More enemy AI added

This commit is contained in:
2025-11-29 16:15:42 +03:00
parent 371ded7d06
commit 16ba892f74
15 changed files with 106 additions and 26 deletions
+2 -2
View File
@@ -3,14 +3,14 @@ extends Node2D
enum Belonging { PLAYER, ENEMY }
enum Type { SHORT_RANGE, MEDIUM_RANGE, LONG_RANGE, HOMING, MINES }
enum Type { NONE, SHORT_RANGE, MEDIUM_RANGE, LONG_RANGE, HOMING, MINES }
@export_range(1, 100) var bullet_per_shot : int = 1
@export_range(0, 360) var sector_angle : int = 0
@export var Projectile : PackedScene
@export var type := Type.MEDIUM_RANGE
@export var type := Type.NONE
@onready var muzzle : Node2D = $Muzzle
@@ -158,7 +158,7 @@ gravity = Vector3(0, 0, 0)
script = ExtResource("2_ew5um")
sector_angle = 1
Projectile = ExtResource("2_2bjeu")
type = 2
type = 3
[node name="ShotParticles" type="Node2D" parent="." index="0"]
@@ -44,6 +44,7 @@ script = ExtResource("1_kg6du")
reloader = SubResource("Resource_oppha")
sector_angle = 5
Projectile = ExtResource("2_ylc0n")
type = 1
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." index="0"]
position = Vector2(6, 0)
@@ -46,7 +46,7 @@ region = Rect2(224, 144, 32, 16)
script = ExtResource("2_mxjpe")
sector_angle = 5
Projectile = ExtResource("3_fsoo2")
type = 3
type = 4
[node name="LeftParticles" type="GPUParticles2D" parent="." index="0"]
position = Vector2(-4, -3)
@@ -130,7 +130,7 @@ animations = [{
script = ExtResource("2_mmhtn")
sector_angle = 10
Projectile = ExtResource("2_7y446")
type = 4
type = 5
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." index="0"]
position = Vector2(-7, 0)
@@ -99,6 +99,7 @@ animations = [{
script = ExtResource("2_fnsb7")
sector_angle = 2
Projectile = ExtResource("2_yluvp")
type = 2
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." index="0"]
position = Vector2(8, 0)
@@ -154,7 +154,7 @@ animations = [{
[node name="RailgunWeapon" instance=ExtResource("1_0nxvu")]
script = ExtResource("1_5nhwg")
Projectile = ExtResource("2_cbsia")
type = 2
type = 3
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." index="0"]
position = Vector2(5, 0)
@@ -115,7 +115,7 @@ script = ExtResource("2_1bd18")
bullet_per_shot = 20
sector_angle = 30
Projectile = ExtResource("2_xvd4y")
type = 0
type = 1
[node name="ShotParticles" type="GPUParticles2D" parent="." index="0"]
position = Vector2(17, 0)
@@ -146,7 +146,7 @@ gravity = Vector3(0, 0, 0)
script = ExtResource("2_08si3")
sector_angle = 10
Projectile = ExtResource("2_1rrdy")
type = 3
type = 4
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." index="0"]
sprite_frames = SubResource("SpriteFrames_ckvhw")