^#^
quit^#^
SUBTOPIC-player^#^
-=[ Help ]=-
command: quit
Usage :quit
Description: Leave the game. You character is saved. If
you are carrying any items they are dropped.
Unless those items are specially marked to
reload the next time your character logs into
the game. When you log into the game you will
log into the 'square'. If there is an entry
room failure, then you will be moved to the
'void'.
Related topics: save, Quit.
^#^
Quit^#^
SUBTOPIC-player^#^
-=[ Help ]=-
command: Quit
Usage: Quit
Description: Leave the game. Your character is saved, and
any items you are carrying are saved. Some
special items, however, may not save.
Certain items that are specially market to
reload the next time your character logs into
the game (like class/sub-class items) will also
remain with you.
When you log into the game next time, you will
log into the room you left. If there is an entry
room failure, then you will be moved to the
'void'.
Related topics: save, quit.
^#^
query_idle^#^
SUBTOPIC-efun^#^
EFUN query_idle()
SYNOPSIS
int query_idle(void|object ob)
DESCRIPTION
Query how many seconds since input was received from a
player object <ob>. If <ob> is void then it defaults to
this_object().
EXAMPLE
/* part of heartbeat */
void heartbeat() {
if(query_idle() > 3600) {
quit();
}
...etc
}
SEE ALSO
query_ip_number(), interactive()
^#^
query_verb^#^
SUBTOPIC-efun^#^
EFUN query_verb()
SYNOPSIS
string query_verb()
DESCRIPTION
Give the name of the current command, or 0 if not executing
from a command. This enables add_action() of several
commands to the same function.
EXAMPLE
status locked_flag;
void init() {
add_action("toggle_lock","lock");
add_action("toggle_lock","unlock");
}
status toggle_lock(string str) {
string verb;
if(str == "padlock") {
verb = query_verb();
if(locked_flag ^ (verb == "unlock")) { /* XOR test */
write("The padlock is already "+ verb +"ed.\n");
return 1;
}
write("You "+ verb +" the padlock.\n");
locked_flag = !locked_flag;
return 1;
}
return 0;
}
SEE ALSO
add_action().
^#^
query_actions^#^
SUBTOPIC-efun32^#^
SYNOPSIS
mixed *query_actions(object ob, mixed mask_or_verb)
DESCRIPTION
query_actions takes either an object or a filename as first
argument and a bitmask (int) or string as a second argument.
If the second argument is a string, query_actions() will return
an array containing information (see below) on the verb or
zero if the living object "ob" cannot use the verb. If the
second argument is a bitmask, query_actions() will return a
flat array containing information on all verbs added to ob.
The second argument is optional (default is the bitmask 1).
1: the verb
2: type
4: short_verb
8: object
16: function
"type" is one of the values defined in <sent.h> (/sys/sent.h)
(which is provided with the parser source).
SENT_PLAIN added with add_action (fun, cmd);
SENT_SHORT_VERB added with add_action (fun, cmd, 1);
SENT_NO_SPACE added with add_action (fun); add_xverb (cmd);
SENT_NO_VERB just an add_action (fun); without a verb
SENT_MARKER internal, won't be in the returned array
SEE ALSO
add_action(E), init(A)
^#^
query_editing^#^
SUBTOPIC-efun32^#^
SYNOPSIS
mixed query_editing(object | string ob)
DESCRIPTION
Returns 1 if the ob is interactive and currently editing
with ed(). If ed() was called with a function name as
second argument, the object where ed() was called is returned,
else 0.
SEE ALSO
ed(E)
^#^
query_host_name^#^
SUBTOPIC-efun32^#^
SYNOPSIS
string query_host_name(void)
DESCRIPTION
Return the name of the machine the mud is running on.
SEE ALSO
query_mud_port(E)
^#^
query_imp_port^#^
SUBTOPIC-efun32^#^
SYNOPSIS
int query_imp_port(void)
DESCRIPTION
Returns the port number that is used for the inter mud
protocol.
SEE ALSO
send_imp(E), receive_imp(M)
^#^
query_input_pending^#^
SUBTOPIC-efun32^#^
SYNOPSIS
object query_input_pending(object | string ob)
DESCRIPTION
If ob is interactive and currently has an input_to() pending,
the object that has called the input_to() is returned,
else 0.
SEE ALSO
input_to(E)
^#^
query_ip_name^#^
SUBTOPIC-efun32^#^
SYNOPSIS
string query_ip_name(object ob)
DESCRIPTION
Give the ip-name for user the current user or for the
optional argument ob. An asynchronous process 'hname' is used
to find out these names in parallel. If there are any failures
to find the ip-name, then the ip-number is returned instead.
SEE ALSO
query_ip_number(E)
^#^
query_ip_number^#^
SUBTOPIC-efun32^#^
SYNOPSIS
string query_ip_number(object ob)
DESCRIPTION
Give the ip-number for the current user or the optional
argument ob.
SEE ALSO
query_ip_name(E)
^#^
query_load_average^#^
SUBTOPIC-efun32^#^
SYNOPSIS
string query_load_average(void)
DESCRIPTION
Returns the load of the mud. Two figures are given, executed
commands/second and compiled lines/second.
SEE ALSO
getrusage(E)
^#^
query_mud_port^#^
SUBTOPIC-efun32^#^
SYNOPSIS
int query_mud_port(void)
DESCRIPTION
Returns the port number the parser uses for user connections.
SEE ALSO
query_host_name(E)
^#^
query_once_interactive^#^
SUBTOPIC-efun32^#^
SYNOPSIS
int query_once_interactive(object ob)
DESCRIPTION
True if the object is or once was interactive.
SEE ALSO
remove_interactive(E)
^#^
query_snoop^#^
SUBTOPIC-efun32^#^
SYNOPSIS
object query_snoop(object victim)
DESCRIPTION
Returns the user who currently snoops victim. The calling
object must be privileged by the master object.
SEE ALSO
snoop(E)
^#^
quote^#^
SUBTOPIC-efun32^#^
SYNOPSIS
mixed quote(mixed)
DESCRIPTION
Converts arrays to quoted arrays and strings to symbols.
Symbols and quoted arrays get quoted once more.
EXAMPLES
quote("foo") -> 'foo
quote(({1,2,3})) -> '({1,2,3})
SEE ALSO
symbolp(E)
^#^
query_level^#^
SUBTOPIC-compatfn/driverfn^#^
SYNOPSIS
int query_level(void)
DESCRIPTION
In former times this function was used by the parser when
executing set_living_name() to check if the calling object
should be marked as being a wizard.
Mentioned here only for hysterical raisins, not used by the
parser anymore.
SEE ALSO
query_player_level(M), wizlist(E)
^#^
query_real_name^#^
SUBTOPIC-compatfn/driverfn^#^
SYNOPSIS
string query_real_name(void)
DESCRIPTION
The result of this_player()->query_real_name() is used as
default argument for the efun wizlist().
If LOG_SHOUT was #defined in the parser at compile time, the
efun shout will use query_real_name() to log the shouter's
name.
SEE ALSO
shout(E), wizlist(E)
^#^
query_weight^#^
SUBTOPIC-compatfn/driverfn^#^
SYNOPSIS
int query_weight(void)
DESCRIPTION
In compat mode this lfun is used by the efun transfer().
Not that no set_weight() is required by the parser.
SEE ALSO
transfer(E), add_weight(A)
^#^
query_allow_shadow^#^
SUBTOPIC-efun32^#^
SYNOPSIS
int query_allow_shadow(object victim)
DESCRIPTION
Return 1 if previous_object() is allowed to use efun shadow()
on object victim, 0 if it is not.
The function should deny shadowing on all root objects, else
it might query the victim for clearance. Most installations
seem to use victim->query_prevent_shadow(previous_object()) to
check if the victim denies being shadowed.
SEE ALSO
shadow(E)
^#^
query_player_level^#^
SUBTOPIC-efun32^#^
SYNOPSIS
int query_player_level(string what)
DESCRIPTION
Check if the user is of high enough level for several things.
The argument denotes the action for which permission is to be
checked:
"trace" Is the user allowed to use tracing?
"inspect memory" Is the user allowed to issue the
special command "showsmallnewmalloced"?
SEE ALSO
trace(E), showsmallnewmalloced(D), malloc(D), status(D), memory(C)
^#^
quota_demon^#^
SUBTOPIC-efun32^#^
SYNOPSIS
void quota_demon(void)
DESCRIPTION
Handle quotas in times of memory shortage.
This function is called during the final phase of a garbage
collection if the reserved user area couldn't be reallocated.
This function (or a called demon) has now the opportunity to
remove some (still active) objects from the system. If this does
not free enough memory to reallocate the user reserve,
slow_shut_down() will be called to start Armageddon.
Up to now, the wizlist lacks various informations needed to
detect the memory-hungriest users.
SEE ALSO
slow_shut_down(M), wizlist(E)