39 lines
672 B
Plaintext
Executable File
39 lines
672 B
Plaintext
Executable File
if distance_to_object(obj_player_control) < 350
|
|
{
|
|
final += 1
|
|
if final = 2
|
|
{
|
|
ID = instance_create(x,y,obj_enemy_beams)
|
|
with (ID) motion_set(other.direction-10+random(20),10)
|
|
final = 0
|
|
}
|
|
}
|
|
|
|
if hp < 1
|
|
{
|
|
score += 10000;
|
|
instance_destroy();
|
|
}
|
|
|
|
shield += 1
|
|
if point_direction(x,y,obj_player_control.x,obj_player_control.y) > direction
|
|
{
|
|
direction += 4
|
|
}
|
|
if point_direction(x,y,obj_player_control.x,obj_player_control.y) < direction
|
|
{
|
|
direction -= 4
|
|
}
|
|
speed = 5
|
|
direction = direction
|
|
if shield >= 450
|
|
{
|
|
shielded = 1
|
|
}
|
|
if shield >= 600
|
|
{
|
|
shielded = 0
|
|
shield = 0
|
|
}
|
|
|