Fallout Wiki
Advertisement
Fallout Wiki
Details
Type Decompiled script
SCRIPTS.LST comment sentry droid for the Glow
MSG file N/A
Transcript

procedure start;
procedure critter_p_proc;
procedure use_skill_on_p_proc;
procedure combat_p_proc;
procedure start
begin
        if (script_action == 8) then begin
                call use_skill_on_p_proc;
        end
        else begin
                if (script_action == 12) then begin
                        call critter_p_proc;
                end
                else begin
                        if (script_action == 13) then begin
                                call combat_p_proc;
                        end
                end
        end
end
procedure critter_p_proc
begin
        if (obj_can_see_obj(self_obj, dude_obj) and (global_var(224) == 2) and (global_var(140) == 0)) then begin
                attack_complex(dude_obj, 0, 1, 0, 0, 30000, 0, 0);
        end
        else begin
                if (global_var(224) != 2) then begin
                        anim(self_obj, 48, 0);
                end
        end
end
procedure use_skill_on_p_proc
begin
        if (action_being_used == 12) then begin
                script_overrides;
                if ((global_var(224) == 2) and is_success(roll_vs_skill(dude_obj, 12, -10))) then begin
                        display_msg(message_str(766, 173));
                        if (local_var(0) == 0) then begin
                                give_exp_points(100);
                        end
                end
                else begin
                        display_msg(message_str(766, 174));
                end
        end
end
procedure combat_p_proc
begin
        if (fixed_param == 4) then begin
                if ((global_var(224) != 2) or (global_var(140) != 0)) then begin
                        script_overrides;
                        anim(self_obj, 48, 0);
                end
        end
end

Advertisement