room_first


Description

This read only variable returns the index of the very first room in the game (this is defined by the order in which the rooms appear in the resource tree and not by the order in which they were created.


Syntax:

room_first;


Returns:

Index


Example:

if lives < 1
   {
   room_goto(room_first);
   }

The above code will check the "lives" variable and if it is less than 1 goto the first room in the game.


Back: General Room Functions And Variables
Next: room_last
© Copyright YoYo Games Ltd. 2018 All Rights Reserved