|
|
|||
[Package Index | Mudlib Index | Effect Index]File /std/basic/virtual_quit_control.cThis method handles problems where players log out in places which are virtually controlled. It does the effort to put them back in, but does it in a way that is recursive. So if they are on a horse in a terrain it will work properly.Written by Pinkfish Started Wed Sep 22 18:24:40 PDT 1999 Exampleinherit "/std/basic/virtual_quit_control";
void player_quitting(object player, object place) {
string pos;
pos = check_start_pos(environment(place));
// Doesn't need to last long since we save immediately.
player->add_property(START_PLACE, pos, 10);
::player_quitting(player, environment(place));
} /* player_quitting() */
// Move the player to the right spot when they login.
void event_enter(object player) {
player->move(player->query_property(START_PLACE));
} /* move_player_to_real_location() */
Method index
Protected FunctionsThese are functions that only objects inheriting the class can access.
int * find_start_coord(object player,
object place)
This method is called on the quit handler when a player quits.
string find_start_pos(object player,
object place)
This method is called on the quit handler when a player quits.
|
||||
|
Brought to you by CMOT Dibbler's Sensational Sausages; buy one while they're hot. |