1 |
if live_call() |
2 |
return global.live_result; |
3 |
var fight_number = global.fight_number |
4 |
if (fight_number == 1) |
5 |
{ |
6 |
var enemy_sparing = global.enemy_sparing |
7 |
var enemy_vulnerable = global.enemy_vulnerable |
8 |
var current_hp_enemy = global.current_hp_enemy |
9 |
var attacking_damage_stat_critical = global.attacking_damage_stat_critical |
10 |
var enemy_target_x = global.enemy_target_x |
11 |
var enemy_target_y = global.enemy_target_y |
12 |
} |
13 |
else if (fight_number == 2) |
14 |
{ |
15 |
enemy_sparing = global.enemy_sparing_2 |
16 |
enemy_vulnerable = global.enemy_vulnerable_2 |
17 |
current_hp_enemy = global.current_hp_enemy_2 |
18 |
attacking_damage_stat_critical = global.attacking_damage_stat_critical_2 |
19 |
enemy_target_x = global.enemy_target_x_2 |
20 |
enemy_target_y = global.enemy_target_y_2 |
21 |
} |
22 |
else if (fight_number == 3) |
23 |
{ |
24 |
enemy_sparing = global.enemy_sparing_3 |
25 |
enemy_vulnerable = global.enemy_vulnerable_3 |
26 |
current_hp_enemy = global.current_hp_enemy_3 |
27 |
attacking_damage_stat_critical = global.attacking_damage_stat_critical_3 |
28 |
enemy_target_x = global.enemy_target_x_3 |
29 |
enemy_target_y = global.enemy_target_y_3 |
30 |
} |
31 |
script_execute(gml_Script_scr_controls_battle_reticle) |
32 |
if (outline <= 0 && no_loop == false) |
33 |
{ |
34 |
outline = 0 |
35 |
shrink = false |
36 |
image_alpha = 0 |
37 |
alarm[0] = 1alarm[0]with (obj_target_bar_battle)
{
shot_total_pre += obj_wild_revolver_circle_pre.shot_add
if (button_pressed_pre == false)
button_pressed_pre = obj_wild_revolver_circle_pre.button_pressed
}
with (obj_wild_revolver_battle_outline)
continue_shot = obj_wild_revolver_circle_pre.button_pressed
instance_destroy() |
38 |
no_loop = true |
39 |
} |
40 |
if key_select |
41 |
{ |
42 |
if ((outline < small_circle && ((enemy_sparing == true && enemy_vulnerable == true) || (enemy_vulnerable == true && current_hp_enemy <= attacking_damage_stat_critical))) || outline <= (small_circle * 0.5)) |
43 |
{ |
44 |
shot_type = "strong" |
45 |
hit_object = obj_shot_strong_fake |
46 |
shot_add = 3 |
47 |
var shot_sound = audio_play_sound(snd_attackhitperfect, 1, 0) |
48 |
} |
49 |
else if (outline < small_circle && outline > (small_circle * 0.5)) |
50 |
{ |
51 |
shot_type = "medium" |
52 |
hit_object = 2915 |
53 |
shot_add = 2 |
54 |
shot_sound = audio_play_sound(snd_attackhit, 1, 0) |
55 |
} |
56 |
else |
57 |
{ |
58 |
outline = 0 |
59 |
shrink = false |
60 |
image_alpha = 0 |
61 |
alarm[0] = 1alarm[0]with (obj_target_bar_battle)
{
shot_total_pre += obj_wild_revolver_circle_pre.shot_add
if (button_pressed_pre == false)
button_pressed_pre = obj_wild_revolver_circle_pre.button_pressed
}
with (obj_wild_revolver_battle_outline)
continue_shot = obj_wild_revolver_circle_pre.button_pressed
instance_destroy() |
62 |
no_loop = true |
63 |
return; |
64 |
} |
65 |
audio_sound_pitch(shot_sound, (1 + obj_wild_revolver_battle_outline.target_current * 0.08)) |
66 |
audio_sound_gain(shot_sound, 10, 0) |
67 |
var dj_a = obj_wild_revolver_battle_outline.target_current |
68 |
var dj_b = dj_a - 1 |
69 |
var dj_c = dj_order[dj_b] |
70 |
instance_create((enemy_target_x + disjoint_x[dj_c]), (enemy_target_y + disjoint_y[dj_c]), hit_object) |
71 |
shrink = false |
72 |
button_pressed = true |
73 |
alarm[0] = 5alarm[0]with (obj_target_bar_battle)
{
shot_total_pre += obj_wild_revolver_circle_pre.shot_add
if (button_pressed_pre == false)
button_pressed_pre = obj_wild_revolver_circle_pre.button_pressed
}
with (obj_wild_revolver_battle_outline)
continue_shot = obj_wild_revolver_circle_pre.button_pressed
instance_destroy() |
74 |
} |
75 |
if (outline > 0 && shrink == true) |
76 |
outline -= shrink_speed |
77 |
if (button_pressed == true && shrink == false) |
78 |
{ |
79 |
color_alt_total += color_alt_speed |
80 |
if (color_alt_total >= color_alt_max) |
81 |
{ |
82 |
color_alt_total = 0 |
83 |
color_number += 1 |
84 |
if (color_number > 1) |
85 |
color_number = 0 |
86 |
} |
87 |
cursor_color = color[color_number] |
88 |
color_number_2 = color_number + 1 |
89 |
if (color_number_2 > 1) |
90 |
color_number_2 = 0 |
91 |
outline_color = color[color_number_2] |
92 |
} |