generic powered thing #203

Parent #255Owner #361Flags read, fertileSource hellcore/hellcore.db

Aliases: generic powered thing, powered thing, thing

9 verbs · 54 properties · 2 children

Verbs

VerbSpecFlagsDefinerLines
plugthis in/inside/into nonerxd#2037
unplugthis none nonerxd#2037
is_onthis none thisrxd#2031
tree_tagthis none thisrxd#2032
chill_factorthis none thisrxd#2033
turn_on turn_off _lose_power _gain_power _break _repair_check has_power _plug moveto recycle find_powerplantthis none thisrxd#2032
look_selfthis none thisrxd#20312
_repairthis none thisrxd#2034
light_levelthis none thisrxd#2036

Properties

PropertyDefinerFlagsOwnerValue
on#203r#3610
turn_on_msg#203rc#361"%DN turns on %dt."
turn_off_msg#203rc#361"%DN turns off %dt."
switched_on#203r#3611
gain_power_msg#203rc#361"%DT suddenly turns on."
lose_power_msg#203rc#361"%DT suddenly turns off."
plugin_msg#203rc#361"You plug %dt into an outlet in %dl."
oplugin_msg#203rc#361"%DN plugs %dt into an outlet in %dl."
no_power_msg#203rc#361"%DN tries to turn on %dt but it doesn't seem to have any power."
powered_by#203rc#361#-1
unplug_msg#203rc#361"You unplug %dt."
ounplug_msg#203rc#361"%DN unplugs %dt."
always_on#203rc#3610
load#203rc#3611
light_level#203rc#3610
break_msg#255rc#361<clear>
repair_difficulty#255rc#361<clear>
junk_on_break#255rc#361<clear>
rename_on_break#255rc#361<clear>
smashable#255rc#361<clear>
repairable#255rc#361<clear>
armor#255rc#361<clear>
held_break_msg#255rc#361<clear>
oheld_break_msg#255rc#361<clear>
handed#5rc#361<clear>
wield_msg#5rc#361<clear>
unwield_msg#5rc#361<clear>
size#5rc#361<clear>
look_place_msg#5rc#361<clear>
value#5rc#361<clear>
get_msg#5rc#361<clear>
drop_msg#5rc#361<clear>
get_fail_msg#5rc#361<clear>
junk_ok#5rc#361<clear>
floats#5rc#361<clear>
long_name_msg#5rc#361<clear>
article#5rc#361<clear>
setup_list#5rc#361<clear>
health#5rc#3615
health_max#5rc#3615
min_skill#5rc#361<clear>
skill#5rc#361<clear>
recipe_for#5rc#361<clear>
carried_msg#5rc#361<clear>
aliases#1rc#361{"generic powered thing", "powered thing", "thing"}
description#1rc#361<clear>
object_size#1r#29{5936, 1298433820}
hidden_verbs#1rc#361<clear>
phelp_msg#1rc#361{"This item can be plugged into a wall socket to draw power. You probably won't find wall sockets outdoors, or in ruined areas -- try your apartment (or someone else's)."}
weight#1rc#361<clear>
owner_verbs#1rc#361<clear>
plural_name#1rc#361<clear>
client_image#1rc#361<clear>
listening#1rc#361<clear>

Ancestry

Ancestors (nearest first): #255 generic smashable thing#5 generic thing#1 root

Children: #173 generic hardware, #201 generic room light source

Call graph

calls n203_2 #203:is_on n203_5 #203:turn_on n203_2->n203_5 n203_3 #203:tree_tag n5_18 #5:tree_tag n203_3->n5_18 n20_2 #20:right n203_3->n20_2 n203_4 #203:chill_factor n255_8 #255:chill_factor n203_4->n255_8 n203_6 #203:look_self n255_2 #255:look_self n203_6->n255_2 n107_43 #107:tell n203_6->n107_43 n20_34 #20:pronoun_sub n203_6->n20_34 n203_7 #203:_repair n203_7->n203_5 n255_4 #255:_repair n203_7->n255_4 n203_8 #203:light_level n203_8->n203_2

Source

plug

Spec this in/inside/into noneFlags rxdOwner #361Definer #203

Referenced by

none

Source

10;
2"Automatically generated for the powered API.";
3if (length(args) && (args[1] == $implementing_interface.magic_pass_cookie))
4return pass(@listdelete(args, 1));
5else
6return $api.powered.implementation:(verb)(this, @args);
7endif

unplug

Spec this none noneFlags rxdOwner #361Definer #203

Referenced by

none

Source

10;
2"Automatically generated for the powered API.";
3if (length(args) && (args[1] == $implementing_interface.magic_pass_cookie))
4return pass(@listdelete(args, 1));
5else
6return $api.powered.implementation:(verb)(this, @args);
7endif

is_on

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

Source

1return (this.on || this.always_on) && this:has_power();

tree_tag

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

none

Source

1tag = pass(@args);
2return (tag + "  ") + tostr($ansi.cyan, $su:right(this.load, -7), $ansi.reset);

chill_factor

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

none

Source

1if (this.on)
2return pass(@args);
3endif

turn_on turn_off _lose_power _gain_power _break _repair_check has_power _plug moveto recycle find_powerplant

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

Source

1"Automatically generated for the powered API.";
2return $api.powered.implementation:(verb)(this, @args);

look_self

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

none

Source

1pass(@args);
2if (valid(this.powered_by))
3if (this.always_on)
4player:tell($su:ps("%S's plugged in.", this));
5elseif (this.on)
6player:tell($su:ps("%S's plugged in and turned on.", this));
7else
8player:tell($su:ps("%S's plugged into the wall, but turned off.", this));
9endif
10else
11player:tell($su:ps("%S's not plugged in or turned on.", this));
12endif

_repair

Spec this none thisFlags rxdOwner #361Definer #203

Referenced by

none

Source

1pass(@args);
2if ((this.health && (!this.on)) && this.always_on)
3this:turn_on();
4endif

light_level

Spec this none thisFlags rxdOwner #29Definer #203

Referenced by

none

Source

1"Copied from old flare (#113095):light_level by Chiyo (#143894) Wed Jul 29 02:15:52 2009 CDT";
2if (this:is_on() && this.light_level)
3return this.light_level;
4else
5return 0;
6endif