generic corpse #2803
Aliases: generic corpse, corpse
8 verbs · 16 properties · 0 children
Verbs
| Verb | Spec | Flags | Definer | Lines |
|---|---|---|---|---|
set_victim | this none this | | #2803 | 7 |
accept | this none this | rx | #2803 | 2 |
rot_msg | this none this | | #2803 | 2 |
look_self | this none this | | #2803 | 24 |
tell_contents | this none this | | #2803 | 7 |
rot | this none this | rx | #2803 | 19 |
maybe_rot | this none this | rx | #2803 | 7 |
notify_arrival | this none this | rx | #2803 | 3 |
Properties
| Property | Definer | Flags | Owner | Value |
|---|---|---|---|---|
help_msg | #2803 | rc | — | value (441 chars){" ", "-- Brief overview of properties and verbs.", " ", ".victim -- Who is this pile of worm meal?", ".time_of_death -- When victim expired.", " ", ":set_victim(victim) -- What it says.", ":accept(what) -- Only accept objects on victim's person.", ":rot() -- Get rid of the corpse.", ":look_self() -- Maybe show how long it's been dead.", ":tell_contents() -- Neat display of loot."} |
victim | #2803 | r | — | #-1 |
time_of_death | #2803 | r | — | 949683881 |
is_corpse | #2803 | r | — | 1 |
lookers | #2803 | | — | not readable (E_PERM) |
store_action | #2803 | | — | "store" |
manufactured | #2803 | | — | 923451666 |
worth | #2803 | | — | -1 |
condition | #2803 | | — | E_NONE |
odrop_failed_msg | #2803 | | — | "%<tries> to drop %t but fails!" |
odrop_succeeded_msg | #2803 | | — | "%<drops> %t." |
otake_succeeded_msg | #2803 | | — | "%<picks> up %t." |
key | #2803 | | — | not readable (E_PERM) |
aliases | #2803 | | — | {"generic corpse", "corpse"} |
description | #2803 | | — | "The prototype of all festering corpses. Man--it really stinks." |
object_size | #2803 | | — | {6122, 1141286558} |
Ancestry
Ancestors (nearest first): #9338 generic RPG container → #2409 LRPG Adventuring Gear → #112297 Generic Dyable LRPG Thing → #517 Generic LRPG Thing
Children: none
Call graph
Source
set_victim
Referenced by
none
Source
1":set_victim(OBJ character)"; 2"Set whose soul this corpse previously contained."; 3if (!$local.rpg:trusted(caller_perms())) 4 return E_PERM; 5else 6 return this.victim = args[1]; 7endif
accept
Referenced by
none
Source
1"Accept items from `victim', or those belonging to victim's owner."; 2return ((!valid(victim = this.victim)) || (args[1].location == victim)) || $perm_utils:controls(victim.owner, args[1]);
rot_msg
Referenced by
- #2803:rot line 6:
this:rot_msg
Source
1":rot_msg() -- Messaged displayed when this corpse rots."; 2return this:title() + " collapses into dust and blows away in the wind.";
look_self
Referenced by
none
Source
1pass(@args); 2saw = 0; 3time = time(); 4recent = 0; 5newlookers = {}; 6for n in (this.lookers) 7 if (n[2] > (time - 600)) 8 if (n[1] == player) 9 recent = 1; 10 saw = n[3]; 11 else 12 newlookers = {@newlookers, n}; 13 endif 14 endif 15endfor 16if ((!recent) && ($local.rpg:resolve(player, "notice", -35) > 0)) 17 saw = 1; 18endif 19this.lookers = {@newlookers, {player, time, saw}}; 20if (saw) 21 player:tell("Your master forensic sense tells you that the unfortunate victim has been dead for about ", $string_utils:from_seconds(time() - this.time_of_death), "."); 22else 23 player:tell("Thousands of hours of `Quincy' reruns tell you that the unfortunate victim has been dead for about ", $string_utils:from_seconds(random(time())), "."); 24endif
tell_contents
Referenced by
none
Source
1":tell_contents([contents]) -- Show the loot."; 2if (c = args ? args[1] | this:contents()) 3 player:tell("Scattered around and upon the dead body you spot ", $string_utils:title_list(c), "."); 4else 5 player:tell("Hmm. No loot around. Maybe you CAN take it with you."); 6endif 7"Quinn 01-DEC-93 0407: Added provision for no loot.";
rot
Referenced by
- #2803:maybe_rot line 5:
this:rot
Source
1":rot_corpse() -- Rot this corpse and all it contains."; 2rpg = $local.rpg; 3if (!rpg:trusted(caller_perms())) 4 return E_PERM; 5endif 6rpg:rpg_announce_all(this.location, this:rot_msg()); 7stickit = rpg.cemetery; 8for loot in (this:contents()) 9 loot:moveto(stickit); 10endfor 11if (this.owner != rpg.owner) 12 this:moveto($nothing); 13elseif (verbs(this) || properties(this)) 14 return E_NACC; 15else 16 rpg.recycler:_recycle(this); 17endif 18"StarDancer 2-DEC-95 changed line 7 so all the stuff on the corpse goes to #1131. Also put :room_announce inside a fork so's it won't die if there're too many Ahabs inna room."; 19"Profane 1-DEC-96 1225PST -- nuke fork, put in rpg_announce_all";
maybe_rot
Referenced by
- #2803:notify_arrival line 2:
this:maybe_rot
Source
1":maybe_rot()"; 2"Rot if the .victim belonging to this corpse is .alive."; 3if (this.victim.alive || (this.victim.body != this)) 4 fork (0) 5 this:rot(); 6 endfork 7endif
notify_arrival
Referenced by
none
Source
1":notify_arrival(who, exit)"; 2this:maybe_rot(); 3return pass(@args);