A
          / \      _              Play Now                         Nemesis on 
          | |     | |  _______   _        _   _______    _______   _    _______
          | |\    | | |   ____| |  \    /  | |   ____|  /   ____| | |  /   ____|
 /-------/-------------------------------------------------------------------,
O= Home <=XX|  About  News  Pics  Adventurers  Wizards  Download  Connect     >
 \-------\-------------------------------------------------------------------'
          | |   \   | |  |____  | |      | | |  |____   ___ \  \  | |  ___ \  \
          | |     \_| |_______| |_|      |_| |_______| |_______/  |_| |_______/
          \ /
           V  

Documentation Area

Document Path: /doc/room2/page7


<
                                  CHAPTER 1                                     
Exits:

   Our example room is only reachable by wizards at the moment and from it
   you can't get anywhere. In room2 exits can be set with the function 
   set_exits(). Add the following lines to your simple room right after the 
   set_weather function:

	set_exits( ({
	  "players/<insert your name here>/workroom", "out"
	}) );

   Now reload the room and look at the changes. The set_exits function takes
   only a single argument, an array. An array is a set of values enclosed by
   ({ }). We will need arrays more often in this tutorial. The first argument
   in our example is the filename (without leading "/" AND without trailing
   ".c") where the exit leads, the second is the exit direction.

   Now create a second simple room (perhaps call it simple2.c) and set the
   exits of both rooms so that you can walk from one room into the other. 
   Of course you can add more exits by just adding them to the array. Note
   that the number of array elements must be a multiple of 2.

   Changed/modified in August 2016!

See also:
>

This page was generated in LPC

Imprint / Impressum