elevator_call_button.scr

lima-1.0b5/lib/domains/std/2.4.5/obj/elevator_call_button.scr · 596 B

From the archive lima-1.0b5+driver.tar.gz

Download the archive   « Back to the archive contents

# Do not remove the headers from this file! see /USAGE for more info.

is=object
variables=where
flag=attached
primary_adj=elevator
primary_id=button

setup[string w]:
  lpc
    _where = w

direct_press_obj:
  ok
end

---
void do_press() {
    int state = 0;

    this_body()->simple_action("$N $vpress the $o.", this_object());
    state = call_other("/domains/std/2.4.5/elevator", "call_elevator", _where);

    if(state) {
        tell_from_inside(environment(this_object()), "The lamp on the elevator button lights up.\n");
        environment(this_object())->set_room_state("lamp");
    }
}

Site Stats

Snippets: 1791
Codebases: 571