Find
You are looking at a buxom waittress called Gertrude
Gertrude stands wearily, waiting for an order.
talk to gertrude
Created by
thorn
, last updated 19 Jul 2012
Code
if target of talk then talked;
if target of push then pushed;
##pushed:
set $actor's class to 'buxom waittress';
set $actor's name to 'Gertrude';
##talked:
update $actor = "host=$init_obj,hosthow='near',pose='taking an order'";
say 'msg',"[$actor] goes to [$init_obj], 'So, what'll it be?'";
sayto $init_obj,"type: buy";
relook $loc;
##tickloc:runsub chkalive;
##chkalive:
if $actor's health > 0 then work;
##work:
if $loc_lit < 0 then lightacandle;
runsub work1/2;
##work1:
$slot3 = $actor's slot3;
if $slot3 eq 3 then checkt3 else work2;
##work2:
if $slot3 eq 2 then checkt2;
if $slot3 eq 1 then checkt1;
if $slot3 eq 0 then fixchairs;
##fixchairs:
$chair = "51916,51894,51895,51897,51898";
foreach in $chair do checkchair;
set $actor's slot3 to 1;
##checkchair:
$h = $list_line's host;
$s = $list_line's slot1;
if $s eq $h then continue else fixchair;
##fixchair:
update $list_line = "host=$s,hosthow='near'";
say 'msg',"Gertrude pushes [$list_line] towards [$s]";
relook $loc;
##checkt1:
$table = 51888;
runsub checktable;
set $actor's slot3 to 2;
##checkt2:
$table = 51893;
runsub checktable;
set $actor's slot3 to 3;
##checkt3:
$table = 51896;
runsub checktable;
set $actor's slot3 to 0;
##checktable:
$proc = 0;
$orderstate = $table's counter;
foreach in $table do processorder;
if $proc eq 0 then wipetable else nextstate;
##processorder:
if $for_id's counter eq $orderstate then po2;
$proc = 1;
##po2:
case $orderstate do makeorder,getorder,sellorder;
##makeorder:
say 'msg',"Gertrude gets an order for [$for_id]";
set $for_id's counter to 1;
update $actor = "host=$table,hosthow='taking orders near'";
set $actor's pose to '';
relook $loc;
##getorder:
say 'msg',"Jerry works on [$for_id]";
set $for_id's counter to 2;
##sellorder:
say 'msg',"Gertrude delivers [$for_id] to [$table]";
set $for_id's loc to $loc;
set $for_id's host to $table;
set $for_id's hosthow to 'on';
set $for_id's counter to 0;
update $actor = "host=$table,hosthow='near'";
set $actor's pose to '';
relook $loc;
##nextstate:
add 1 to $orderstate;
if $orderstate > 2 then zeroos;
set $table's counter to $orderstate;
##zeroos:
$orderstate = 0;
##wipetable:
runsub wipeit/4;
##wipeit:
$preverb = (begins,starts);
$verb = (wiping,polishing,emptying the ashtray at);
say 'msg',"Gertrude $preverb $verb [$table]";
set $actor's host to $table;
set $actor's hosthow to $verb;
set $actor's pose to '';
relook $loc;
##lightacandle:
print "light one?";
find $loc,candle;
if $found_id <1 then newcandle else lightanother;
##newcandle:
new "some candles";
set $new_id's host to 51888;
set $new_id's hosthow to 'on';
call "light $new_id";
##lightanother:
call "light $found_id";