generic gamer #91

Parent #40Owner #36Flags read, fertileSource RPG Core/rpgcore-patched.db

Aliases: generic gamer, gamer

58 verbs · 93 properties · 3 children

Verbs

VerbSpecFlagsDefinerLines
init_for_corethis none thisrxd#9143
quickpage '*any any anyrd#9144
follow trail stop-following forgetany none nonerd#9162
dump_followersthis none thisrxd#918
capture cuffthis none nonerd#9115
surrendernone none nonerd#912
_capturethis none thisrxd#9111
_leashthis none thisrxd#9120
release uncuff losethis none nonerxd#9126
_releasethis none thisrxd#918
dump_goodiesthis none thisrxd#9139
look_selfthis none thisrxd#9115
tell_contentsthis none thisrxd#9122
look_statethis none thisrxd#9110
@he*althnone none nonerd#9114
diethis none thisrxd#9158
_wieldthis none thisrxd#912
pass_outthis none thisrxd#9113
freezethis none thisrxd#9113
take_hitthis none thisrxd#9120
take_healththis none thisrxd#913
armorthis none thisrxd#917
damagethis none thisrxd#9117
to_hitthis none thisrxd#9110
to_defendthis none thisrxd#917
tellthis none thisrxd#9128
titlethis none thisrxd#9122
sayany any anyrxd#918
emoteany any anyrxd#9110
reached_limitthis none thisrxd#9116
my_huhthis none thisrxd#917
g*et t*akeany none nonerxd#9136
dr*op th*rowany none nonerxd#9151
gi*ve ha*nd payany at/to anyrxd#9160
conv*ertany at/to anyrd#9116
transfer_ammothis none thisrxd#9144
descriptionthis none thisrxd#911
@kids @s*how @verbs @props @properties @exam*ine exam*ine where*is @where*is homeany none nonerd#9126
@stats @score @points @skillsnone none nonerxd#9147
@boostany at/to anyrd#9147
@send @answer @repl*yany any anyrxd#9146
cash moneynone none nonerd#9117
my_match_objectthis none thisrxd#918
medicalthis none thisrxd#915
@featuresany for/about anyrxd#9123
@add-feature @addfeature @remove-feature @rmfeatureany none nonerd#915
_add_money _rem_moneythis none thisrxd#9116
_has_amountthis none thisrxd#916
_lootthis none thisrxd#9118
roll_againstthis none thisrxd#9162
@rollany none nonerd#9124
loot rob pilfer roll search stripthis none nonerxd#912
speak*ingany none nonerd#9126
rememberany as anyrd#9123
do_forgetthis none thisrxd#919
short_desc_matchesthis none thisrxd#9110
@rememberednone none nonerd#915
short_desc_msgthis none thisrxd#911

Properties

PropertyDefinerFlagsOwnerValue
death_msg#91rc#36"%N %<falls> limply to the ground."
alive#91r#361
alert#91r#361
mobile#91r#361
wielded#91r#36#110
last_paged#91r#36#2
last_healed#91r#36#-1
followed_by#91r#36#-1
following#91r#36#-1
free_points#91r#360.0
stats#91r#36{{"Strength", "Dexterity", "Intelligence", "Health"}, {10.0, 10.0, 10.0, 10.0}}
stats_current#91r#36{{"Strength", "Dexterity", "Intelligence", "Health"}, {10.0, 10.0, 10.0, 10.0}}
skills#91r#36{{"combat", "medical", "language"}, {0.0, 0.0, 0.0}}
race#91r#36"human"
org#91r#36""
money#91r#36{}
follow_msg#91rc#36"%N %<is/are> following %d."
stopfollow_msg#91rc#36"%N %<stops> following %d."
searching#91r#360
languages#91r#36{{#142}, {2.0}}
speaking#91r#36#-1
remembered_names#91r#36{}
short_desc_msg#91r#36""
_mail_task#40rc#36<clear>
messages_going#40c#36<clear>
mail_lists#40rc#36<clear>
mail_notify#40r#2<clear>
mail_forward#40rc#36<clear>
mail_options#40rc#36{}
message_keep_date#40rc#36<clear>
messages_kept#40rc#36<clear>
current_message#40c#36{0, -1300000000}
messages#40c#36<clear>
ansi_options#95r#36<clear>
replace_codes#95r#36<clear>
features#6r#36{#92, #124, #143}
previous_connection#6#2<clear>
email_address#6#2<clear>
last_disconnect_time#6r#2<clear>
help#6rc#36#105
more_msg#6rc#36<clear>
linetask#6r#36<clear>
linesleft#6r#36<clear>
linebuffer#6#36<clear>
pagelen#6r#36<clear>
owned_objects#6r#2<clear>
linelen#6r#36<clear>
current_folder#6c#36<clear>
all_connect_places#6#2<clear>
last_connect_place#6#2<clear>
brief#6rc#36<clear>
lines#6c#36<clear>
page_absent_msg#6rc#36<clear>
pq#6rc#36<clear>
pqc#6rc#36<clear>
page_origin_msg#6rc#36<clear>
page_echo_msg#6rc#36<clear>
edit_options#6rc#36<clear>
last_connect_time#6r#2<clear>
ownership_quota#6#36<clear>
gender#6rc#36<clear>
prc#6rc#36<clear>
ppc#6rc#36<clear>
poc#6rc#36<clear>
psc#6rc#36<clear>
pr#6rc#36<clear>
pp#6rc#36<clear>
po#6rc#36<clear>
ps#6rc#36<clear>
home#6rc#36#62
password#6#2<clear>
gaglist#6rc#36<clear>
paranoid#6rc#36<clear>
display_options#6rc#36<clear>
verb_subs#6rc#36<clear>
first_connect_time#6r#2<clear>
size_quota#6#36<clear>
last_password_time#6#2<clear>
last_connect_attempt#6#2<clear>
page_count_start_time#6r#2<clear>
ping_task#6r#36<clear>
value_base#102r#2<clear>
damage_base#102r#20.5
x_loc#102r#36<clear>
y_loc#102r#36<clear>
ansi_title#102r#36<clear>
obvious#102r#36<clear>
build_help#102rc#36<clear>
key#1c#360
aliases#1r#2{"generic gamer", "gamer"}
description#1rc#36<clear>
object_size#1r#36{68946, -1090650497}
html#1rc#36<clear>

Ancestry

Ancestors (nearest first): #40 Generic Mail Receiving Player#95 ANSI PC#6 generic player#102 subthing#1 Root Class

Children: #90 Frand's administrator class, #116 generic puppet, #159 player

Call graph

calls n91_0 #91:init_for_core n40_52 #40:init_for_core n91_0->n40_52 n91_1 #91:quickpage n6_18 #6:tell n91_1->n6_18 n20_20 #20:match_player n91_1->n20_20 n56_1 #56:player_match_result n91_1->n56_1 n6_29 #6:page n91_1->n6_29 n91_2 #91:follow n91_2->n6_18 n91_2->n20_20 n51_0 #51:match n91_2->n51_0 n98_12 #98:person_match_failed n91_2->n98_12 n91_25 #91:tell n91_2->n91_25 n35_1 #35:say_action n91_2->n35_1 n52_5 #52:isa n91_2->n52_5 n55_18 #55:iassoc n91_2->n55_18 n27_1 #27:intersection n91_2->n27_1 n1_29 #1:contents n91_2->n1_29 n91_25->n6_18 n6_9 #6:titlec n91_25->n6_9 n102_4 #102:title n91_25->n102_4 n91_4 #91:capture n91_4->n6_18 n91_4->n91_25 n91_4->n27_1 n91_4->n1_29 n91_4->n6_9 n91_4->n102_4 n91_26 #91:title n91_4->n91_26 n52_6 #52:ancestors n91_26->n52_6 n91_5 #91:surrender n91_5->n35_1 n91_18 #91:freeze n91_5->n91_18 n91_18->n91_25 n91_6 #91:_capture n91_7 #91:_leash n91_6->n91_7 n91_7->n91_25 n91_7->n52_5 n91_7->n27_1 n91_7->n1_29 n91_7->n6_9 n91_7->n91_7 n91_9 #91:_release n91_7->n91_9 n91_9->n35_1 n91_9->n52_5 n99_4 #99:valid_task n91_9->n99_4 n99_17 #99:schedule n91_9->n99_17 n91_8 #91:release n91_8->n6_18 n91_8->n35_1 n91_8->n27_1 n91_8->n1_29 n91_8->n6_9 n91_8->n91_26 n91_8->n91_9 n91_10 #91:dump_goodies n91_10->n52_5 n63_1 #63:_recycle n91_10->n63_1 n52_3 #52:has_callable_verb n91_10->n52_3 n52_0 #52:has_property n91_10->n52_0 n63_2 #63:_create n91_10->n63_2 n21_1 #21:set_names n91_10->n21_1 n91_11 #91:look_self n91_11->n6_18 n91_11->n1_29 n91_11->n6_9 n6_79 #6:tell_lines n91_11->n6_79 n91_36 #91:description n91_11->n91_36 n41_7 #41:pronoun_sub n91_11->n41_7 n91_13 #91:look_state n91_11->n91_13 n20_8 #20:from_seconds n91_11->n20_8 n91_12 #91:tell_contents n91_11->n91_12 n91_13->n6_18 n91_13->n41_7 n91_13->n20_8 n91_12->n6_18 n91_12->n52_0 n91_12->n6_79 n6_13 #6:linelen n91_12->n6_13 n32_0 #32:length n91_12->n32_0 n20_4 #20:columnize n91_12->n20_4 n91_14 #91:@he*alth n91_14->n6_18 n91_15 #91:die n91_15->n91_25 n91_15->n6_9 n91_15->n91_26 n91_15->n91_10 n91_15->n52_6 n91_17 #91:pass_out n91_15->n91_17 n91_17->n91_25

Showing 48 of 129 verbs; 81 not shown.

Source

init_for_core

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1if (caller_perms().wizard)
2if (this == $rpgamer)
3this.stats = {{"Strength", "Dexterity", "Intelligence", "Health"}, {10.0, 10.0, 10.0, 10.0}};
4this.stats_current = {{"Strength", "Dexterity", "Intelligence", "Health"}, {10.0, 10.0, 10.0, 10.0}};
5this.skills = {{"combat", "medical", "language"}, {0.0, 0.0, 0.0}};
6this.death_msg = "%N %<falls> limply to the ground.";
7this.alive = 1;
8this.alert = 1;
9this.mobile = 1;
10this.wielded = $hand;
11this.last_paged = #2;
12this.last_healed = #-1;
13this.followed_by = #-1;
14this.following = #-1;
15this.free_points = 0.0;
16this.race = "human";
17this.org = "";
18this.money = {};
19this.damage_base = 0.5;
20this.follow_msg = "%N %<is/are> following %d.";
21this.stopfollow_msg = "%N %<stops> following %d.";
22this.speaking = #-1;
23elseif (!this.wizard)
24for p in (properties($rpgamer))
25if ((!p) in {"build_help", "help_msg"})
26clear_property(this, p);
27endif
28endfor
29endif
30if (this == $builder)
31this.stats = {{"Strength", "Dexterity", "Intelligence", "Health"}, {20.0, 20.0, 20.0, 20.0}};
32this.stats_current = {{"Strength", "Dexterity", "Intelligence", "Health"}, {20.0, 20.0, 20.0, 20.0}};
33this.skills = {{"combat", "medical", "language"}, {5.0, 5.0, 5.0}};
34elseif (this != $rpgamer)
35clear_property(this, "skills");
36clear_property(this, "stats");
37clear_property(this, "stats_current");
38endif
39this.languages = {{$default_lang}, {2.0}};
40this.remembered_names = {};
41this.short_desc_msg = "";
42return pass(@args);
43endif

quickpage '*

Spec any any anyFlags rdOwner #36Definer #91

Referenced by

none

Source

1"Quickpage has the advantage that if you don't give a name,it will";
2"assume you meant the last person you paged.  Useful if you're having";
3"a long conversation.  Syntax:";
4"'<player> <message>      Quickpages a given player.";
5"' <message>              Quickpages last player.  Space is important.";
6"quickpage player message Quickpages a given player.";
7"quickpage message        Quickpages last player.  Note that if your message";
8"                         starts with some player's name, it'll go to them,";
9"                         instead.  Use ' to be safe.";
10if (args == {})
11if (length(verb) == 1)
12player:tell("You last paged: ", this.last_paged:title(), " (", this.last_paged, ").");
13else
14player:tell("Sending blank pages is a waste of time.");
15endif
16return 1;
17endif
18verbname = verb;
19if (verbname == "quickpage")
20dobjvalid = call_function("tonum", $string_utils:match_player(args[1]));
21if (dobjvalid > 0)
22whostring = args[1];
23message = argstr[length(dobjstr) + 1..length(argstr)];
24else
25whostring = player.last_paged.name;
26message = argstr;
27endif
28elseif (length(verbname) > 1)
29whostring = verbname[2..length(verbname)];
30message = argstr;
31iobjstr = (dobjstr + " ") + iobjstr;
32dobjstr = whostring;
33else
34whostring = player.last_paged.name;
35message = argstr;
36iobjstr = (dobjstr + " ") + iobjstr;
37dobjstr = whostring;
38endif
39target = $string_utils:match_player(whostring);
40if ($command_utils:player_match_failed(target, whostring))
41return;
42endif
43player.last_paged = target;
44return player:page(target.name, message);

follow trail stop-following forget

Spec any none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1who = dobjstr;
2person = valid(dobj) ? dobj | $match_utils:match(who, this.location:contents());
3person = ((person == $ambiguous_match) || `!(!property_info(person, "followed_by")) ! ANY => 0') ? person | $string_utils:match_player(who);
4if ($rp_regulator:person_match_failed(person, who))
5return;
6elseif (person.location != player.location)
7return player:tell(person.name, " can not be found here.");
8endif
9if ((player.owner != player) || (person.owner != person))
10return player:tell("Guests are not allowed to interact in that fashion.");
11elseif (person == this)
12return this:tell(who, "? You can only follow *other* people.");
13endif
14if (verb in {"follow", "trail"})
15if (valid(this.following))
16this:tell("You're already following ", this.following:title(), ". 'Stop-following' or 'forget' ", this.following:title(), " first.");
17return;
18endif
19dobj = this.following = person;
20$you:say_action(this.follow_msg);
21person.followed_by = this;
22this:tell("('Stop-following' or 'forget' ", this.following:title(), " to quit following)");
23while (valid(this.following))
24if ((((!(person in connected_players())) && is_player(person)) || ((!(this in connected_players())) && is_player(this))) || (!person.location:acceptable(this)))
25person:tell(this.name, " just stopped following you.");
26this.following:dump_followers();
27this:tell("You have just stopped following ", person:title(), ".");
28this:tell(person:titlec(), " has either entered a room secured against you, disconnected, or managed to lose you.");
29else
30suspend(5);
31if (((person.location != this.location) && $object_utils:isa(person.location, $room)) || ($object_utils:isa(person.location, $terrain) && (!person.location:match_loc(person, this))))
32if (person.location == $dead_zone)
33this.following:dump_followers();
34return this:tell("You cannot follow ", person:title(), " into the dead zone.");
35endif
36suspend(1);
37this.x_loc = person.x_loc;
38this.y_loc = person.y_loc;
39move(this, person.location);
40$you:say_action("%N %<follows> %d.");
41endif
42endif
43endwhile
44else
45if (!valid(this.following))
46if (verb == "forget")
47rns = player.remembered_names;
48if (!(rin = $list_utils:iassoc(argstr, rns, 2)))
49return player:tell("You don't know anyone named '", argstr, "'.");
50endif
51player:tell("Okay you have forgotten about ", rns[rin][2], ", ", rns[rin][1]:short_desc_msg(), ".");
52return player:do_forget(rns[rin][1]);
53endif
54this:tell("You aren't following anyone, anyway.");
55elseif (((c = $set_utils:intersection(player:contents(), children($cuffs))) != {}) && c[1].wornness)
56this:tell("You're a prisoner, and can't free yourself.");
57else
58dobj = person;
59this.following:dump_followers();
60$you:say_action(this.stopfollow_msg);
61endif
62endif

dump_followers

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1if (valid(this.followed_by))
2this.followed_by.following = $nothing;
3endif
4if (valid(this.following))
5this.following.followed_by = $nothing;
6endif
7this.followed_by = $nothing;
8this.following = $nothing;

capture cuff

Spec this none noneFlags rdOwner #36Definer #91

Referenced by

none

Source

1if ((player != this) && `player.alive ! E_PROPNF => 0')
2if ((((!this.alert) || (!this.mobile)) && (c = $set_utils:intersection(player:contents(), children($cuffs)))) && c[1]:ok_to_use())
3c[1]:_cuff(this);
4elseif (((((player.stats_current[2][1] > (this.stats_current[2][1] * 1.2)) || (player.stats_current[2][2] > (this.stats_current[2][2] * 1.2))) || (player.stats_current[2][4] > (this.stats_current[2][4] * 2.0))) && (c = $set_utils:intersection(player:contents(), children($cuffs)))) && (player in c[1].trustees))
5c[1]:_cuff(this);
6elseif ((this.alert && this.alive) && this.mobile)
7this:tell(player:titlec(), " tries to capture you, but you avoid ", player.pp, " grasp.");
8player:tell(this:titlec(), " cautiously dodges your advance.");
9this.location:announce_all_but({this, player}, tostr(this:titlec(), " cautiously avoids ", player:title(), "."));
10else
11player:tell("Why not try searching ", this:title(), " instead?");
12endif
13else
14player:tell("You like bondage, huh?");
15endif

surrender

Spec none none noneFlags rdOwner #36Definer #91

Referenced by

none

Source

1$you:say_action("%N %<surrenders>!");
2this:freeze();

_capture

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ OWNED";
2"This is if called by handcuffs or mental control verbs.";
3this.following = player;
4player.followed_by = this;
5if (`$scheduler:kill_task(this.wander_task) ! E_PROPNF => 0')
6this.wander_task = 0;
7endif
8if (!(this.wielded in {$hand, $claw, $teeth}))
9this.wielded:_unwield();
10endif
11this:_leash();

_leash

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1if ((valid(this.following) && this.following.alert) && this.following.alive)
2suspend(1);
3if (((valid(this.following) && (this.following.location != this.location)) && $object_utils:isa(this.following.location, $room)) && (!$object_utils:isa(this.following.location, $editor)))
4this.location:announce_all_but({this}, this:titlec(), " follows ", this.following:title(), " out.");
5move(this, this.following.location);
6this.location:announce_all_but({this}, this:titlec(), " is being led by ", this.following:title(), ".");
7elseif ((valid(this.following) && $object_utils:isa(this.following.location, $terrain)) && (!this.following.location:match_loc(this.following, this)))
8this.location:announce_all_but({this, this.following}, this:titlec(), " follows.");
9this.x_loc = this.following.x_loc;
10this.y_loc = this.following.y_loc;
11this:tell("You follow.");
12this.following:tell(this:titlec(), " follows.");
13this.location:announce_all_but({this, this.following}, this:titlec(), " follows in shackles.");
14endif
15fork (4)
16this:_leash();
17endfork
18elseif ($set_utils:intersection(this:contents(), children($cuffs)) != {})
19this:_release();
20endif

release uncuff lose

Spec this none noneFlags rxdOwner #2Definer #91

Referenced by

none

Source

1if (verb == "lose")
2if (this == player.followed_by)
3$you:say_action("%N %<attempts> to evade all followers.");
4return player:dump_followers();
5else
6return player:tell(this:titlec(), " is only casually following you, if at all.");
7endif
8endif
9"Cuffs";
10if ((c = $set_utils:intersection(this:contents(), children($cuffs))) && c[1]:ok_to_use())
11if (player != this)
12return c[1]:_uncuff(this);
13else
14return player:tell("Sorry, the cuffs are designed so you can't release yourself.");
15endif
16elseif (c != {})
17return player:tell("Only an authorized person can release ", this.po, ".");
18endif
19"Mental";
20if (this.following == player)
21this:_release();
22elseif (valid(this.following))
23player:tell("Only the person who captured ", this:title(), " can release ", this.po, ".");
24else
25player:tell(this:titlec(), " is not a prisoner.");
26endif

_release

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"WIZ OWNED...to be called from handcuffs or mental control verbs.";
2if (valid(this.following))
3$you:say_action("%N %<releases> %d.");
4if ((!is_player(this)) && $object_utils:isa(this, $puppet))
5this.wander_task = (0 || (!$scheduler:valid_task(call_function("tonum", this.wander_task)))) ? $scheduler:schedule_every(this.wait_seconds, this, "wander") | this.wander_task;
6endif
7player:dump_followers();
8endif

dump_goodies

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: dump_goodies(1 or 0) => moves contents of this to this location.";
2"       if 1 is the argument, money is dumped, too";
3"WIZ PERMS";
4if (valid(this.location))
5this.wielded = $hand;
6for x in (this.contents)
7if ($object_utils:isa(x, $container))
8for y in (x.contents)
9y:moveto(this);
10endfor
11$recycler:_recycle(x);
12endif
13endfor
14for x in (this.contents)
15try
16if (($object_utils:has_callable_verb(x, "recycle_at_death") && (!((this.alive && this.alert) && this.mobile))) && x.recycle_at_death)
17x:recycle_at_death();
18else
19x:moveto(this.location);
20endif
21if ($object_utils:has_property(x, "x_loc"))
22x.x_loc = this.x_loc;
23x.y_loc = this.y_loc;
24endif
25except v (ANY)
26"it won't move";
27endtry
28endfor
29"Move money to this location";
30if ((this.money != {}) && args[1])
31money = $recycler:_create($death_purse, $default_holder);
32$building_utils:set_names(money, tostr(this.name, "'s cash purse,cash purse,cash,purse,money"));
33money.money = this.money;
34this.money = {};
35money:moveto(this.location);
36money.x_loc = this.x_loc;
37money.y_loc = this.y_loc;
38endif
39endif

look_self

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

none

Source

1player:tell(this:titlec());
2player:tell_lines(this:description());
3if (!(this in connected_players()))
4player:tell($gender_utils:pronoun_sub("%{:He} %{!is} sleeping.", this));
5elseif (`player.alert ! E_PROPNF => 0' && `player.alive ! E_PROPNF => 0')
6this:look_state();
7elseif ((idle = idle_seconds(this)) < 60)
8player:tell($gender_utils:pronoun_sub("%{:He} %{!is} awake and %{!looks} alert.", this));
9else
10time = $string_utils:from_seconds(idle);
11player:tell($gender_utils:pronoun_sub("%{:He} %{!is} awake, but %{!has} been staring off into space for ", this), time, ".");
12endif
13if (c = this:contents())
14this:tell_contents(c);
15endif

tell_contents

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1c = args[1];
2if (c)
3au = $ansi_utils;
4longear = {};
5gear = {};
6width = player:linelen();
7half = width / 2;
8player:tell("Carrying:");
9for thing in (c)
10cx = tostr(" ", thing:title(), " (", thing, ")");
11if ($object_utils:has_property(player, "wielded"))
12cx = (this.wielded == thing) ? tostr(cx, " (ready)") | cx;
13endif
14if (valid(au) ? au:length(cx) | (length(cx) > half))
15longear = {@longear, cx};
16else
17gear = {@gear, cx};
18endif
19endfor
20player:tell_lines($string_utils:columnize(gear, 2, width));
21player:tell_lines(longear);
22endif

look_state

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1if (!this.alert)
2player:tell($gender_utils:pronoun_sub("%{:He} %{!is} knocked unconscious.", this));
3elseif (!this.alive)
4player:tell($gender_utils:pronoun_sub("%{:He} %{!is} ethereal, as if dead.", this));
5elseif ((idle = idle_seconds(this)) < 60)
6player:tell($gender_utils:pronoun_sub("%{:He} %{!is} awake and %{!looks} alert.", this));
7else
8time = $string_utils:from_seconds(idle);
9player:tell($gender_utils:pronoun_sub("%{:He} %{!is} awake, but %{!has} been staring off into space for ", this), time, ".");
10endif

@he*alth

Spec none none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1"Usage: @health => tells you your current health level as a percentage of your maximum potential health.";
2current = player.stats_current[2][4];
3max = player.stats[2][4];
4if (max != 0.0)
5health = 100.0 * (current / max);
6pointer = (toint(health) / 3) + 11;
7pointer = (pointer > 22) ? pointer + 8 | pointer;
8pointer = (pointer > 41) ? pointer + 7 | pointer;
9bar = "[bold][red]-----------[yellow]-----------[green]----------- [normal]";
10bar[pointer] = "|";
11player:tell(bar, floatstr(health, 2), "%");
12else
13player:tell("You are completely dead.");
14endif

die

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"Moves player to afterlife.";
2"WIZ PERMS!";
3if (this.programmer)
4return this.stats_current[2][4] = this.stats_current[2][4] + 0.01;
5endif
6who = (length(callers()) < 2) ? player | callers()[2][3];
7trustees = {this.owner};
8for x in ($object_utils:ancestors(this))
9trustees = setadd(trustees, x.owner);
10endfor
11for x in ($object_utils:ancestors(this.location))
12trustees = setadd(trustees, x.owner);
13endfor
14if ((!(who in trustees)) && (!who.wizard))
15"Bogus killer";
16return;
17elseif (!this.alive)
18"already dead";
19return this:pass_out();
20endif
21this.alive = 0;
22this.location:announce_all_but({this}, $string_utils:pronoun_sub(this.death_msg, this));
23this:tell("The world around you fades to black, and you feel light as a feather.");
24deathscene = this.location;
25this.alert = 0;
26this:dump_followers();
27fork (7)
28deathscene:announce_all("The corpse of ", this:title(), " dissolves quickly.");
29this:dump_goodies(1);
30this.alert = 1;
31this:tell("A pinhole of light appears above you, enlarging as you float toward it.");
32this:tell(" ");
33this.x_loc = (this.x_loc < 1) ? 1 | this.x_loc;
34this.y_loc = (this.y_loc < 1) ? 1 | this.y_loc;
35move(this, $dead_zone);
36this.location:announce_all_but({this}, this:titlec(), "(yes, quite dead) has arrived.");
37if (parent(this) == $rpgamer)
38for item in (setremove(this.owned_objects, this))
39$wiz_utils:set_owner(item, $default_holder);
40endfor
41endif
42endfork
43this.free_points = 0.0;
44this.stats = {{"Strength", "Dexterity", "Intelligence", "Health"}, {0.0, 0.0, 0.0, 0.0}};
45this.stats_current = {{"Strength", "Dexterity", "Intelligence", "Health"}, {0.0, 0.0, 0.0, 0.0}};
46n = length(this.skills[2]);
47for z in [1..n]
48this.skills[2][z] = 0.0;
49endfor
50this.remembered_names = {};
51this.languages = {{$lang_utils.default_lang}, {2.0}};
52brats = children($rpgamer);
53for x in (brats)
54if (ghost = this in $list_utils:slice(x.remembered_names, 1))
55x.remembered_names = setremove(x.remembered_names, x.remembered_names[ghost]);
56endif
57(ticks_left() < 5000) && suspend(0);
58endfor

_wield

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

none

Source

1"Wield arg[1]";
2return this.wielded = args[1];

pass_out

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1"Bye-bye land for 60 seconds";
2if (this.alert)
3this.location:announce_all_but({this}, $string_utils:pronoun_sub("%N %<falls> unconscious.", this));
4this:tell("You fall unconscious.");
5this.alert = 0;
6fork (60)
7this.alert = 1;
8if (this.alive)
9this.location:announce_all_but({this}, $string_utils:pronoun_sub("%N %<awakens> from unconsciousness.", this));
10this:tell("You awaken.");
11endif
12endfork
13endif

freeze

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1"Paralysis for 60 seconds";
2if (this.mobile)
3this.location:announce_all_but({this}, $string_utils:pronoun_sub("%N %<becomes> immobilized.", this));
4this:tell("You become immobilized.");
5this.mobile = 0;
6fork (60)
7this.mobile = 1;
8if (this.alive && this.alert)
9this.location:announce_all_but({this}, $string_utils:pronoun_sub("%N %<regains> mobility.", this));
10this:tell("You regain mobility.");
11endif
12endfork
13endif

take_hit

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

none

Source

1"USAGE: victim:take_hit(damage[, attacker])";
2damage = tofloat(args[1]);
3if (!(this in connected_players()))
4if ((length(args) > 1) && valid(args[2]))
5x = args[2];
6else
7x = player;
8endif
9$you:say_action2(x, this, "%N %<recoils> from a shockwave, caused by %p blow to the stasis field surrounding %d.");
10x.stats_current[2][4] = x.stats_current[2][4] - damage;
11return this.stats_current[2][4];
12endif
13if ((((caller == this.location) || (caller == this.owner)) || `caller.hostility ! E_PROPNF => 0') || `caller.weapon ! E_PROPNF => 0')
14damage = ((x = damage - this:armor()) > 0.1) ? x | 0.1;
15this.stats_current[2][4] = this.stats_current[2][4] - damage;
16if (this.stats_current[2][4] < 0.0)
17this:die();
18endif
19endif
20return this.stats_current[2][4];

take_health

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

none

Source

1"USAGE: beneficiary:take_health(healing points)";
2this.stats_current[2][4] = this.stats_current[2][4] + tofloat(args[1]);
3return this.stats_current[2][4] = (this.stats_current[2][4] < this.stats[2][4]) ? this.stats_current[2][4] | this.stats[2][4];

armor

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1armor = 0.0;
2for x in (this:contents())
3if (`x.wornness ! E_PROPNF => 0')
4armor = armor + x:shield_rating();
5endif
6endfor
7return armor;

damage

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: assailant:damage([any])";
2"Returns wielded weapon damage, modified by strength.";
3"If missle weapon is used, returns just weapon damage.";
4"If no args are sent, damage will vary up or down from the base by a 25% margin.";
5"If there are additional combat skills affecting damage, this is the verb to hack.";
6if (!valid(this.wielded))
7damage = this.damage_base;
8else
9damage = this.wielded.shoots ? this.wielded.projectile_dam | (this.wielded.damage_base + ((this.stats_current[2][1] - 10.0) / 3.142));
10endif
11moddam = random(5);
12if ((moddam = 1) && (!args))
13damage = damage - (damage * 0.25);
14elseif ((moddam = 5) && (!args))
15damage = damage + (damage * 0.25);
16endif
17return (damage > 0.0) ? damage | 0.1;

to_hit

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"If missle weapon, returns dexterity, modified by basic combat skill";
2"If not, returns average strength & dexterity, modified by combat skill";
3"If there are additional skills affecting striking accuracy, this is the verb to hack.";
4combat = "combat" in this.skills[1];
5if (valid(this.wielded) && this.wielded.shoots)
6attack = this.stats_current[2][2] + sqrt(this.skills[2][combat]);
7else
8attack = ((this.stats_current[2][2] + this.stats_current[2][1]) / 2.0) + sqrt(this.skills[2][combat]);
9endif
10return (attack > 0.0) ? attack | 0.1;

to_defend

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"Returns dexterity, modified by basic combat skill.";
2"Compared to to_hit(), combat skill has only half the effect.";
3"This:armor() likewise has only half the effect it does on take_hit().";
4combat = "combat" in this.skills[1];
5dex = (((!(this in connected_players())) || (!this.alert)) || (!this.mobile)) ? 0.1 | this.stats_current[2][2];
6defense = (dex + (sqrt(this.skills[2][combat]) / 2.0)) + (this:armor() / 2.0);
7return (defense > 0.0) ? defense | 0.1;

tell

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1"Enforces unconsciousness.";
2"Only verbs using 'notify' should get through.";
3if (this.alert || (player == this))
4if ((caller == this.location) && (!this.alert))
5return;
6elseif (((caller == $channels) || this.gaglist) || this.paranoid)
7pass(@args);
8else
9newargs = args;
10if ((this != player) && (generic = `player:short_desc_msg() ! E_VERBNF => player:title()'))
11if (i = player in $list_utils:slice(this.remembered_names, 1))
12generic = this.remembered_names[i][2];
13endif
14for x in [1..length(newargs)]
15newarg = tostr(newargs[x]);
16if (start = index(newarg, player:titlec()))
17if (start == 1)
18newargs[x] = $string_utils:subst(newarg, {{player:titlec(), $string_utils:capitalize(generic)}});
19else
20newargs[x] = $string_utils:subst(newarg, {{player:title(), generic}});
21endif
22endif
23endfor
24endif
25this:notify(tostr(@newargs));
26endif
27endif
28return;

title

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1name = `i = this in $list_utils:slice(player.remembered_names, 1) ! ANY => 0' ? player.remembered_names[i][2] | `this:short_desc_msg() ! E_VERBNF => this.name';
2title = (x = name in $list_utils:slice(this.ansi_title, 1)) ? this.ansi_title[x][2] | name;
3blurb = "";
4if (this in connected_players())
5if (!this.alive)
6blurb = "dead";
7elseif (!this.alert)
8blurb = "unconscious";
9elseif (!this.mobile)
10blurb = "immobilized";
11elseif ((this.stats_current[2][4] / (this.stats[2][4] + 0.0001)) < 0.75)
12blurb = "injured";
13elseif (idle_seconds(this) > 120)
14blurb = "idle";
15elseif (this.stats_current[2][3] < 1.75)
16blurb = "drooling";
17endif
18elseif (!($puppet in $object_utils:ancestors(this)))
19blurb = "asleep";
20endif
21title = blurb ? tostr(title, "(", blurb, ")") | title;
22return title;

say

Spec any any anyFlags rxdOwner #2Definer #91

Referenced by

none

Source

1if ($object_utils:has_callable_verb(this.location, "say") != {$room})
2return this.location:(verb)(@args);
3else
4argstr = $ansi_utils:terminate_normal(argstr);
5endif
6sayverb = $string_utils:get_say_verb(argstr);
7this:tell("You ", $you:verb_sub(sayverb), ", \"", argstr, "\" ", $lang_utils:in_line_for($lang_utils:speaking(this), this));
8$lang_utils:announce(this, setremove(this.location:contents(), this), tostr(this:titlec(), " ", $gender_utils:get_conj(sayverb, this), ", \"%lang_encrypt\""), argstr);

emote

Spec any any anyFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ PERMS";
2if ($object_utils:has_callable_verb(this.location, "emote") != {$room})
3return this.location:(verb)(@args);
4endif
5if (argstr && (argstr[1] == ":"))
6argstr[1..1] = "";
7else
8argstr[1..0] = " ";
9endif
10this.location:announce_all(this:title(), argstr);

reached_limit

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1"Returns true if this player can hold no more";
2if ($frand_class in $object_utils:ancestors(this))
3return 0;
4endif
5allstuff = {};
6lightstuff = 0.0;
7for item in (this:contents())
8if ($container in $object_utils:ancestors(item))
9allstuff = {@allstuff, @item.contents};
10elseif ($note in $object_utils:ancestors(item))
11lightstuff = lightstuff + 0.5;
12endif
13allstuff = {@allstuff, item};
14endfor
15weight = length(allstuff) - $math_utils:round(lightstuff);
16return (weight > $math_utils:round(1.5 * this.stats_current[2][1])) ? 1 | 0;

my_huh

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ PERMS";
2if (((args[1] in {"g", "get", "t", "take"}) && dobjstr) && prepstr)
3player:tell($string_utils:capitalize(prepstr), " what? Try just \"", args[1], " ", dobjstr, "\".");
4kill_task(task_id());
5else
6return pass(@args);
7endif

g*et t*ake

Spec any none noneFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ PERMS";
2if (this:reached_limit())
3return this:tell("You can't carry any more.");
4elseif (dobjstr in {"all", "everything"})
5for o in (this.location:contents())
6if (`!o.gender ! E_PROPNF => 1')
7`o:g(@args) ! ANY => ""';
8endif
9endfor
10return player:tell("Done.");
11endif
12dobj = (!valid(dobj)) ? $match_utils:match(dobjstr, this.location:contents()) | dobj;
13if (dobj == $failed_match)
14parsed = $string_utils:first_word(dobjstr);
15amount = parsed[1];
16stuff = parsed[2];
17object = toint(amount) ? $match_utils:match(stuff, this.location:contents()) | dobj;
18if (valid(object))
19dobj = object;
20this:tell("You take all ", dobj:title(), ". (Drop what you don't want.)");
21endif
22endif
23if (!(dobj in players()))
24if (valid(dobj) && $object_utils:has_verb(dobj, verb))
25if ($player in $object_utils:ancestors(dobj))
26return player:tell("You can't pick up people!");
27endif
28return dobj:(verb)(@args);
29endif
30if (dobjstr && `this.location:match_fake(dobjstr) ! E_VERBNF => ""')
31return player:tell($string_utils:capitalize(dobjstr), " will not move.");
32endif
33$command_utils:do_huh(verb, args);
34else
35player:tell("You can't pick up a player.");
36endif

dr*op th*row

Spec any none noneFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ PERMS";
2if (dobjstr in {"all", "everything"})
3for o in (this:contents())
4if (`!o.gender ! E_PROPNF => 1')
5`o:dr(@args) ! ANY => ""';
6endif
7endfor
8return player:tell("Done.");
9endif
10dobj = (!valid(dobj)) ? $match_utils:match(dobjstr, this:contents()) | dobj;
11if (valid(dobj) && $object_utils:has_verb(dobj, verb))
12if ($object_utils:has_property(dobj, "linelen"))
13return player:tell("I'm sorry... Were we dating?");
14elseif ($object_utils:has_property(dobj, "x_loc"))
15dobj.x_loc = this.x_loc;
16dobj.y_loc = this.y_loc;
17endif
18return dobj:(verb)(@args);
19endif
20if (parsed = $string_utils:first_word(dobjstr))
21amount = parsed[1];
22stuff = parsed[2];
23if (!$money_utils:_has_currency(stuff))
24if (toint(amount))
25ammo = this:match(stuff);
26collect = $object_utils:has_property(ammo, "rounds") || $object_utils:has_property(ammo, "units");
27if (valid(ammo) && collect)
28if ($object_utils:has_property(ammo, "x_loc"))
29ammo.x_loc = this.x_loc;
30ammo.y_loc = this.y_loc;
31endif
32return this:transfer_ammo(amount, ammo, this.location);
33elseif (ammo == $ambiguous_match)
34return this:tell("There are a couple of things named \"", stuff, "\" around.");
35elseif (dobj == $ambiguous_match)
36return this:tell("You have a couple of things named \"", dobjstr, "\" on you.");
37else
38return this:tell("You really don't have ", dobjstr, " to spare, do you?");
39endif
40endif
41elseif (toint(amount))
42return this:tell("Why would you throw away good money?");
43endif
44if ($object_utils:has_property(dobj, "x_loc"))
45dobj.x_loc = this.x_loc;
46dobj.y_loc = this.y_loc;
47endif
48$command_utils:do_huh(verb, args);
49else
50return player:tell($string_utils:capitalize(verb), " what?");
51endif

gi*ve ha*nd pay

Spec any at/to anyFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"WIZ PERMS";
2if ((player != this.owner) && (player != this))
3return player:tell(tostr(E_PERM));
4elseif (dobjstr in {"all", "everything"})
5for o in (this:contents())
6if (`!o.gender ! E_PROPNF => 1')
7`o:gi(@args) ! ANY => ""';
8endif
9endfor
10return player:tell("Done.");
11endif
12dobj = (!valid(dobj)) ? $match_utils:match(dobjstr, this:contents()) | dobj;
13if (valid(dobj) && $object_utils:has_verb(dobj, verb))
14if (valid(iobj) && $object_utils:has_property(iobj, "stats_current"))
15if (iobj:reached_limit())
16return this:tell(iobj:titlec(), " cannot carry any more.");
17endif
18endif
19return dobj:(verb)(args[2]);
20endif
21args = setremove(args, "to");
22person = $match_utils:match(iobjstr, player.location:contents());
23if (!valid(person))
24if ($object_utils:has_verb(this.location, "match_fake") && this.location:match_fake(iobjstr))
25return player:tell($string_utils:capitalize(iobjstr), " ignores your offer.");
26endif
27return $rp_regulator:person_match_failed(person, iobjstr);
28elseif (person.location != this.location)
29return player:tell("I don't see that person here.");
30elseif (toint(args[1]) < 0)
31return player:tell("You can't give a negative amount.");
32elseif (!$money_utils:_has_currency(args[2]))
33if (toint(args[1]))
34c = {@this:contents(), @this.location:contents()};
35ammo = $string_utils:match(args[2], c, "name", c, "aliases");
36collect = $object_utils:has_property(ammo, "rounds") || $object_utils:has_property(ammo, "units");
37if (valid(ammo) && collect)
38return this:transfer_ammo(args[1], ammo, person);
39elseif (ammo == $ambiguous_match)
40return player:tell("There are a couple of things named \"", args[2], "\" around.");
41elseif (dobj == $ambiguous_match)
42return player:tell("You have a couple of things named \"", dobjstr, "\" on you.");
43else
44return player:tell("You really don't have ", dobjstr, " to spare, do you?");
45endif
46endif
47elseif (toint(args[1]))
48if (!$object_utils:has_callable_verb(person, "_add_money"))
49return player:tell(person:titlec(), " can't accept that.");
50endif
51left = this:_rem_money(args[2], tofloat(args[1]));
52if (left != 0)
53return this:tell("You don't have that many ", args[2], ".");
54endif
55person:_add_money(args[2], tofloat(args[1]));
56this.location:announce_all_but({this, person}, this:title(), " hands some money to ", person:title(), ".");
57this:tell("You pay ", args[1], " ", args[2], " to ", person:title(), ".");
58return person:tell(this:title(), " pays ", args[1], " ", args[2], " to you.");
59endif
60$command_utils:do_huh(verb, args);

conv*ert

Spec any at/to anyFlags rdOwner #36Definer #91

Referenced by

none

Source

1"conv <amount> <currency1> to <currency2> => does mathematical (not actual) conversion";
2args = setremove(args, "to");
3is_real = $money_utils:_has_currency(args[2]);
4if (length(args) < 3)
5return this:tell("...to which currency?");
6elseif (this.stats_current[2][3] < 5.75)
7return this:tell("You don't know the math needed to convert currencies.");
8endif
9also_real = $money_utils:_has_currency(args[3]);
10amount = toint(args[1]) ? tofloat(args[1]) | 0.0;
11if ((is_real && also_real) && (amount > 0.0))
12tvalue = $money_utils:_from_to(args[2], args[3], amount);
13this:tell(args[1], " ", args[2], " = ", floatstr(tvalue, 2), " ", args[3]);
14else
15this:tell("Cannot convert - Invalid input.");
16endif

transfer_ammo

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: transfer_ammo(amount,source,recipient)";
2"WIZ PERMS";
3amount = toint(args[1]);
4source = args[2];
5recipient = args[3];
6prop = $object_utils:has_property(source, "rounds") ? "rounds" | "units";
7clip = #-1;
8if ((this.location == recipient.location) || (this.location == recipient))
9for x in (recipient:contents())
10if (parent(x) == parent(source))
11clip = x;
12endif
13endfor
14if ((amount > 0) && (amount <= source.(prop)))
15if (!valid(clip))
16gen = source.f ? source | parent(source);
17nclip = $recycler:_create(gen, $default_holder);
18$building_utils:set_names(nclip, $string_utils:from_list(source.aliases, ","));
19nclip.(prop) = 0;
20nclip:moveto(recipient);
21clip = nclip;
22endif
23for z in [1..amount]
24if (source.(prop) > 0)
25clip.(prop) = clip.(prop) + 1;
26source.(prop) = source.(prop) - 1;
27endif
28endfor
29if (`this.currency ! E_PROPNF => 0')
30this.location:announce_all(this:titlec(), " counts out ", args[1], " ", source:title(), ".");
31elseif (this.location == recipient)
32$you:say_action(tostr("%N %<drops> ", args[1], " ", source:title(), "."));
33else
34$you:say_action(tostr("%N %<gives> ", args[1], " ", source:title(), " to %i."));
35endif
36fork (1)
37$object_utils:isa(clip, $ammo) ? clip:combine() | "already absorbed";
38endfork
39else
40this:tell("You don't have that many to spare.");
41endif
42else
43this:tell(recipient:titlec(), " is not here.");
44endif

description

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1return this.description ? this.description | "You see an ordinary person.";

@kids @s*how @verbs @props @properties @exam*ine exam*ine where*is @where*is home

Spec any none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1if (verb in {"exam", "examine"})
2if (valid(dobj))
3if (`dobj.location in {player, player.location} ! ANY => 0' || $object_utils:isa(this, $frand_class))
4dobj:do_examine(this);
5endif
6elseif (dobj == $ambiguous_match)
7this:tell("Which one?");
8elseif (dobj == $failed_match)
9if (fakeobj = `this.location:match_fake(dobjstr) ! ANY => 0')
10if (fakeobj == {"seat"})
11this:tell_lines(this.location.seat_desc);
12elseif (fakeobj == {"pool"})
13this:tell_lines(this.location.pool_desc);
14else
15return this:tell_lines(fakeobj);
16endif
17return this.location:who_do_what();
18else
19this:tell("That object is not here.");
20endif
21endif
22elseif (parent(this) != $rpgamer)
23return `this:(verb)(@args) ! E_VERBNF => ""';
24else
25player:tell("I don't understand that.");
26endif

@stats @score @points @skills

Spec none none noneFlags rxdOwner #2Definer #91

Referenced by

Source

1"@stats, @score, @points, @skills -- tells you your current stats and skills.";
2bar = $string_utils:space(player:linelen() - 13, "_");
3ST = tostr(floatstr(this.stats_current[2][1], 2), "/", floatstr(this.stats[2][1], 2));
4spacer = $string_utils:space((player:linelen() / 2) - (19 + length(ST)), " ");
5ST = tostr("STRENGTH", spacer, ST);
6DX = tostr(floatstr(this.stats_current[2][2], 2), "/", floatstr(this.stats[2][2], 2));
7spacer = $string_utils:space((player:linelen() / 2) - (20 + length(DX)), " ");
8DX = tostr("DEXTERITY", spacer, DX);
9IQ = tostr(floatstr(this.stats_current[2][3], 2), "/", floatstr(this.stats[2][3], 2));
10spacer = $string_utils:space((player:linelen() / 2) - (23 + length(IQ)), " ");
11IQ = tostr("INTELLIGENCE", spacer, IQ);
12HT = tostr(floatstr(this.stats_current[2][4], 2), "/", floatstr(this.stats[2][4], 2));
13spacer = $string_utils:space((player:linelen() / 2) - (17 + length(HT)), " ");
14HT = tostr("HEALTH", spacer, HT);
15spacer = $string_utils:space((player:linelen() / 2) - 20, ".");
16info = tostr(spacer, "CUR/MAX");
17header = $string_utils:columnize({info, info}, 2, player:linelen() - 4);
18stats = $string_utils:columnize({ST, DX, IQ, HT}, 2, player:linelen() - 4);
19skills = {};
20for index in [1..length(this.skills[1])]
21name = this.skills[1][index];
22value = floatstr(this.skills[2][index], 2);
23spacer = $string_utils:space((player:linelen() / 2) - ((12 + length(name)) + length(value)), " ");
24skills = {@skills, tostr(name, spacer, value)};
25endfor
26skills = $string_utils:columnize(skills, 2, player:linelen() - 4);
27stathead = tostr("STATISTICS", $string_utils:space(player:linelen() - 23, "_"));
28skillhead = tostr("SKILLS", $string_utils:space(player:linelen() - 19, "_"));
29to_hit = tostr("attack roll  => ", floatstr(this:to_hit(), 2), " or less");
30to_defend = tostr("defense roll => ", floatstr(this:to_defend(), 2), " or less");
31damage_base = tostr("damage base  => ", floatstr(this:damage(1), 2));
32free_points = tostr("free points  => ", floatstr(this.free_points, 2));
33extra = $string_utils:columnize({to_hit, to_defend, damage_base, free_points}, 2, player:linelen() - 4);
34speakl = underl = {};
35for lin in [1..length(this.languages[1])]
36if (this.languages[2][lin] >= 2.0)
37speakl = {@speakl, this.languages[1][lin].lang_name};
38elseif (this.languages[2][lin] >= 1.0)
39underl = {@underl, this.languages[1][lin].lang_name};
40endif
41endfor
42speaks = $string_utils:english_list(speakl);
43unders = $string_utils:english_list(underl);
44speaks = (speaks == "nothing") ? "Proficient in no languages." | ("Speaks: " + speaks);
45unders = (unders == "nothing") ? "" | ("Understands some: " + unders);
46display = {tostr("===== ", this:titlec(), " (", this.gender, " ", this.race, ") ======"), " ", stathead, @header, @stats, bar, skillhead, @skills, bar, @extra, " ", tostr(this.org, " Member. ", speaks, " ", unders)};
47player:tell_lines(display);

@boost

Spec any at/to anyFlags rdOwner #2Definer #91

Referenced by

none

Source

1"USAGE: @boost <stat/skill> to <level>";
2"       <level> can be a number, or the word 'maximum' ('max')";
3if (`player.location == $local.chargen ! ANY => 0' && ($local.chargen.type == "choice"))
4return player:tell("Use \"set\" while generating your character.");
5elseif (length(parsed = $rp_regulator:parse_stat_level(dobjstr, iobjstr, player)) == 3)
6{kind, index, newlevel} = parsed;
7else
8if (!(iobjstr in {"max", "maximum"}))
9player:tell(E_INVARG);
10endif
11return;
12endif
13if (kind == "stat")
14if (newlevel < player.stats[2][index])
15return player:tell("You cannot lower statistics to gain points.");
16endif
17player.free_points = player.free_points + ($rp_regulator:boost_mod(player.stats[1][index], this) * $rp_regulator:statcost(player.stats[2][index]));
18newcost = $rp_regulator:boost_mod(player.stats[1][index], this) * $rp_regulator:statcost(newlevel);
19if (newcost <= player.free_points)
20player.free_points = player.free_points - newcost;
21curdif = newlevel - player.stats[2][index];
22player.stats_current[2][index] = curdif + player.stats_current[2][index];
23player.stats[2][index] = newlevel;
24player:tell(player.stats[1][index], " => ", floatstr(newlevel, 2));
25else
26player.free_points = player.free_points - ($rp_regulator:boost_mod(player.stats[1][index], this) * $rp_regulator:statcost(player.stats[2][index]));
27player:tell("You don't have enough points for that change.");
28endif
29else
30if (newlevel < player.skills[2][index])
31return player:tell("You cannot lower skills to gain points.");
32endif
33minskill = (dobjstr == "ki") ? 0.2 | 0.0;
34if (player.skills[2][index] <= minskill)
35return player:tell("You can't boost skills in which you don't have minimum proficiency.");
36endif
37player.free_points = player.free_points + ($rp_regulator:boost_mod(player.skills[1][index], this) * $rp_regulator:skillcost(player.skills[2][index]));
38newcost = $rp_regulator:boost_mod(player.skills[1][index], this) * $rp_regulator:skillcost(newlevel);
39if (newcost <= player.free_points)
40player.free_points = player.free_points - newcost;
41player.skills[2][index] = newlevel;
42player:tell(player.skills[1][index], " => ", floatstr(newlevel, 2));
43else
44player.free_points = player.free_points - ($rp_regulator:boost_mod(player.skills[1][index], this) * $rp_regulator:skillcost(player.skills[2][index]));
45player:tell("You don't have enough points for that change.");
46endif
47endif

@send @answer @repl*y

Spec any any anyFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"This verb uses a property 'sanctuary', already on the combat room.";
2"(room.sanctuary == 0) => combat allowed.";
3"(room.sanctuary == 1) => combat forbidden.";
4"(room.sanctuary == 2) => combat forbidden and mailing allowed.";
5if (`!(!property_info(this.location, "sanctuary")) ! E_PROPNF => 0')
6if ((this.location.sanctuary == 2) || (parent(this) != $rpgamer))
7return pass(@args);
8endif
9this:tell("You can't find a good place to compose your letter.");
10if ($command_utils:yes_or_no("Do you want to send a quick note (no editing)?"))
11if (args && (args[1] == "to"))
12args = listdelete(args, 1);
13endif
14subject = {};
15for a in (args)
16if (((i = index(a, "=")) > 3) && (index("subject", a[1..i - 1]) == 1))
17args = setremove(args, a);
18a[1..i] = "";
19subject = {a};
20endif
21endfor
22rcpts = $mail_editor:parse_recipients({}, args) || $mail_editor:parse_recipients({}, $command_utils:read("mail recipients"));
23if (rcpts)
24subj = $command_utils:read("subject");
25if (subj)
26this:tell("Enter your message below:");
27if (text = $command_utils:read_lines())
28return $mail_agent:send_message(this, rcpts, subj, text) && this:tell("Mail sent.");
29endif
30endif
31endif
32return this:tell("Session aborted.");
33else
34if (valid(realm = this.location.location))
35realm = $object_utils:isa(realm, $realm) ? realm | realm.location;
36realm = $object_utils:isa(realm, $realm) ? realm | $nothing;
37postals = {};
38for p in (realm.contents)
39postals = ($object_utils:isa(p, $rpg_room) && (p.sanctuary == 2)) ? {@postals, p} | postals;
40endfor
41this:tell("Mail terminals in the area: ", $string_utils:nn(postals));
42endif
43return;
44endif
45endif
46pass(@args);

cash money

Spec none none noneFlags rdOwner #36Definer #91

Referenced by

none

Source

1"USAGE: money => tells you what kind of currency you are carrying and how much.";
2"       See also \"help convert\".";
3if (this.money == {})
4this:tell("You have no money.");
5elseif (this.stats_current[2][3] < 4.25)
6this:tell("You don't know how to count money.");
7else
8this:tell("===============  Cash  ==================");
9this:tell_lines($string_utils:columnize({"Currency", "Amount"}, 3));
10cash = 0.0;
11for x in (this.money)
12this:tell_lines($string_utils:columnize({x[1], floatstr(x[2], 2)}, 3));
13cash = cash + $money_utils:_from_to(x[1], $money_utils:match_org(this.org), x[2]);
14endfor
15this:tell("=========================================");
16this:tell("== Total value: ", floatstr(cash, 2), " ", $money_utils:match_org(this.org), " ==");
17endif

my_match_object

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1if (parent(this) != $rpgamer)
2return pass(@args);
3endif
4o = pass(@args);
5if (`o.location == player ! E_INVIND => 0')
6return o;
7endif
8return (valid(o) && (!valid(player.location:match(args[1])))) ? $failed_match | o;

medical

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: healer:medical()";
2"Returns intelligence level, modified by medical skill.";
3"If there are additional skills affecting healing, this is the verb to hack.";
4medical = "medical" in this.skills[1];
5return (0.667 * this.stats_current[2][3]) + (1.5 * this.skills[2][medical]);

@features

Spec any for/about anyFlags rxdOwner #2Definer #91

Referenced by

none

Source

1if (parent(this) == $rpgamer)
2features = {};
3for feature in (this.features)
4if (!valid(feature))
5this:remove_feature(feature);
6else
7features = listappend(features, feature);
8endif
9endfor
10if (features)
11len = max(length("Feature"), length(tostr(max_object()))) + 1;
12player:tell("These features may contain help files for their use. Type \"? <#feature>\" to access that information.");
13player:tell($string_utils:left("Feature", len), "Name");
14player:tell($string_utils:left("-------", len), "----");
15for feature in (features)
16player:tell($string_utils:left(tostr(feature), len), feature.name);
17endfor
18player:tell($string_utils:left("-------", len), "----");
19endif
20player:tell(length(features), " feature", (length(features) > 1) ? "s" | "", " found.");
21else
22pass(@args);
23endif

@add-feature @addfeature @remove-feature @rmfeature

Spec any none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1if (parent(this) == $rpgamer)
2return player:notify("Sorry, only a wizard can add or remove your features on this MOO.");
3elseif (caller == this)
4pass(@args);
5endif

_add_money _rem_money

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1"USAGE: _add_money(currency, amount) or _rem_money(currency, amount)";
2"       _rem_money returns 1 if unsucessful.";
3plus = (verb == "_add_money") ? 1 | 0;
4if (m = args[1] in $list_utils:slice(this.money))
5if (plus)
6this.money[m][2] = this.money[m][2] + tofloat(args[2]);
7elseif ((leftover = this.money[m][2] - tofloat(args[2])) >= 0.0)
8this.money[m][2] = leftover;
9return 0;
10else
11return 1;
12endif
13elseif (plus)
14this.money = {@this.money, {args[1], tofloat(args[2])}};
15endif
16return 1;

_has_amount

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: _has_amount(currency) => FLOAT";
2if (m = args[1] in $list_utils:slice(this.money))
3return this.money[m][2];
4else
5return 0.0;
6endif

_loot

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1if (player.location == this.location)
2if (this in connected_players())
3if ((!this.alert) || (!this.mobile))
4this:dump_goodies(1);
5$you:say_action("%N %<searches> %d for valuable goods.");
6this.location:tell_contents(setremove(this.location:contents(), player), this.location.ctype);
7else
8this:tell("You cautiously dodge ", player:title(), ", who is trying to steal from you.");
9player:tell(this:titlec(), " cautiously dodges your advance.");
10this.location:announce_all_but({this, player}, tostr(this:titlec(), " cautiously avoids ", player:title(), "."));
11endif
12else
13$you:say_action("%N %<attempts> to search %d for valuable goods, but %<is/are> deflected by a stasis field.");
14endif
15else
16player:tell("There is no \"", dobjstr, "\" here.");
17endif
18"WIZ PERMS";

roll_against

Spec this none thisFlags rxdOwner #2Definer #91

Referenced by

Source

1"USAGE: roll_against(StatOrSkillName or nothing, [modifier]) => Tests for successful action attempt. Skill points & free points are adjusted automatically.";
2"       => 0=failure, 1=success, 2=total success";
3"       optional [modifier] should be between 0.75 and 1.25, with higher numbers offering a greater chance of success.";
4"supports: strength, dexterity, intelligence, health, attack, defense, combat, medical, language, charismatic, necromatic, legerdemain, mechanical, pilot, command, search, vision, stealth";
5name = `args[1] ! E_RANGE => ""';
6level = 10.5;
7sk = 0;
8if (!name)
9"use defaults";
10elseif (i = name in this.stats[1])
11level = this.stats[2][i];
12sk = 0;
13elseif (name in {"combat", "attack"})
14sk = "combat" in this.skills[1];
15level = this:to_hit();
16elseif (name == "defense")
17sk = "combat" in this.skills[1];
18level = this:to_defend();
19elseif (name == "medical")
20level = this:medical();
21sk = name in this.skills[1];
22elseif (name in {"language", "necromatic", "mechanical"})
23level = this.stats_current[2][3] + `this.skills[2][sk = name in this.skills[1]] ! ANY => 0.0';
24elseif (name == "pilot")
25level = (((2.0 * this.stats_current[2][2]) + this.stats_current[2][3]) / 3.0) + `this.skills[2][sk = "vision" in this.skills[1]] ! ANY => 0.0';
26elseif (name in {"legerdemain", "stealth"})
27name = (sk = name in this.skills[1]) ? name | "legerdemain";
28level = this.stats_current[2][2] + `this.skills[2][sk = name in this.skills[1]] ! ANY => 0.0';
29elseif (name in {"charismatic", "command"})
30name = (sk = name in this.skills[1]) ? name | "charismatic";
31level = this.stats_current[2][3] + `this.skills[2][sk = name in this.skills[1]] ! ANY => 0.0';
32elseif (name in {"vision", "search"})
33name = (sk = name in this.skills[1]) ? name | "vision";
34level = (((this.stats_current[2][4] + this.stats_current[2][3]) + this.stats_current[2][2]) / 3.0) + `this.skills[2][sk = name in this.skills[1]] ! ANY => 0.0';
35else
36"use defaults";
37endif
38rec = {this, sk};
39if (m = `tofloat(args[2]) ! ANY => 0')
40modifier = (m > 1.25) ? 1.25 | m;
41modifier = (m < 0.75) ? 0.75 | m;
42else
43modifier = 1.0;
44endif
45roll = tofloat((random(6) + random(6)) + random(6)) / modifier;
46if ((roll < 5.0) || (roll < (level - 10.0)))
47hit = 2;
48elseif ((roll < level) && (roll < 16.0))
49hit = 1;
50else
51hit = 0;
52endif
53if (!(rec in $rp_regulator.rollers))
54if (sk)
55denom = ((lump = this.skills[2][sk]) >= 1.0) ? lump | 1.0;
56this.skills[2][sk] = this.skills[2][sk] + ((tofloat(hit) + 0.25) * (0.0005 / denom));
57endif
58this.free_points = this.free_points + ((tofloat(hit) + 0.5) * 0.0005);
59$rp_regulator.rollers = setadd($rp_regulator.rollers, rec);
60$scheduler:schedule(7, $rp_regulator, "remove_roller", {rec});
61endif
62return hit;

@roll

Spec any none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1"USAGE: @roll <StatOrSkillName or nothing> => Tests for successful action attempt.";
2"       => failure, success, or total success";
3"";
4"supports: strength, dexterity, intelligence, health, attack, defense, combat, medical, language, charismatic, necromatic, legerdemain, mechanical, pilot, command, search, vision, stealth";
5"";
6"Players may create their own roleplay rules and situations and use this verb to test for successful attempts.";
7b = $failed_match;
8skills = {"strength", "dexterity", "intelligence", "health", "attack", "defense", "combat", "medical", "language", "charismatic", "necromatic", "legerdemain", "mechanical", "pilot", "command", "search", "vision", "stealth"};
9if (dobjstr && (!(b = $string_utils:match_stringlist(dobjstr, skills))))
10if (!$command_utils:yes_or_no("This is not a valid roll option. Do you wish a standard success roll?"))
11return player:tell("[yellow]***[normal] @roll aborted [yellow]***[normal]");
12endif
13dobjstr = "";
14endif
15dobjstr = ((!typeof(b)) && b) ? skills[b] | dobjstr;
16success = this:roll_against(dobjstr);
17blurb = (!typeof(b)) ? "[yellow]***[normal] %N %<rolls> for " | "[yellow]***[normal] %N %<rolls> against the situation";
18if (!success)
19$you:say_action(tostr(blurb, dobjstr, " and %<fails>. [yellow]***[normal]"));
20elseif (success == 1)
21$you:say_action(tostr(blurb, dobjstr, " and %<succeeds>. [yellow]***[normal]"));
22else
23$you:say_action(tostr(blurb, dobjstr, " and [bold]totally[normal] %<succeeds>. [yellow]***[normal]"));
24endif

loot rob pilfer roll search strip

Spec this none noneFlags rxdOwner #2Definer #91

Referenced by

none

Source

1"USAGE: loot/rob/pilfer/roll/search/strip <person> => if person is knocked out, moves person.contents to the room.";
2this:_loot();

speak*ing

Spec any none noneFlags rdOwner #2Definer #91

Referenced by

none

Source

1if (dobjstr == "")
2player:Tell("You know the following languages:");
3player:Tell("-----------------------------------");
4n = 0;
5for l in ($lang_utils:can_speak_languages(player))
6(ticks_left() < 4000) && suspend(0);
7n = n + 1;
8player:tell(n, ". ", l.lang_name);
9endfor
10player:tell();
11player:tell("You are currently speaking ", $lang_utils:speaking(player).lang_name, ".");
12else
13n = call_function("tonum", dobjstr);
14langs = $lang_utils:can_speak_languages(player);
15if ((n == 0) || (n > length(langs)))
16m = $string_utils:match(dobjstr, langs, "lang_name");
17if (!valid(m))
18return player:Tell("You don't speak that language.");
19endif
20lang = m;
21else
22lang = langs[n];
23endif
24player.speaking = lang;
25player:Tell("You are now speaking ", lang.lang_name, ".");
26endif

remember

Spec any as anyFlags rdOwner #36Definer #91

Referenced by

none

Source

1rm = player.location:match(dobjstr);
2if (!valid(rm))
3return (rm == $ambiguous_match) ? player:Tell("There are too many things described as '", dobjstr, "'.") | player:Tell("I don't see any person described as '", dobjstr, "'.");
4elseif ((!($rpgamer in $object_utils:ancestors(rm))) || (player.owner != player))
5return player:Tell("You don't need to remember that.");
6endif
7rin = rm in $list_utils:slice(player.remembered_names, 1);
8if (rin)
9player:tell("You already have that person remembered as '", player.remembered_names[rin][2], "'.");
10if (!$command_utils:yes_or_no("Do you want to overwrite the old name?"))
11return player:tell("Okay. It will remain as '", player.remembered_names[rin][2], "'.");
12endif
13player.remembered_names = setremove(player.remembered_names, player.remembered_names[rin]);
14endif
15player.remembered_names = setadd(player.remembered_names, {rm, iobjstr});
16player:tell("Okay you now know that person as '", iobjstr, "'.");
17suspend(1);
18"clean out non-players";
19for r in (player.remembered_names)
20if (!($rpgamer in $object_utils:ancestors(r[1])))
21player.remembered_names = setremove(player.remembered_names, r);
22endif
23endfor

do_forget

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

none

Source

1remembered = this.remembered_names;
2{target} = args;
3index = $list_utils:iassoc(target, remembered, 1);
4if (!index)
5return 0;
6endif
7remembered = listdelete(remembered, index);
8this.remembered_names = remembered;
9return 1;

short_desc_matches

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

none

Source

1base = this:short_desc_msg();
2words = $string_utils:words(base);
3l = length(words);
4alist = {this.gender, this.race, (this.gender + " ") + this.race, (this.race + " ") + this.gender};
5for i in [1..l]
6alist = setadd(alist, $string_utils:from_list(words[i..l], " "));
7blist = $list_utils:remove_duplicates({words[i], words[l]});
8alist = setadd(alist, $string_utils:from_list(blist, " "));
9endfor
10return $list_utils:remove_duplicates(alist);

@remembered

Spec none none noneFlags rdOwner #36Definer #91

Referenced by

none

Source

1for r in (player.remembered_names)
2(ticks_left() < 500) && suspend(0);
3player:tell(r[2], ": ", `r[1]:short_desc_msg() ! ANY => "ERROR, contact a wizard about your .remembered_names list"');
4endfor
5player:tell();

short_desc_msg

Spec this none thisFlags rxdOwner #36Definer #91

Referenced by

Source

1return this.short_desc_msg ? this.short_desc_msg | tostr("a ", this.gender, " ", this.race);