procedure start;
procedure do_stuff;
procedure ladderend;
procedure ladder01;
variable damage;
variable testa;
variable testb;
variable open;
variable dude_tile;
procedure start
begin
if (script_action == 6) then begin
load_map("VaultEnt.map", 1);
end
end
procedure do_stuff
begin
testa := do_check(dude_obj, 5, 2);
script_overrides;
call ladder01;
end
procedure ladderend
begin
end
procedure ladder01
begin
if (is_success(testa)) then begin
display_msg(message_str(291, 100));
end
else begin
if (is_critical(testa)) then begin
damage := random(1, 6) + random(1, 6) + random(1, 6) - 9;
if (damage < 1) then begin
display_msg(message_str(291, 101));
end
else begin
display_msg(message_str(291, 102) + damage + message_str(291, 103));
critter_dmg(dude_obj, damage, 0);
end
end
else begin
display_msg(message_str(291, 104));
end
move_to(dude_obj, local_var(1), local_var(2));
end
end