A
/ \ _ Play Now Nemesis on
| | | | _______ _ _ _______ _______ _ _______
| |\ | | | ____| | \ / | | ____| / ____| | | / ____|
/-------/-------------------------------------------------------------------,
O= Home <=XX| About News Pics Adventurers Wizards Download Connect >
\-------\-------------------------------------------------------------------'
| | \ | | |____ | | | | | |____ ___ \ \ | | ___ \ \
| | \_| |_______| |_| |_| |_______| |_______/ |_| |_______/
\ /
V
Documentation Area
Document Path: /doc/room/move
Name: move - override exits in a room
Syntax:
#include <room2.h>
int move()
Description:
The move function is called through an add_action for each direction
(set with set_exits) that is accessible in the room. It can be over-
ridden to show special actions when a player wants to leave the room.
Return value:
Should always return 1
Examples:
A player shouldn't leave the room to the north, when a troll is
present:
move() {
if (query_verb()=="north" && present("troll")) {
write("The troll bars your way!\n");
say("The troll bars "+this_player()->query_name()+
"'s way north.\n");
return 1;
}
return ::move();
}
See also:
This page was generated in LPC
Imprint / Impressum