Skip to content

Commit

Permalink
Fixed possible duplicating timer events in vccurtis
Browse files Browse the repository at this point in the history
(ref. #288)
  • Loading branch information
NovaRain committed Jul 26, 2024
1 parent d0516ef commit 6fa4999
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scripts_src/valtcity/vccurtis.ssl
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,9 @@ procedure map_enter_p_proc begin
//critter_add_trait(self_obj,TRAIT_OBJECT,OBJECT_AI_PACKET,AI_CHILD);
// Tough kid. He throws rocks.
set_self_ai(AI_VAULT_GUARD);
add_timer_event(self_obj, game_ticks( random(20, 30) ), 1);
if (is_loading_game == false) then begin
flush_add_timer_event_sec(self_obj, random(20, 30), 1);
end
end
end

Expand Down Expand Up @@ -275,7 +277,7 @@ end

procedure Node003 begin
floater(107);
add_timer_event(self_obj, game_ticks( random(20, 30) ), 1);
flush_add_timer_event_sec(self_obj, random(20, 30), 1);
end

procedure Node004 begin
Expand All @@ -289,7 +291,7 @@ procedure Node004 begin
else
Nixon_Floats += 1;

add_timer_event(self_obj, game_ticks(5), 1);
flush_add_timer_event_sec(self_obj, 5, 1);
end

procedure Node005 begin
Expand Down

0 comments on commit 6fa4999

Please sign in to comment.