Is it possible to create cutscenes with timers and animations?

Cutscenes that the player doesn’t interact with the game.

you can build somethink with tweens and camera move.
i use this in my game for some events
during this “event” the total screen has an overlay that catches the cursor input, so user cant click anywhere

for example moving camera:

                        this.scene.cameras.main.stopFollow();
                        this.scene.tweens.add( {
                            targets: this.scene.cameras.main,
                            scrollX: (field.x - this.scene.game.config.width/2),
                            scrollY: (field.y - this.scene.game.config.height/2),
                            duration: stageData.duration||2000,
                            ease: "Sine.easeInOut",
                            hold: 1000,
                            yoyo: true,
                            onComplete: this.nextStage,
                            onCompleteScope: this,
                        });

for example zooming camera:

this.scene.cameras.main.zoomTo( parseInt(stageData.zoom)||1, 2000 );

with the same code, u can move your npcs / char over the scene :slight_smile:

1 Like