1 |
if live_call() |
2 |
return global.live_result; |
3 |
if instance_exists(obj_dialogue_box_battle_transformation_any) |
4 |
axis_trash_meter_y = lerp(axis_trash_meter_y, axis_trash_meter_y_target, 0.2) |
5 |
else |
6 |
{ |
7 |
axis_trash_meter_y = lerp(axis_trash_meter_y, -80, 0.2) |
8 |
axis_trash_meter_pulse_alpha = 0 |
9 |
} |
10 |
axis_trash_meter_current = lerp(axis_trash_meter_current, axis_trash_meter, 0.2) |
11 |
if (axis_trash_meter_current > 99.99) |
12 |
{ |
13 |
axis_trash_meter_current = 100 |
14 |
if (axis_trash_meter_full == false) |
15 |
{ |
16 |
audio_play_sound(snd_axis_trash_meter_full, 1, 0) |
17 |
axis_trash_meter_pulse_alpha = 1 |
18 |
axis_trash_meter_alpha_inc = -0.1 |
19 |
axis_trash_meter_full = true |
20 |
} |
21 |
} |
22 |
else |
23 |
axis_trash_meter_full = false |
24 |
if (axis_trash_meter_current < 0.01) |
25 |
axis_trash_meter_current = 0 |
26 |
var battery_level_target = 100 * (axis_hit_count_current / axis_hit_count_max) |
27 |
axis_battery_meter_current = lerp(axis_battery_meter_current, battery_level_target, 0.15) |
28 |
if axis_trash_meter_full |
29 |
{ |
30 |
axis_trash_meter_pulse_alpha += axis_trash_meter_alpha_inc |
31 |
if (axis_trash_meter_pulse_alpha >= 1 || axis_trash_meter_pulse_alpha <= 0) |
32 |
axis_trash_meter_alpha_inc *= -1 |
33 |
} |
34 |
if instance_exists(obj_battle_enemy_axis_generator) |
35 |
shield_enabled = true |
36 |
if shield_enabled |
37 |
{ |
38 |
if (!instance_exists(obj_battle_enemy_axis_generator)) |
39 |
shield_enabled = false |
40 |
else |
41 |
{ |
42 |
axis_shield_pulse_alpha += axis_shield_pulse_alpha_inc |
43 |
if ((axis_shield_pulse_alpha >= 1 && axis_shield_pulse_alpha_inc > 0) || (axis_shield_pulse_alpha <= 0.2 && axis_shield_pulse_alpha_inc < 0)) |
44 |
axis_shield_pulse_alpha_inc *= -1 |
45 |
} |
46 |
} |