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

Documentation Area

Document Path: /doc/lib/test_if_any_there


Name: test_if_any_there - check if anyone is present

Syntax:
	status test_if_any_there(object room, int ignore)

Description:
	The test_if_any_there function checks if a once interactive player
	is still present in the given room. If no room is given, the current
	object is assumed. The function is usually used by monsters, which
	turn off the heart beat, if nobody is present.

	The optional second argument is used to ignore certain types of users:
	- If it is 0 (default), userp() is checked
	- If it is 1, interactive() is checked and invisibles are ignored
	- If it is 2, interactive() is checked and wizards are ignored

Return value: 
	1 if a once interactive player is present, 0 if not

Examples:
	if (!test_if_any_there(environment())) return set_heart_beat(0);

See also:


This page was generated in LPC

Imprint / Impressum