ℹ️ For Yop2D Next, the new 2D + 3D version of Yop2D (coming soon). Button and node names are those of Yop2D Next.
🔍 How do I…? All short recipes, with a search
Two buttons: Hide makes a chest disappear, Show brings it back. Just one node: Visibility.
You need:
- a 2D project open in Yop2D Next.
Step 1: the object
- Put an object in the scene (an image or a Square) and name it coffre.
Step 2: the two buttons
- Tap Object → Interactive → Button with text.
- Name it cacher and type Hide in its Text line.
- Tap Object → Interactive → Button with text.
- Name it montrer and type Show in its Text line.
Step 3: the nodes
- Open the Blueprint.
- On Object Click: Object cacher → Visibility: Object coffre, Visible (yes / no) No
- On Object Click: Object montrer → Visibility: Object coffre, Visible (yes / no) Yes
The nodes
On Object Clickcacher
→
Visibilitycoffre · No
On Object Clickmontrer
→
Visibilitycoffre · Yes
Try it
Tap Play, then Hide: the chest disappears. Tap Show: it comes back.
👉 A hidden object can still touch others. To remove it for good, use Destroy Object.