1 |
damage_number = scr_determine_damage_number_enemyscr_determine_damage_number_enemyfunction scr_determine_damage_number_enemy(argument0, argument1, argument2) //gml_Script_scr_determine_damage_number_enemy
{
var enemy_count = global.enemy_count
if (global.battle_enemy_name_1 == argument0)
return 1;
else if (enemy_count >= 2 && global.battle_enemy_name_2 == argument1)
return 2;
else if (enemy_count >= 3 && global.battle_enemy_name_3 == argument2)
return 3;
else
return 0;
} ("frostermit a", "frostermit b", "frostermit c") |
2 |
fall_speed = irandom_range(1, 3) |
3 |
x_point = x |
4 |
y_point = y |
5 |
angle_pos = 270 |
6 |
angle_pos_default = angle_pos |
7 |
angle_pos_max = 15 * fall_speed |
8 |
angle_radius = 5 |
9 |
angle_increase = 6 * fall_speed |
10 |
starting_position_x = x |
11 |
starting_position_y = y |
12 |
animation_disjoint_x = 0 |
13 |
animation_disjoint_y = 0 |
14 |
can_move = false |
15 |
var random_number = irandom_range(1, 8) |
16 |
switch random_number |
17 |
{ |
18 |
case 1: |
19 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_1 |
20 |
break |
21 |
case 2: |
22 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_2 |
23 |
break |
24 |
case 3: |
25 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_3 |
26 |
break |
27 |
case 4: |
28 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_4 |
29 |
break |
30 |
case 5: |
31 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_5 |
32 |
break |
33 |
case 6: |
34 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_6 |
35 |
break |
36 |
case 7: |
37 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_7 |
38 |
break |
39 |
case 8: |
40 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_8 |
41 |
break |
42 |
default: |
43 |
sprite_index = spr_battle_enemy_attack_frostermit_snowflake_1 |
44 |
} |
45 |
|
46 |
image_speed = 0 |
47 |
image_index = 0 |
48 |
image_alpha = 0 |
49 |
random_number = irandom_range(0, 1) |
50 |
if (random_number == 0) |
51 |
random_number = -1 |
52 |
sign_modifier = random_number |
53 |
time_elapsed = 0 |
54 |
time_max = 30 + 15 * (fall_speed - 1) |
55 |
time_increase = 1 |
56 |
max_rise = 5 * fall_speed * (irandom_range(1, 2)) |