1 |
if (live_call()) |
2 |
return global.live_result; |
3 |
damage_number = scr_determine_damage_number_enemyscr_determine_damage_number_enemyfunction scr_determine_damage_number_enemy(arg0, arg1, arg2)
{
var enemy_count = global.enemy_count;
if (global.battle_enemy_name_1 == arg0)
return 1;
else if (enemy_count >= 2 && global.battle_enemy_name_2 == arg1)
return 2;
else if (enemy_count >= 3 && global.battle_enemy_name_3 == arg2)
return 3;
else
return 0;
} ("martlet", "void", "void"); |
4 |
image_blend = c_yellow; |
5 |
if (!instance_exists(obj_feather_fall_final_holder)) |
6 |
instance_create(0, 0, obj_feather_fall_final_holder); |
7 |
state = 0; |
8 |
fall_speed = 10; |
9 |
x_point = x; |
10 |
y_point = y; |
11 |
angle_pos = 270; |
12 |
angle_pos_default = angle_pos; |
13 |
angle_pos_max = 15 * fall_speed; |
14 |
angle_radius = 10; |
15 |
starting_position_x = x; |
16 |
starting_position_y = y; |
17 |
animation_disjoint_x = 0; |
18 |
animation_disjoint_y = 0; |
19 |
can_move = true; |
20 |
explosion_angle = irandom_range(0, 360); |
21 |
var random_number = irandom_range(1, 3); |
22 |
switch (random_number) |
23 |
{ |
24 |
case 1: |
25 |
sprite_index = spr_battle_enemy_attack_martlet_feather_1; |
26 |
break; |
27 |
case 2: |
28 |
sprite_index = spr_battle_enemy_attack_martlet_feather_2; |
29 |
break; |
30 |
case 3: |
31 |
sprite_index = spr_battle_enemy_attack_martlet_feather_3; |
32 |
break; |
33 |
case 4: |
34 |
sprite_index = spr_battle_enemy_attack_martlet_feather_4; |
35 |
break; |
36 |
case 5: |
37 |
sprite_index = spr_battle_enemy_attack_martlet_feather_5; |
38 |
break; |
39 |
default: |
40 |
sprite_index = spr_battle_enemy_attack_martlet_feather_1; |
41 |
} |
42 |
image_speed = 0; |
43 |
image_index = 0; |
44 |
image_alpha = 0; |
45 |
var battle_box = 3154; |
46 |
if (x < battle_box.x) |
47 |
random_number = 1; |
48 |
else |
49 |
random_number = -1; |
50 |
sign_modifier = random_number; |
51 |
time_elapsed = 0; |
52 |
time_max = 30 + (15 * (fall_speed - 1)); |
53 |
time_increase = 1; |
54 |
max_rise = 10 * fall_speed * 2; |
55 |
time_elapsed_increase_fall = round(time_max / 3); |
56 |
spin_speed = 25; |
57 |
no_loop_spin = false; |
58 |
attack_speed = 32; |
59 |
in_box = false; |
60 |
x_list = ds_list_create(); |
61 |
y_list = ds_list_create(); |
62 |
angle_list = ds_list_create(); |
63 |
max_points_trail = 10; |
64 |
trail_sprite = sprite_index; |
65 |
trail_cc_max = 3; |
66 |
trail_cc_start = trail_cc_max - 1; |
67 |
trail_cc_current = trail_cc_start; |
68 |
bullet_hit_points = 1; |
69 |
bullet_hit_draw_timer = 0; |
70 |
bullet_destroy_self = false; |
71 |
alarm[0] = 30;gml_Object_obj_battle_enemy_attack_martlet_feather_fall_feather_final_Alarm_0.gmlif (live_call())
return global.live_result;
x_destination = obj_heart_battle_fighting_parent.x;
y_destination = obj_heart_battle_fighting_parent.y;
angle_destination = point_direction(x, y, obj_heart_battle_fighting_parent.x, obj_heart_battle_fighting_parent.y);
if (angle_difference(image_angle, angle_destination) > 0)
spin_direction = 1;
else
spin_direction = -1;
obj_feather_fall_final_holder.x_store = x_destination;
obj_feather_fall_final_holder.y_store = y_destination;
obj_feather_fall_final_holder.angle_store = angle_destination;
global.id_store = id;
with (instance_create_depth(x_destination, y_destination, -100, obj_battle_enemy_attack_martlet_feather_fall_target_1_final))
{
geno_target_angle = other.explosion_angle;
sprite_index = spr_battle_enemy_attack_martlet_target_half_axis;
}
id_target = global.id_store;
state = 1;
switch (sprite_index)
{
case spr_battle_enemy_attack_martlet_feather_1:
audio_play_sound(snd_mart_feather_atk3, 20, 0);
break;
case spr_battle_enemy_attack_martlet_feather_2:
case spr_battle_enemy_attack_martlet_feather_3:
audio_play_sound(snd_mart_feather_atk1, 20, 0);
break;
case spr_battle_enemy_attack_martlet_feather_4:
case spr_battle_enemy_attack_martlet_feather_5:
audio_play_sound(snd_mart_feather_atk2, 20, 0);
break;
default:
audio_play_sound(snd_mart_feather_atk1, 20, 0);
} |