1 |
if live_call() |
2 |
return global.live_result; |
3 |
bomb_side = choose(1, 2, 3, 4) |
4 |
var bomb_offset = 90 |
5 |
switch bomb_side |
6 |
{ |
7 |
case 1: |
8 |
var bomb = instance_create_depth((battle_box.x - 100), choose((battle_box.y - bomb_offset), (battle_box.y + bomb_offset)), -100, obj_battle_enemy_attack_axis_bomb_2) |
9 |
bomb.gravity_direction = 180 |
10 |
bomb.direction = 0 |
11 |
break |
12 |
case 2: |
13 |
bomb = instance_create_depth(choose((battle_box.x - bomb_offset), (battle_box.x + bomb_offset)), (battle_box.y - 100), -100, obj_battle_enemy_attack_axis_bomb_2) |
14 |
bomb.gravity_direction = 90 |
15 |
bomb.direction = 270 |
16 |
break |
17 |
case 3: |
18 |
bomb = instance_create_depth((battle_box.x + 100), choose((battle_box.y - bomb_offset), (battle_box.y + bomb_offset)), -100, obj_battle_enemy_attack_axis_bomb_2) |
19 |
bomb.gravity_direction = 0 |
20 |
bomb.direction = 180 |
21 |
break |
22 |
case 4: |
23 |
bomb = instance_create_depth(choose((battle_box.x - bomb_offset), (battle_box.x + bomb_offset)), (battle_box.y + 100), -100, obj_battle_enemy_attack_axis_bomb_2) |
24 |
bomb.gravity_direction = 270 |
25 |
bomb.direction = 90 |
26 |
break |
27 |
} |
28 |
|
29 |
bomb.image_angle = bomb.direction - 90 |
30 |
alarm[0] = attack_intervalalarm[0]if live_call()
return global.live_result;
bomb_side = choose(1, 2, 3, 4)
var bomb_offset = 90
switch bomb_side
{
case 1:
var bomb = instance_create_depth((battle_box.x - 100), choose((battle_box.y - bomb_offset), (battle_box.y + bomb_offset)), -100, obj_battle_enemy_attack_axis_bomb_2)
bomb.gravity_direction = 180
bomb.direction = 0
break
case 2:
bomb = instance_create_depth(choose((battle_box.x - bomb_offset), (battle_box.x + bomb_offset)), (battle_box.y - 100), -100, obj_battle_enemy_attack_axis_bomb_2)
bomb.gravity_direction = 90
bomb.direction = 270
break
case 3:
bomb = instance_create_depth((battle_box.x + 100), choose((battle_box.y - bomb_offset), (battle_box.y + bomb_offset)), -100, obj_battle_enemy_attack_axis_bomb_2)
bomb.gravity_direction = 0
bomb.direction = 180
break
case 4:
bomb = instance_create_depth(choose((battle_box.x - bomb_offset), (battle_box.x + bomb_offset)), (battle_box.y + 100), -100, obj_battle_enemy_attack_axis_bomb_2)
bomb.gravity_direction = 270
bomb.direction = 90
break
}
bomb.image_angle = bomb.direction - 90
alarm[0] = attack_interval |