Time-Based Events?

Status
Not open for further replies.

Pearsona

Trash Goblin
Veteran
Joined
Nov 12, 2013
Messages
92
Reaction score
48
First Language
English
Primarily Uses
RMMV
I am making a horror game, and one of the scenes is a chase scene, which ends with the player going into a room and locking the door. The player would have to solve a puzzle to escape, but if they took more than a certain set amount of time the monster chasing them would break the door down and attack them. However, I dont know how to make this event trigger. How would I go about making a time limit like this? (im not looking for an event that would put a timer in the corner of the screen, however)
 

Celianna

Tileset artist
Veteran
Joined
Mar 1, 2012
Messages
10,557
Reaction score
5,590
First Language
Dutch
Primarily Uses
RMMV
You could also simply use two variables and a common event set to parallel process.


When your event begins, where the player has to escape, set a variable to Game Data > Other > Play Time. Then turn on a switch. Create a common event that runs on this switch, set it to parallel process. In it, set another variable to Play Time again. Subtract the first variable from the second, so you get the amount of time that has currently passed. Create a conditional branch that checks if the second variable is greater than or equal to X. X being the amount of seconds you want the player to have to escape. So this can be 60 which is 1 minute.


If true, trigger the event that makes the monster break down the door. Else, just do nothing :)


Don't forget to turn off the switch if the player manages to solve the puzzle.
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,615
Reaction score
4,618
First Language
English
Primarily Uses
RMMV

@coffeeplayz , please refrain from necro-posting in a thread. Necro-posting is posting in a thread that has not had posting activity in over 30 days. You can review our forum rules here. Thank you.


I'm closing this thread.

 
Status
Not open for further replies.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts



I've been experimenting with improved memory management again, which allowed me to include items to increase player path length. These are both 44 grid spaces long, and stable. :LZSexcite:
I FINALLY DID IT! 5 years making my very first game and I just officially released it on STEAM..... OMG..... I can say I finished a game! The feelings!!!!!
Stream will be live shortly! I am going to be playing some Among Us! Feel free to drop by!
Ami
tv program always get the ratings (it's the reason why drama series has 1000+ episode),also full and nonsense of censorship (weird blur, a scene getting cut because the unconvenient viewer,but it unconvenient to me either. you never see what the original is)

i know the reason is to take cover the viewer from the negative thing,but i just laughing and mocking of them that they're always suck :guffaw:
Star Chart Idea - Just something I am working on.

Forum statistics

Threads
104,460
Messages
1,006,444
Members
135,966
Latest member
Kleik
Top