Change room if you do click or not

Started by rockthe, Sun 14/04/2019 06:57:17

Previous topic - Next topic

rockthe

I have a  StartCutscene(eSkipAnyKeyOrMouseClick); with EndCutscene();

I want go to different room if I did mouse click or I was waiting the cutscene.
For click: Room 3
Without click: Room4

Slasher

#1
This was asked exactly like pakolmo in NOV 2016

answer was

Code: ags

bool skipped;

StartCutscene(eSkipAnyKeyOrMouseClick);
/*
.
. Your cutscene code
.
*/
if(Game.SkippingCutscene)
    skipped = true;
EndCutscene();
/* ... */
if(skipped)
    player.ChangeRoom(3);
else
    player.ChangeRoom(4);


Note: This will also take the player to room 3 if the player pressed a key to skip the cutscene. You didn't mention key presses, so I'm not sure if that was what you were after.

SMF spam blocked by CleanTalk