diff --git a/.DS_Store b/.DS_Store index 293e264..6866fca 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c8038f0..e79812c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,3 +1,5 @@ +# This is a basic workflow to help you get started with Actions + name: CI # Controls when the action will run. @@ -26,14 +28,6 @@ jobs: # Steps represent a sequence of tasks that will be executed as part of the job steps: - - name: Build Release - if: env.GITHUB_EVENT_NAME == 'push' - run: echo "BUILD_TYPE=release" >> $GITHUB_ENV - - - name: Build Debug/Beta - if: env.GITHUB_EVENT_NAME == 'pull_request' - run: echo "BUILD_TYPE=debug" >> $GITHUB_ENV - # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - uses: actions/checkout@v2 name: Checkout Files @@ -63,11 +57,10 @@ jobs: mkdir -v -p build/web EXPORT_DIR="$(readlink -f build)" cd $GITHUB_WORKSPACE - /usr/bin/godot --headless --verbose --export-${{ env.BUILD_TYPE }} "Web" "$EXPORT_DIR/web/index.html" + /usr/bin/godot --headless --verbose --export-release "Web" "$EXPORT_DIR/web/index.html" - name: Upload Build uses: https://code.forgejo.org/forgejo/upload-artifact@v4 - id: upload-build with: name: Web Build path: build/web diff --git a/1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png b/1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png similarity index 100% rename from 1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png rename to 1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png diff --git a/1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png.import b/1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png.import similarity index 69% rename from 1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png.import rename to 1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png.import index 00479ef..15759ee 100644 --- a/1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png.import +++ b/1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://cpjtncjaomqwm" -path="res://.godot/imported/prompt_p.png-9bae51d7552c94969996b613509af9e3.ctex" +path="res://.godot/imported/tile_0366.png-edb08678f52d381824bd466af55fc5c0.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_p.png" -dest_files=["res://.godot/imported/prompt_p.png-9bae51d7552c94969996b613509af9e3.ctex"] +source_file="res://1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0366.png" +dest_files=["res://.godot/imported/tile_0366.png-edb08678f52d381824bd466af55fc5c0.ctex"] [params] diff --git a/Entagon.gd b/Entagon.gd index 9ddafe9..b4e729a 100644 --- a/Entagon.gd +++ b/Entagon.gd @@ -8,7 +8,7 @@ func hit(body): body.destroy() else: body.queue_free() - spawn_explosion() + spawn_explosion() queue_free() if body.name == "Border": queue_free() @@ -21,4 +21,4 @@ func spawn_explosion(): # Called every frame. 'delta' is the elapsed time since the previous frame. func _physics_process(delta): - apply_central_force((global_position - player.global_position).normalized() * -1400) + apply_central_force((global_position - (player.global_position + player.linear_velocity * 3)).normalized() * -1200) diff --git a/Shield.gd b/Shield.gd new file mode 100644 index 0000000..3ad1fe5 --- /dev/null +++ b/Shield.gd @@ -0,0 +1,18 @@ +extends StaticBody2D + +@export var health = 10 +var max_health = 10.0 + +func destroy(): + health -= 1 + + if health == 1: + $PowerDownFX.play() + + if health <= 0: + if not is_queued_for_deletion(): + $"..".queue_free() + $"../../Player".aquire_exagon() + + modulate = Color(Color.CYAN, 0.7 - lerp(0.7, 0.1, health / max_health)) + diff --git a/Spawner.gd b/Spawner.gd index de62d4c..59af8f7 100644 --- a/Spawner.gd +++ b/Spawner.gd @@ -45,8 +45,6 @@ func spawn_loop(): func spawn_enemies(count: int, duration: float, enemy: WaveEnemy): var delay = duration / count for i in range(count): - if get_tree().paused: - await get_parent().unpaused spawn(enemy) await get_tree().create_timer(delay).timeout @@ -58,7 +56,7 @@ func spawn(item: WaveEnemy): print("Spawning Boss!") spawn_loc = Vector2(1920/2, 1080/2) else: - for i in range(1000): + for i in range(100): var test_pos = Vector2(randf(), randf()) * Vector2(1920, 1080) if not $"../CollisionCheck".is_clear(test_pos, item.check_distance): continue diff --git a/bullet.gd b/bullet.gd index 8f3a48f..6b54bf3 100644 --- a/bullet.gd +++ b/bullet.gd @@ -21,7 +21,6 @@ func hit(body): queue_free() else: bounces += 1 - $Sprite2D.play("depleted") #print(bounces) if bounces >= 2: diff --git a/bullet.tscn b/bullet.tscn index 94c210d..45568ea 100644 --- a/bullet.tscn +++ b/bullet.tscn @@ -20,11 +20,11 @@ region = Rect2(0, 0, 40, 40) atlas = ExtResource("2_unua3") region = Rect2(40, 0, 40, 40) -[sub_resource type="AtlasTexture" id="AtlasTexture_m7c0a"] +[sub_resource type="AtlasTexture" id="AtlasTexture_u3ov1"] atlas = ExtResource("2_unua3") region = Rect2(80, 0, 40, 40) -[sub_resource type="AtlasTexture" id="AtlasTexture_uq6kd"] +[sub_resource type="AtlasTexture" id="AtlasTexture_ia1sw"] atlas = ExtResource("2_unua3") region = Rect2(120, 0, 40, 40) @@ -36,32 +36,27 @@ animations = [{ }, { "duration": 1.0, "texture": SubResource("AtlasTexture_ldqff") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_u3ov1") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ia1sw") }], "loop": true, "name": &"default", "speed": 7.0 -}, { -"frames": [{ -"duration": 1.0, -"texture": SubResource("AtlasTexture_m7c0a") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_uq6kd") -}], -"loop": true, -"name": &"depleted", -"speed": 5.0 }] [sub_resource type="CircleShape2D" id="CircleShape2D_13gk7"] radius = 30.0 -[node name="Bullet" type="RigidBody2D" groups=["bullet", "destructible"]] +[node name="Bullet" type="RigidBody2D" groups=["bullet"]] collision_layer = 2 physics_material_override = SubResource("PhysicsMaterial_xnhwp") gravity_scale = 1.66533e-16 -contact_monitor = true max_contacts_reported = 1 +contact_monitor = true linear_velocity = Vector2(2.08165e-12, 2.08165e-12) script = ExtResource("1_3q13i") @@ -75,10 +70,7 @@ position = Vector2(-0.0234375, -0.00781251) rotation = 1.5708 scale = Vector2(4, 4) sprite_frames = SubResource("SpriteFrames_pacu6") -animation = &"depleted" autoplay = "default" -frame = 1 -frame_progress = 0.323082 offset = Vector2(7.05637, 10.7826) [node name="TrajectoryDisplay" type="Line2D" parent="."] diff --git a/eart.gd b/eart.gd index 7ebf226..ebffe73 100644 --- a/eart.gd +++ b/eart.gd @@ -16,7 +16,7 @@ func shoot(): $Turret.target = find_target() - #$ShootTimer.start(1) + $ShootTimer.start(1) func find_target(): diff --git a/eart.tres b/eart.tres index ba101e4..886e17f 100644 --- a/eart.tres +++ b/eart.tres @@ -9,4 +9,4 @@ script = ExtResource("1_0iu7m") enemy = ExtResource("1_hy2xe") boss = false portal_texture = ExtResource("2_nxpif") -check_distance = 150 +check_distance = 100 diff --git a/eart.tscn b/eart.tscn index 6541a8f..9d700f2 100644 --- a/eart.tscn +++ b/eart.tscn @@ -140,6 +140,7 @@ radius = 44.1475 script = ExtResource("1_xkxbf") [node name="ShootTimer" type="Timer" parent="."] +one_shot = true autostart = true [node name="Turret" type="Node2D" parent="."] diff --git a/entagon.tscn b/entagon.tscn index 139d3ce..8106dd9 100644 --- a/entagon.tscn +++ b/entagon.tscn @@ -65,9 +65,9 @@ radius = 30.0 collision_mask = 0 physics_material_override = SubResource("PhysicsMaterial_odemo") gravity_scale = 1.66533e-16 -contact_monitor = true max_contacts_reported = 2 -linear_damp = 2.0 +contact_monitor = true +linear_damp = 3.0 angular_velocity = 0.174533 script = ExtResource("1_726g8") @@ -100,7 +100,4 @@ target_shield = true shape = SubResource("CircleShape2D_eo18f") target_position = Vector2(2.08165e-12, 500) -[node name="ShieldMarker" type="Marker2D" parent="."] -scale = Vector2(1.5, 1.5) - [connection signal="body_entered" from="." to="." method="hit"] diff --git a/entagon_enemy.tres b/entagon_enemy.tres index bae3c74..a1d3fbc 100644 --- a/entagon_enemy.tres +++ b/entagon_enemy.tres @@ -9,4 +9,4 @@ script = ExtResource("3_t4kaf") enemy = ExtResource("1_mfudl") boss = false portal_texture = ExtResource("2_2xm8e") -check_distance = 200 +check_distance = 250 diff --git a/eptagon base.png b/eptagon base.png deleted file mode 100644 index 52a42b4..0000000 Binary files a/eptagon base.png and /dev/null differ diff --git a/eptagon base.png.import b/eptagon base.png.import deleted file mode 100644 index aa6fc9e..0000000 --- a/eptagon base.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://ccbd4o2iasbun" -path="res://.godot/imported/eptagon base.png-f7cfa0569b442888d2d8722ed916ca54.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://eptagon base.png" -dest_files=["res://.godot/imported/eptagon base.png-f7cfa0569b442888d2d8722ed916ca54.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/eptagon shoot.png b/eptagon shoot.png deleted file mode 100644 index 907509d..0000000 Binary files a/eptagon shoot.png and /dev/null differ diff --git a/eptagon shoot.png.import b/eptagon shoot.png.import deleted file mode 100644 index bbd242e..0000000 --- a/eptagon shoot.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://da478jrss0ira" -path="res://.godot/imported/eptagon shoot.png-5691739fab2bd478303ccc7f4ddc2612.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://eptagon shoot.png" -dest_files=["res://.godot/imported/eptagon shoot.png-5691739fab2bd478303ccc7f4ddc2612.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/eptagon.gd b/eptagon.gd index 993581b..d3bbb2f 100644 --- a/eptagon.gd +++ b/eptagon.gd @@ -1,21 +1,10 @@ extends StaticBody2D -var dying = false - # Called when the node enters the scene tree for the first time. func _ready(): $Turret.target = $"../Player" #print($Turret.target) -func destroy(): - if dying: - return - dying = true - var explosion = load("res://explosion.tscn").instantiate() - $"/root/Node2D".add_child(explosion) - explosion.global_position = global_position - await get_tree().create_timer(0.2).timeout - queue_free() # Called every frame. 'delta' is the elapsed time since the previous frame. func _process(delta): diff --git a/eptagon.tscn b/eptagon.tscn index 3cdc55e..233b17b 100644 --- a/eptagon.tscn +++ b/eptagon.tscn @@ -1,60 +1,39 @@ -[gd_scene load_steps=15 format=3 uid="uid://bda763f0fxh5k"] +[gd_scene load_steps=12 format=3 uid="uid://bda763f0fxh5k"] [ext_resource type="Script" path="res://eptagon.gd" id="1_d0pdl"] +[ext_resource type="Texture2D" uid="uid://d4f0f3ggnd3rl" path="res://eptagon.png" id="1_kwkxh"] [ext_resource type="Script" path="res://Turret.gd" id="2_6tkha"] -[ext_resource type="Texture2D" uid="uid://ccbd4o2iasbun" path="res://eptagon base.png" id="2_ook2g"] [ext_resource type="Script" path="res://Gun.gd" id="2_sea5o"] +[ext_resource type="Texture2D" uid="uid://d1wxsdwad10p6" path="res://eptagon-turret.png" id="3_jhgw8"] [ext_resource type="PackedScene" uid="uid://c6ybtahxwpukd" path="res://bullet.tscn" id="4_cyd7j"] -[ext_resource type="Texture2D" uid="uid://da478jrss0ira" path="res://eptagon shoot.png" id="4_unb6p"] -[sub_resource type="AtlasTexture" id="AtlasTexture_ynjjr"] -atlas = ExtResource("4_unb6p") -region = Rect2(0, 0, 128, 128) +[sub_resource type="AtlasTexture" id="AtlasTexture_1fcnk"] +atlas = ExtResource("3_jhgw8") +region = Rect2(0, 0, 32, 32) -[sub_resource type="AtlasTexture" id="AtlasTexture_7lu72"] -atlas = ExtResource("4_unb6p") -region = Rect2(128, 0, 128, 128) +[sub_resource type="AtlasTexture" id="AtlasTexture_hhi7e"] +atlas = ExtResource("3_jhgw8") +region = Rect2(32, 0, 32, 32) -[sub_resource type="AtlasTexture" id="AtlasTexture_i6mfs"] -atlas = ExtResource("4_unb6p") -region = Rect2(256, 0, 128, 128) - -[sub_resource type="AtlasTexture" id="AtlasTexture_g3rpy"] -atlas = ExtResource("4_unb6p") -region = Rect2(384, 0, 128, 128) - -[sub_resource type="AtlasTexture" id="AtlasTexture_4lb8x"] -atlas = ExtResource("4_unb6p") -region = Rect2(512, 0, 128, 128) - -[sub_resource type="AtlasTexture" id="AtlasTexture_bkh2l"] -atlas = ExtResource("4_unb6p") -region = Rect2(640, 0, 128, 128) +[sub_resource type="AtlasTexture" id="AtlasTexture_lo0cp"] +atlas = ExtResource("3_jhgw8") +region = Rect2(0, 32, 32, 32) [sub_resource type="SpriteFrames" id="SpriteFrames_1fj5a"] animations = [{ "frames": [{ "duration": 1.0, -"texture": SubResource("AtlasTexture_ynjjr") +"texture": SubResource("AtlasTexture_1fcnk") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_7lu72") +"texture": SubResource("AtlasTexture_hhi7e") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_i6mfs") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_g3rpy") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_4lb8x") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_bkh2l") +"texture": SubResource("AtlasTexture_lo0cp") }], "loop": true, "name": &"default", -"speed": 7.0 +"speed": 3.0 }] [sub_resource type="CircleShape2D" id="CircleShape2D_03ifk"] @@ -64,18 +43,18 @@ radius = 36.0139 script = ExtResource("1_d0pdl") [node name="Sprite2D" type="Sprite2D" parent="."] -position = Vector2(1, 5) -texture = ExtResource("2_ook2g") +scale = Vector2(3, 3) +texture = ExtResource("1_kwkxh") [node name="Turret" type="Node2D" parent="."] script = ExtResource("2_6tkha") [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="Turret"] -position = Vector2(5, 0) +position = Vector2(14, 0) rotation = -1.5708 +scale = Vector2(3, 3) sprite_frames = SubResource("SpriteFrames_1fj5a") autoplay = "default" -frame_progress = 0.726849 [node name="Gun" type="Marker2D" parent="Turret"] position = Vector2(56, 0) @@ -85,7 +64,4 @@ bullet = ExtResource("4_cyd7j") [node name="Collider" type="CollisionShape2D" parent="."] shape = SubResource("CircleShape2D_03ifk") -[node name="ShieldMarker" type="Marker2D" parent="."] -scale = Vector2(2, 2) - [connection signal="animation_looped" from="Turret/AnimatedSprite2D" to="Turret/Gun" method="shoot"] diff --git a/main.gd b/main.gd index 622b378..88d0c28 100644 --- a/main.gd +++ b/main.gd @@ -1,14 +1,11 @@ extends Node2D var config = ConfigFile.new() -signal paused -signal unpaused - # Called when the node enters the scene tree for the first time. func _init(): if OS.is_debug_build(): - Engine.set_time_scale(1) + Engine.set_time_scale(0.25) if config.load("user://settings.cfg") == OK: var player = load(config.get_value("gameplay", "class", "res://player-row.tscn")).instantiate() diff --git a/main.tscn b/main.tscn index 02619d5..0300133 100644 --- a/main.tscn +++ b/main.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=121 format=3 uid="uid://bmd4m7lqj4v0x"] +[gd_scene load_steps=117 format=3 uid="uid://bmd4m7lqj4v0x"] [ext_resource type="Script" path="res://main.gd" id="1_3dydx"] [ext_resource type="Script" path="res://Spawner.gd" id="1_ifu8g"] @@ -12,16 +12,15 @@ [ext_resource type="Texture2D" uid="uid://yvrhlh04k8w1" path="res://background space.png" id="6_yg4g1"] [ext_resource type="Script" path="res://wave_enemy.gd" id="7_54h7d"] [ext_resource type="Texture2D" uid="uid://cwquv3mq5kk1d" path="res://countdown-spritesheet.png" id="8_e1eub"] -[ext_resource type="Resource" uid="uid://ba01r62bwm6av" path="res://eptagon_enemy.tres" id="9_q67ak"] +[ext_resource type="Resource" uid="uid://dd8me0deake37" path="res://eptagon_enemy.tres" id="9_q67ak"] [ext_resource type="Resource" uid="uid://c805aej5v7cvr" path="res://eart.tres" id="10_jib8h"] [ext_resource type="AudioStream" uid="uid://dn65uapn0wsok" path="res://impactMetal_002.ogg" id="11_acuni"] [ext_resource type="Script" path="res://CollisionCheck.gd" id="11_ryeyk"] [ext_resource type="FontFile" uid="uid://bnguin7bsyx6e" path="res://Kenney Future.ttf" id="11_s4q6p"] -[ext_resource type="Texture2D" uid="uid://cso5ufbf7u7oj" path="res://Circle.png" id="13_318fy"] +[ext_resource type="Texture2D" uid="uid://bvpoajwx0yw3y" path="res://Circle.png" id="13_318fy"] [ext_resource type="Script" path="res://Notification.gd" id="13_lkv81"] [ext_resource type="Script" path="res://Stopwatch.gd" id="13_xhnp2"] [ext_resource type="Script" path="res://Leaderboard.gd" id="14_v1elq"] -[ext_resource type="Script" path="res://pause_game.gd" id="16_bto6x"] [ext_resource type="FontFile" uid="uid://bpcp43g74vhgo" path="res://monogram-extended.ttf" id="16_s4rjt"] [ext_resource type="PackedScene" uid="uid://4sdwatj6up8i" path="res://tar.tscn" id="19_8258f"] [ext_resource type="AudioStream" uid="uid://b8soxqg0jquqg" path="res://Flow State 2.ogg" id="21_7hdkm"] @@ -130,36 +129,12 @@ wait_for_killed = true [sub_resource type="Resource" id="Resource_2j32b"] script = ExtResource("4_um0x7") -enemies = Array[ExtResource("7_54h7d")]([ExtResource("5_xdrk0"), ExtResource("9_q67ak"), ExtResource("10_jib8h")]) -quantities = Array[int]([2, 2, 1]) +enemies = Array[ExtResource("7_54h7d")]([ExtResource("5_e24vf"), ExtResource("9_q67ak")]) +quantities = Array[int]([2, 2]) spawning_duration = 10.0 wait = 3.0 wait_for_killed = true -[sub_resource type="Resource" id="Resource_viqo8"] -script = ExtResource("4_um0x7") -enemies = Array[ExtResource("7_54h7d")]([ExtResource("5_xdrk0"), ExtResource("9_q67ak"), ExtResource("10_jib8h")]) -quantities = Array[int]([15, 3, 4]) -spawning_duration = 30.0 -wait = 10.0 -wait_for_killed = true - -[sub_resource type="Resource" id="Resource_o3j5s"] -script = ExtResource("4_um0x7") -enemies = Array[ExtResource("7_54h7d")]([ExtResource("5_e24vf"), ExtResource("3_xmk5u"), ExtResource("10_jib8h")]) -quantities = Array[int]([5, 5, 3]) -spawning_duration = 20.0 -wait = 5.0 -wait_for_killed = true - -[sub_resource type="Resource" id="Resource_cygv1"] -script = ExtResource("4_um0x7") -enemies = Array[ExtResource("7_54h7d")]([ExtResource("5_e24vf"), ExtResource("10_jib8h"), ExtResource("3_xmk5u"), ExtResource("5_xdrk0"), ExtResource("9_q67ak")]) -quantities = Array[int]([5, 5, 10, 15, 5]) -spawning_duration = 30.0 -wait = 1.0 -wait_for_killed = true - [sub_resource type="RectangleShape2D" id="RectangleShape2D_7w8g6"] size = Vector2(328, 185.333) @@ -693,8 +668,9 @@ script = ExtResource("1_3dydx") [node name="Spawner" type="Node2D" parent="." node_paths=PackedStringArray("wave_label")] script = ExtResource("1_ifu8g") -waves = Array[ExtResource("4_um0x7")]([SubResource("Resource_ur7l5"), SubResource("Resource_kupyp"), SubResource("Resource_o8cet"), SubResource("Resource_0cevq"), SubResource("Resource_eppj0"), SubResource("Resource_rpu1y"), SubResource("Resource_4b1vo"), SubResource("Resource_gg7kj"), SubResource("Resource_fjkob"), SubResource("Resource_5sdy5"), SubResource("Resource_61v84"), SubResource("Resource_82qld"), SubResource("Resource_2j32b"), SubResource("Resource_viqo8"), SubResource("Resource_o3j5s"), SubResource("Resource_cygv1")]) +waves = Array[ExtResource("4_um0x7")]([SubResource("Resource_ur7l5"), SubResource("Resource_kupyp"), SubResource("Resource_o8cet"), SubResource("Resource_0cevq"), SubResource("Resource_eppj0"), SubResource("Resource_rpu1y"), SubResource("Resource_4b1vo"), SubResource("Resource_gg7kj"), SubResource("Resource_fjkob"), SubResource("Resource_5sdy5"), SubResource("Resource_61v84"), SubResource("Resource_82qld"), SubResource("Resource_2j32b")]) wave_label = NodePath("../UI/Wave Count") +start_wave = 8 [node name="Timer" type="Timer" parent="Spawner"] wait_time = 0.1 @@ -760,35 +736,6 @@ position = Vector2(1920, 540) rotation = -1.5708 shape = SubResource("WorldBoundaryShape2D_rmvst") -[node name="PauseButton" type="ColorRect" parent="."] -process_mode = 3 -visible = false -z_index = 1000 -anchors_preset = 8 -anchor_left = 0.5 -anchor_top = 0.5 -anchor_right = 0.5 -anchor_bottom = 0.5 -offset_right = 1920.0 -offset_bottom = 1080.0 -grow_horizontal = 2 -grow_vertical = 2 -color = Color(0, 0, 0, 0.466667) -script = ExtResource("16_bto6x") - -[node name="Label" type="Label" parent="PauseButton"] -layout_mode = 1 -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -theme_override_fonts/font = ExtResource("11_s4q6p") -theme_override_font_sizes/font_size = 100 -text = "PAUSED" -horizontal_alignment = 1 -vertical_alignment = 1 - [node name="UI" type="Control" parent="."] z_index = 10 layout_mode = 3 diff --git a/main_menu.tscn b/main_menu.tscn index 7e447e5..37e837c 100644 --- a/main_menu.tscn +++ b/main_menu.tscn @@ -161,6 +161,7 @@ text = "Movement " layout_mode = 2 theme_override_fonts/font = ExtResource("4_ybv7t") theme_override_font_sizes/font_size = 54 +selected = 0 item_count = 2 popup/item_0/text = "Relative" popup/item_1/text = "Absolute" @@ -178,6 +179,7 @@ text = "CLASS" layout_mode = 2 theme_override_fonts/font = ExtResource("4_ybv7t") theme_override_font_sizes/font_size = 54 +selected = 0 item_count = 3 popup/item_0/text = "Row" popup/item_1/text = "Ite" @@ -323,8 +325,8 @@ bus = &"Music" [connection signal="pressed" from="Layout/Play" to="." method="play"] [connection signal="pressed" from="Layout/Settings" to="Settings Panel" method="show"] [connection signal="pressed" from="Layout/Tutorial" to="Tutorial Text" method="show"] -[connection signal="pressed" from="Settings Panel/Close" to="Settings Panel" method="hide"] [connection signal="pressed" from="Settings Panel/Close" to="Settings Panel" method="save"] +[connection signal="pressed" from="Settings Panel/Close" to="Settings Panel" method="hide"] [connection signal="text_changed" from="Settings Panel/Menu/Username" to="Settings Panel" method="check_valid"] [connection signal="text_changed" from="Settings Panel/Menu/Username" to="Settings Panel/Menu/Username" method="check"] [connection signal="value_changed" from="Settings Panel/Menu/MusicVolume" to="Settings Panel/Menu/MusicVolume" method="_on_value_changed"] diff --git a/pause_game.gd b/pause_game.gd deleted file mode 100644 index e77d83a..0000000 --- a/pause_game.gd +++ /dev/null @@ -1,11 +0,0 @@ -extends Control - -func _input(event): - if event.is_action_pressed("pause"): - get_tree().paused = not get_tree().paused - visible = not visible - if get_tree().paused: - get_parent().paused.emit() - else: - get_parent().unpaused.emit() - diff --git a/player-iamond.gd b/player-iamond.gd index 0253bf9..531da0a 100644 --- a/player-iamond.gd +++ b/player-iamond.gd @@ -10,7 +10,7 @@ func _ready(): absolute_movement = not config.get_value("config", "relative_controls") func _input(event): - if event.is_action_pressed("primary_fire") and can_jump: + if event.is_action_pressed("jump") and can_jump: can_jump = false $"../".get_node("%Ability/Portal").start_countup(0.5) $Sprite.speed_scale = 1 diff --git a/player-ite.gd b/player-ite.gd index ddcca2b..75aa6a5 100644 --- a/player-ite.gd +++ b/player-ite.gd @@ -21,7 +21,7 @@ func update_animation(): $Engine.play("idle") func _input(event): - if event.is_action_pressed("primary_fire") and speed != 0: + if event.is_action_pressed("shoot") and speed != 0: fire_laser() func _process(delta): @@ -46,7 +46,7 @@ func fire_laser(): tween.set_parallel(false) tween.tween_callback(set_laser_texture.bind(active_texture)) tween.tween_property(self, "can_damage", true, 0) - tween.tween_interval(0.25) + tween.tween_interval(0.5) tween.tween_property(self, "can_damage", false, 0) tween.tween_callback(set_laser_texture.bind(aiming_texture)) tween.set_parallel(true) diff --git a/player-row.gd b/player-row.gd index 80db79a..0707f74 100644 --- a/player-row.gd +++ b/player-row.gd @@ -20,7 +20,7 @@ func _ready(): absolute_movement = not config.get_value("config", "relative_controls") func _input(event): - if event.is_action_pressed("primary_fire"): + if event.is_action_pressed("quare"): if num_quares >= max_quares: notifier.notify("All Quares in Use!") return @@ -37,7 +37,7 @@ func _input(event): new_quare.position = get_global_mouse_position() $/root/Node2D.add_child(new_quare) new_quare.name = "Quare" - if event.is_action_pressed("secondary_fire"): + if event.is_action_pressed("exagon"): if exagons > 1: exagons = 1 if exagons <= 0: diff --git a/player-row.tscn b/player-row.tscn index ef435b8..6faa3c8 100644 --- a/player-row.tscn +++ b/player-row.tscn @@ -207,4 +207,5 @@ stream = ExtResource("4_lwgj5") bus = &"SFX" [node name="ShieldMarker" type="Marker2D" parent="." index="5"] +position = Vector2(4, 0) scale = Vector2(1.5, 1.5) diff --git a/player-shield.gd b/player-shield.gd deleted file mode 100644 index dd0c732..0000000 --- a/player-shield.gd +++ /dev/null @@ -1,4 +0,0 @@ -extends CollisionShape2D - -func destroy(): - $AnimatedSprite2D.play("die") diff --git a/player-shield.tscn b/player-shield.tscn deleted file mode 100644 index 6746af2..0000000 --- a/player-shield.tscn +++ /dev/null @@ -1,125 +0,0 @@ -[gd_scene load_steps=19 format=3 uid="uid://b11jmnjkk6ibm"] - -[ext_resource type="Script" path="res://player-shield.gd" id="1_wq4q6"] -[ext_resource type="Texture2D" uid="uid://cc3nl13t7c4mj" path="res://eart-shield.png" id="2_iu5tn"] -[ext_resource type="Texture2D" uid="uid://dysewmpj8nvgx" path="res://eart-shield-break.png" id="3_yw3j3"] - -[sub_resource type="CircleShape2D" id="CircleShape2D_0lade"] -radius = 24.3425 - -[sub_resource type="AtlasTexture" id="AtlasTexture_mcb3o"] -atlas = ExtResource("2_iu5tn") -region = Rect2(0, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_l8lnp"] -atlas = ExtResource("2_iu5tn") -region = Rect2(64, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_so4um"] -atlas = ExtResource("2_iu5tn") -region = Rect2(128, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_sel7y"] -atlas = ExtResource("2_iu5tn") -region = Rect2(192, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_iumxh"] -atlas = ExtResource("2_iu5tn") -region = Rect2(256, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_jb6hd"] -atlas = ExtResource("2_iu5tn") -region = Rect2(320, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_5xoy6"] -atlas = ExtResource("2_iu5tn") -region = Rect2(384, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_a5ids"] -atlas = ExtResource("3_yw3j3") -region = Rect2(0, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_x2842"] -atlas = ExtResource("3_yw3j3") -region = Rect2(64, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_ckp3b"] -atlas = ExtResource("3_yw3j3") -region = Rect2(128, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_b6w7a"] -atlas = ExtResource("3_yw3j3") -region = Rect2(192, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_m7ilu"] -atlas = ExtResource("3_yw3j3") -region = Rect2(256, 0, 64, 64) - -[sub_resource type="AtlasTexture" id="AtlasTexture_w1mec"] -atlas = ExtResource("3_yw3j3") -region = Rect2(320, 0, 64, 64) - -[sub_resource type="SpriteFrames" id="SpriteFrames_gcmwu"] -animations = [{ -"frames": [{ -"duration": 1.0, -"texture": SubResource("AtlasTexture_mcb3o") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_l8lnp") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_so4um") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_sel7y") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_iumxh") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_jb6hd") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_5xoy6") -}], -"loop": true, -"name": &"default", -"speed": 7.0 -}, { -"frames": [{ -"duration": 1.0, -"texture": SubResource("AtlasTexture_a5ids") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_x2842") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_ckp3b") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_b6w7a") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_m7ilu") -}, { -"duration": 1.0, -"texture": SubResource("AtlasTexture_w1mec") -}], -"loop": false, -"name": &"die", -"speed": 7.0 -}] - -[node name="Shield" type="CollisionShape2D" groups=["destructible"]] -scale = Vector2(3, 3) -shape = SubResource("CircleShape2D_0lade") -script = ExtResource("1_wq4q6") - -[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] -sprite_frames = SubResource("SpriteFrames_gcmwu") -autoplay = "default" -frame = 4 -frame_progress = 0.495833 - -[connection signal="animation_finished" from="AnimatedSprite2D" to="." method="queue_free"] diff --git a/player.gd b/player.gd index 3785928..edd0bbf 100644 --- a/player.gd +++ b/player.gd @@ -27,10 +27,10 @@ func _physics_process(delta): return var move_input = Input.get_axis("down", "up") var side_input = Input.get_axis("right", "left") - if move_input != 0 or side_input != 0: + if move_input > 0 and not moving: moving = true update_animation() - else: + elif move_input <= 0 and moving: moving = false update_animation() @@ -40,9 +40,6 @@ func _physics_process(delta): apply_central_force(transform.y * side_input * speed / -2 + transform.x * move_input * speed * linear_damp) func destroy(): - if has_node("Shield"): - $Shield.destroy() - return $DeathFX.play() get_tree().paused = true $"../GameOver".visible = true diff --git a/portal-ability.tscn b/portal-ability.tscn index dcb35a9..d6d30be 100644 --- a/portal-ability.tscn +++ b/portal-ability.tscn @@ -1,8 +1,9 @@ -[gd_scene load_steps=5 format=3 uid="uid://bl3178jc8lq1x"] +[gd_scene load_steps=6 format=3 uid="uid://bl3178jc8lq1x"] [ext_resource type="PackedScene" uid="uid://d2xigwib6hka4" path="res://quare_ability.tscn" id="1_ttx3n"] [ext_resource type="Texture2D" uid="uid://dgd2mofq75e01" path="res://portal-icon.png" id="2_2epev"] [ext_resource type="Shader" uid="uid://c2p7rwspwqmr8" path="res://greyscale.tres" id="2_s8u32"] +[ext_resource type="Texture2D" uid="uid://dux6o222ain2r" path="res://1-Bit Input Prompts Pixel 16/Tiles (White)/prompt_mouse.png" id="4_kefbp"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_ia5nv"] resource_local_to_scene = true @@ -12,3 +13,10 @@ shader_parameter/strength = null [node name="Portal" instance=ExtResource("1_ttx3n")] material = SubResource("ShaderMaterial_ia5nv") texture_under = ExtResource("2_2epev") + +[node name="prompt" parent="." index="0"] +offset_left = -20.0 +offset_top = 3.0 +offset_right = 20.0 +offset_bottom = 43.0 +texture = ExtResource("4_kefbp") diff --git a/project.godot b/project.godot index f8386a5..e13206e 100644 --- a/project.godot +++ b/project.godot @@ -64,28 +64,31 @@ restart={ "events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":82,"key_label":0,"unicode":114,"location":0,"echo":false,"script":null) ] } +jump={ +"deadzone": 0.5, +"events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":1,"position":Vector2(130, 40),"global_position":Vector2(138, 120),"factor":1.0,"button_index":1,"canceled":false,"pressed":true,"double_click":false,"script":null) +, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":32,"location":0,"echo":false,"script":null) +] +} +quare={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":81,"key_label":0,"unicode":113,"location":0,"echo":false,"script":null) +] +} +exagon={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":69,"key_label":0,"unicode":101,"location":0,"echo":false,"script":null) +] +} quit={ "deadzone": 0.5, "events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194305,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null) ] } -primary_fire={ +shoot={ "deadzone": 0.5, "events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":1,"position":Vector2(91, 32),"global_position":Vector2(99, 112),"factor":1.0,"button_index":1,"canceled":false,"pressed":true,"double_click":false,"script":null) , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":32,"location":0,"echo":false,"script":null) -, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":81,"key_label":0,"unicode":113,"location":0,"echo":false,"script":null) -] -} -secondary_fire={ -"deadzone": 0.5, -"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":81,"key_label":0,"unicode":113,"location":0,"echo":false,"script":null) -, Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":0,"position":Vector2(0, 0),"global_position":Vector2(0, 0),"factor":1.0,"button_index":2,"canceled":false,"pressed":false,"double_click":false,"script":null) -, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194325,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null) -] -} -pause={ -"deadzone": 0.5, -"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":80,"key_label":0,"unicode":112,"location":0,"echo":false,"script":null) ] } diff --git a/quare_ability.tscn b/quare_ability.tscn index 4dde334..12b65f5 100644 --- a/quare_ability.tscn +++ b/quare_ability.tscn @@ -1,9 +1,10 @@ -[gd_scene load_steps=7 format=3 uid="uid://d2xigwib6hka4"] +[gd_scene load_steps=8 format=3 uid="uid://d2xigwib6hka4"] [ext_resource type="Texture2D" uid="uid://ba2tcipuc8rdi" path="res://quare 2.png" id="1_thx02"] [ext_resource type="Shader" uid="uid://c2p7rwspwqmr8" path="res://greyscale.tres" id="1_unkpb"] [ext_resource type="Texture2D" uid="uid://barlie6sierj" path="res://square.png" id="2_odtey"] [ext_resource type="Script" path="res://RechargeProgress.gd" id="3_gufwx"] +[ext_resource type="Texture2D" uid="uid://cqxvhnxgi4k7" path="res://1-Bit Input Prompts Pixel 16/Tiles (White)/tile_0357.png" id="5_isqlk"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_5a8v0"] resource_local_to_scene = true @@ -29,3 +30,18 @@ texture_progress = ExtResource("2_odtey") texture_progress_offset = Vector2(2.08165e-12, 2.08165e-12) tint_progress = Color(0, 0, 0, 0.443137) script = ExtResource("3_gufwx") + +[node name="prompt" type="TextureRect" parent="."] +self_modulate = Color(1, 1, 1, 0.552941) +layout_mode = 1 +anchors_preset = 7 +anchor_left = 0.5 +anchor_top = 1.0 +anchor_right = 0.5 +anchor_bottom = 1.0 +offset_left = -17.0 +offset_right = 23.0 +offset_bottom = 40.0 +grow_horizontal = 2 +grow_vertical = 0 +texture = ExtResource("5_isqlk") diff --git a/riangle.tscn b/riangle.tscn index 9c24a59..057f708 100644 --- a/riangle.tscn +++ b/riangle.tscn @@ -66,7 +66,7 @@ animations = [{ }], "loop": true, "name": &"default", -"speed": 5.0 +"speed": 10.0 }] [node name="Riangle" type="StaticBody2D" groups=["destructible", "enemy"]] @@ -80,8 +80,6 @@ rotation = 1.5708 scale = Vector2(5.50033, 5.50033) sprite_frames = SubResource("SpriteFrames_p5dvv") autoplay = "default" -frame = 6 -frame_progress = 0.850246 [node name="Gun2" type="Marker2D" parent="."] position = Vector2(-224, 284) @@ -101,7 +99,7 @@ script = ExtResource("3_kffl0") bullet = ExtResource("4_tfncc") [node name="Timer" type="Timer" parent="."] -wait_time = 1.5 +wait_time = 3.0 autostart = true [node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."] diff --git a/shield.gd b/shield.gd index 18aa90d..c37ac2a 100644 --- a/shield.gd +++ b/shield.gd @@ -13,7 +13,7 @@ func _ready() -> void: if find_collisionshape(): print(find_collisionshape().get_parent().name) find_collisionshape().set_deferred("disabled", true) - $Collider.set_deferred("disabled", false) + #$Collider.set_deferred("disabled", false) func destroy(): if find_collisionshape(): diff --git a/shield.tscn b/shield.tscn index 7edd12e..1b8347c 100644 --- a/shield.tscn +++ b/shield.tscn @@ -1,6 +1,6 @@ [gd_scene load_steps=19 format=3 uid="uid://c3s8as813frjc"] -[ext_resource type="Script" path="res://shield.gd" id="1_v4v4e"] +[ext_resource type="Script" path="res://shield.gd" id="1_ni0ln"] [ext_resource type="Texture2D" uid="uid://cc3nl13t7c4mj" path="res://eart-shield.png" id="2_2bt8h"] [ext_resource type="Texture2D" uid="uid://dysewmpj8nvgx" path="res://eart-shield-break.png" id="3_1tta6"] @@ -111,9 +111,9 @@ animations = [{ [sub_resource type="CircleShape2D" id="CircleShape2D_00lvq"] radius = 25.1794 -[node name="Shield" type="StaticBody2D" groups=["destructible"]] -scale = Vector2(3.5, 3.5) -script = ExtResource("1_v4v4e") +[node name="Shield" type="AnimatableBody2D" groups=["destructible"]] +scale = Vector2(3, 3) +script = ExtResource("1_ni0ln") [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] sprite_frames = SubResource("SpriteFrames_gcmwu") @@ -123,6 +123,5 @@ autoplay = "default" [node name="Collider" type="CollisionShape2D" parent="."] position = Vector2(-1, 0) shape = SubResource("CircleShape2D_00lvq") -disabled = true [connection signal="animation_finished" from="AnimatedSprite2D" to="." method="queue_free"] diff --git a/shield_bullet.gd b/shield_bullet.gd index a315d78..b76dc5a 100644 --- a/shield_bullet.gd +++ b/shield_bullet.gd @@ -3,7 +3,6 @@ extends RigidBody2D @onready var player = $"../Player" var shield_scene = preload("res://shield.tscn") -var player_shield = preload("res://player-shield.tscn") func _physics_process(delta): rotation = linear_velocity.angle() @@ -15,23 +14,8 @@ func hit(body): var shield = shield_scene.instantiate() - if body.has_node("Shield"): - queue_free() - return - if body.name == "Player": - shield = player_shield.instantiate() - var marker = body.get_node("ShieldMarker") - - shield.position = marker.position - shield.scale = marker.scale - - body.add_child(shield) - - elif body.has_node("ShieldMarker"): - if body.get_node("ShieldMarker").has_node("Shield"): - queue_free() - return + if body.has_node("ShieldMarker"): shield.scale = Vector2.ONE body.get_node("ShieldMarker").add_child(shield) else: