Skip to content

Commit

Permalink
gl_k_tragic: saneer arithmetic ops, ref #326
Browse files Browse the repository at this point in the history
  • Loading branch information
burner1024 committed Jan 11, 2025
1 parent 1bebb36 commit 7ea32eb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts_src/global/gl_k_tragic.ssl
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ procedure start begin
if global_var(GVAR_ADDICT_TRAGIC) == 0 then return;

// Craving
if game_time - time_of_last_craving >= TIME_TRAGIC_USAGE then begin
if game_time >= time_of_last_craving + TIME_TRAGIC_USAGE then begin
if in_world_map then force_encounter(0);

time_of_last_craving = game_time;
if (game_time - time_of_game_load < TIME_DURATION_OF_ADDICTION) then display_mymsg(MSG_craving);
if (game_time < time_of_game_load + TIME_DURATION_OF_ADDICTION) then display_mymsg(MSG_craving);
end

// Addiction passed
if game_time - time_of_game_load >= TIME_DURATION_OF_ADDICTION then begin
if game_time >= time_of_game_load + TIME_DURATION_OF_ADDICTION then begin
set_global_var(GVAR_ADDICT_TRAGIC, 0);
if not dude_is_addicted() then hide_iface_tag(INTERFACE_TAG_ADDICT);
display_mymsg(MSG_relieved);
Expand Down

0 comments on commit 7ea32eb

Please sign in to comment.