← Yop2D

How to shake the screen?

Beginner guide · no code

Français · English · Español · Deutsch · Italiano · Português · Русский · 中文 · 日本語 · العربية

ℹ️ 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

The screen shakes for half a second, as after a hit. Just one node: Camera shake.

You need:

Step 1: the button

  1. Tap Object → Interactive → Button with text.
  2. Name it secouer and type Shake in its Text line.

Step 2: the nodes

  1. Open the Blueprint.
  2. On Object Click: Object secouer → Camera shake: Duration (milliseconds, 1000 = 1 s) 500

The nodes

On Object Clicksecouer
→
Camera shake500

Try it

Tap Play, then Shake: the screen shakes.

👉 In a real game: put it after If object touches Tag (the hero is hit) or after an explosion. More Strength = stronger.