top of page

Timer Operations - A Basic Escape Dungeon

  • Writer: meetthemeese
    meetthemeese
  • Nov 3, 2022
  • 3 min read

Updated: Nov 23, 2022

One of the several useful commands the RPGMaker 2000 comes with is the Timer Operations command. This allows us to set a timer in our game, which we can then combine with mainly the Fork Conditions or the Set Variables (we can set variables with 'Timer seconds left' when we create them) command to initiate certain game sequences.


This tutorial shows how we can use this in a very common scenario - a timed escape dungeon.


Alarm clock
z0mg! a related image!

This tutorial also assumes you're familiar with the RM2K interface and creating events (if not, check out this list of beginner tutorials instead).




The Logic


At any given point in the game (someone correct me if I'm wrong), there can only be one timer set up. There is only 1 timer object to manipulate (I haven't been able to find any settings that lets us create multiple timers yet).


We're able to set the timer to a limit, and start and stop that same timer in any map. So this timer object has a global or game-wide scope. In an escape dungeon, we'd want to start the timer when we enter it, and stop it on exit. We can do this with a parallel event and switches.


There are 2 parts to this:

  1. A map-event that runs as a parallel process, to set and start the timer whenever the player enters the dungeon and to set a switch to indicate that the timer is running

  2. The entry and exit teleport events will also need to turn off the timer explicitly.

In case you want the timer to be a one-time thing only, with the player able to freely explore the dungeon after a successful exit, you just need to prevent the parallel process from running. In this example, we'll be making an always-timed-escape dungeon, and in order to make it a one-time thing only, you'd just need to ensure the switch that tracks the timer being on stays in the ON state. It'll be clearer once we go through the example.


I'm using Don's rip for the example, so translations might differ slightly if you're using the official version.




The Unnumbered Steps:


Let's start with the parallel event. Set it up on any inaccessible part of your map. It needs to have 2 pages - the default will set and turn on the timer, while page 2 will handle what happens when the timer ends.


Default page -

Set the trigger to 'parallel process', and add the following commands:

  1. Open the 'Timer Operations' command (tab 1, column 1), and in the new dialog, choose 'Set' (the first option). Then set the timer limit in the next panel (you can also use variables here, but for this example, we'll need a static timer limit).

Timer operations command

The timer command's dialog

  1. Add the same command again, but this time, choose 'Start'. You can also opt for displaying the timer (on the top left corner of your game). Selecting the 'Available In Battle' option means the timer will continue to run during battles.

  2. Create and set a switch to ON. My switch is named DungeonTimer.


Default page settings
Default page settings

Default page of the parallel event
Default page of the parallel event

Page 2:

Set the trigger to 'parallel process' again. This time, we'll need to set the page condition with the switch we created in the default page, so go ahead and add that as an 'Event Condition'.


Page 2 settings of the parallel event
Page 2 settings of the parallel event

Use the fork command and choose the 'Timer' option.

We want to do something once the timer runs out, so set this option to 'below' 0min. 0sec..


Fork conditions setting
Fork conditions setting


I'm simply going to end the game if the timer runs out before the player can escape. This is what my commands look like:


Page 2 commands in parallel event
I haven't written one snarky or random caption yet, congratulate me

NOTE: The fork condition does not evaluate the timer unless it is in the Start/running state. This means that if you've manually turned it off before the end (of time), then the fork condition doesn't bother reading the timer's value at all and you automatically fall in the ELSE branch (if any).


That's the parallel event done. Let's now move on to the entry and exit teleport events.


Here's an unneeded screenshot of my map with its teleport events, because why not.


Map
Map

We only need to add two extra commands to whatever you usually use for entry/exit:

  1. Stop the timer with the 'Timer Operations' command

  2. Turn off the switch that was turned on when the timer started running (in this example, that's called DungeonTimer)

NOTE: If you don't turn off the switch, then you've effectively got a one-time-timed dungeon (i.e., the player needs to exit just once and on subsequent returns to the dungeon, the timer won't run anymore). This works because, as explained before, if the timer has been stopped via command, then the fork condition in Page 2 of our parallel event simply evaluates to false.

Additions to the usual entry/exit commands
Additions to the usual entry/exit commands

And that's that. Pretty straight-forward!


cover
Rejoice


Before we wrap up, just another reminder that you can store a timer's current value in variables. Eyep.




Farewell, fellow rpg-ers.


- An Irritable Moose




Comments


PREV:

[Link Missing]

NEXT:

[Link Missing]

Check Out Other (Possibly Unrelated) Posts From This Site

bottom of page