Skip to content

Commit

Permalink
📝 update commands
Browse files Browse the repository at this point in the history
  • Loading branch information
MiranDMC committed Oct 28, 2024
1 parent 0a54f63 commit d91c8b7
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions sa/snippets/default/03C4.txt
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
// $sw4_health_display stores health bar in original game. Safe to use, except if "Ghetto Drive By" mission is in progress
const screenCounter = $sw4_health_display // global variable safe to use, unless "Ghetto Drive By" mission is in progress

set_onscreen_counter_flash_when_first_displayed {var_counter} $sw4_health_display {state} true
set_onscreen_counter_flash_when_first_displayed {var_counter} screenCounter {state} true

display_onscreen_counter_with_string {var_counter} $sw4_health_display {display} CounterDisplay.Bar {text} 'DEAD' // WASTED
$sw4_health_display = 10 // start with 10%
display_onscreen_counter_with_string {var_counter} screenCounter {display} CounterDisplay.Bar {text} 'DEAD' // WASTED
screenCounter = 10 // start with 10%

// animate the bar
while $sw4_health_display < 100
$sw4_health_display += 1
while screenCounter < 100
screenCounter += 1
wait 100
end

// display for one more second
wait 1000

// cleanup
clear_onscreen_counter {var_counter} $sw4_health_display
clear_onscreen_counter {var_counter} screenCounter

0 comments on commit d91c8b7

Please sign in to comment.