generic ambient noisemaker #241

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

Aliases: generic ambient noisemaker

3 verbs · 19 properties · 0 children

Verbs

VerbSpecFlagsDefinerLines
look_place_msgthis none thisrxd#2411
heartbeatthis none thisrxd#2415
pulsethis none thisrxd#2418

Properties

PropertyDefinerFlagsOwnerValue
heart#241rc#3610
last_heartbeat#241rc#3610
noise_chance#241rc#3613
min_frequency#241rc#361180
last_noise_time#241r#3610
direction#241rc#361#-1
noise_msg#231rc#361<clear>
default_volume#231rc#361<clear>
color#231rc#361<clear>
aliases#1rc#361{"generic ambient noisemaker"}
description#1rc#361<clear>
object_size#1r#29{1823, 1298434525}
hidden_verbs#1rc#361<clear>
phelp_msg#1rc#361<clear>
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): #231 generic noise#1 root

Children: none

Call graph

calls n241_1 #241:heartbeat n241_2 #241:pulse n241_1->n241_2 n231_2 #231:sound_in n241_2->n231_2

Source

look_place_msg

Spec this none thisFlags rxdOwner #361Definer #241

Referenced by

none

Source

1return " ";

heartbeat

Spec this none thisFlags rxdOwner #361Definer #241

Referenced by

none

Source

1if (random(100) <= this.noise_chance)
2if ((time() - this.last_noise_time) >= this.min_frequency)
3this:pulse();
4endif
5endif

pulse

Spec this none thisFlags rxdOwner #361Definer #241

Referenced by

Source

1this.last_noise_time = time();
2if (valid(this.direction))
3where = this.direction.otherside.location;
4this:sound_in(where, this, {}, this.default_volume, this.direction.otherside);
5this.direction.otherside.location:make_noise(this, this.direction);
6else
7this.location:make_noise(this);
8endif