diff --git a/assets/tileset/snowland/Snowland@64x64.png b/assets/tileset/snowland/Snowland@64x64.png new file mode 100644 index 0000000..4a07286 Binary files /dev/null and b/assets/tileset/snowland/Snowland@64x64.png differ diff --git a/assets/tileset/snowland/Snowland@64x64.png.import b/assets/tileset/snowland/Snowland@64x64.png.import new file mode 100644 index 0000000..b7eba1f --- /dev/null +++ b/assets/tileset/snowland/Snowland@64x64.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bq6hnxbt4w37u" +path="res://.godot/imported/Snowland@64x64.png-668e70d3ab246c642a8c023e626eafa5.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/tileset/snowland/Snowland@64x64.png" +dest_files=["res://.godot/imported/Snowland@64x64.png-668e70d3ab246c642a8c023e626eafa5.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/project.godot b/project.godot index 1c5cf49..db8ca09 100644 --- a/project.godot +++ b/project.godot @@ -11,17 +11,21 @@ config_version=5 [application] config/name="Frontier of Hell" -run/main_scene="res://scenes/stages/stage_1.tscn" +run/main_scene="res://scenes/stages/stage_2.tscn" config/features=PackedStringArray("4.1", "Mobile") boot_splash/bg_color=Color(0.141176, 0.141176, 0.141176, 1) boot_splash/image="res://assets/icons/logo.png" -config/icon="res://icon.svg" +config/icon="res://assets/icons/logo.png" boot_splash/minimum_display_time=3 [display] window/stretch/mode="viewport" +[filesystem] + +import/blender/enabled=false + [layer_names] 2d_physics/layer_1="Objects" diff --git a/scenes/stages/stage_1.tres b/scenes/stages/stage_1.tres new file mode 100644 index 0000000..9a62f2f --- /dev/null +++ b/scenes/stages/stage_1.tres @@ -0,0 +1,513 @@ +[gd_resource type="TileSet" load_steps=5 format=3 uid="uid://2u7m4ggcr08j"] + +[ext_resource type="Texture2D" uid="uid://cnxj0mf3luxo" path="res://assets/tileset/ashlands/tf_A5_ashlands_3.png" id="1_og26w"] +[ext_resource type="Texture2D" uid="uid://danbfdqmqu23q" path="res://assets/tileset/ashlands/tf_B_ashlands_3.png" id="2_v3iem"] + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_7yb1o"] +texture = ExtResource("1_og26w") +texture_region_size = Vector2i(48, 48) +1:0/0 = 0 +1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:0/0/physics_layer_0/angular_velocity = 0.0 +2:0/0 = 0 +2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:0/0/physics_layer_0/angular_velocity = 0.0 +3:0/0 = 0 +3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:0/0/physics_layer_0/angular_velocity = 0.0 +4:0/0 = 0 +4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:0/0/physics_layer_0/angular_velocity = 0.0 +5:0/0 = 0 +5:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:0/0/physics_layer_0/angular_velocity = 0.0 +6:0/0 = 0 +6:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:0/0/physics_layer_0/angular_velocity = 0.0 +7:0/0 = 0 +7:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:0/0/physics_layer_0/angular_velocity = 0.0 +0:1/0 = 0 +0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:1/0/physics_layer_0/angular_velocity = 0.0 +1:1/0 = 0 +1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:1/0/physics_layer_0/angular_velocity = 0.0 +2:1/0 = 0 +2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:1/0/physics_layer_0/angular_velocity = 0.0 +3:1/0 = 0 +3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:1/0/physics_layer_0/angular_velocity = 0.0 +4:1/0 = 0 +4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:1/0/physics_layer_0/angular_velocity = 0.0 +5:1/0 = 0 +5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:1/0/physics_layer_0/angular_velocity = 0.0 +6:1/0 = 0 +6:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:1/0/physics_layer_0/angular_velocity = 0.0 +7:1/0 = 0 +7:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:1/0/physics_layer_0/angular_velocity = 0.0 +0:2/0 = 0 +0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:2/0/physics_layer_0/angular_velocity = 0.0 +1:2/0 = 0 +1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:2/0/physics_layer_0/angular_velocity = 0.0 +2:2/0 = 0 +2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:2/0/physics_layer_0/angular_velocity = 0.0 +3:2/0 = 0 +3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:2/0/physics_layer_0/angular_velocity = 0.0 +4:2/0 = 0 +4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:2/0/physics_layer_0/angular_velocity = 0.0 +5:2/0 = 0 +5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:2/0/physics_layer_0/angular_velocity = 0.0 +6:2/0 = 0 +6:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:2/0/physics_layer_0/angular_velocity = 0.0 +7:2/0 = 0 +7:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:2/0/physics_layer_0/angular_velocity = 0.0 +0:3/0 = 0 +0:3/0/terrain_set = 0 +0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:3/0/physics_layer_0/angular_velocity = 0.0 +0:3/0/terrains_peering_bit/bottom_right_corner = 0 +1:3/0 = 0 +1:3/0/terrain_set = 0 +1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:3/0/physics_layer_0/angular_velocity = 0.0 +1:3/0/terrains_peering_bit/bottom_right_corner = 0 +1:3/0/terrains_peering_bit/bottom_side = 0 +1:3/0/terrains_peering_bit/bottom_left_corner = 0 +2:3/0 = 0 +2:3/0/terrain_set = 0 +2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:3/0/physics_layer_0/angular_velocity = 0.0 +2:3/0/terrains_peering_bit/bottom_left_corner = 0 +3:3/0 = 0 +3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:3/0/physics_layer_0/angular_velocity = 0.0 +4:3/0 = 0 +4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:3/0/physics_layer_0/angular_velocity = 0.0 +5:3/0 = 0 +5:3/0/terrain_set = 0 +5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:3/0/physics_layer_0/angular_velocity = 0.0 +5:3/0/terrains_peering_bit/bottom_right_corner = 1 +6:3/0 = 0 +6:3/0/terrain_set = 0 +6:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:3/0/physics_layer_0/angular_velocity = 0.0 +6:3/0/terrains_peering_bit/bottom_right_corner = 1 +6:3/0/terrains_peering_bit/bottom_side = 1 +6:3/0/terrains_peering_bit/bottom_left_corner = 1 +7:3/0 = 0 +7:3/0/terrain_set = 0 +7:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:3/0/physics_layer_0/angular_velocity = 0.0 +7:3/0/terrains_peering_bit/bottom_left_corner = 1 +0:4/0 = 0 +0:4/0/terrain_set = 0 +0:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:4/0/physics_layer_0/angular_velocity = 0.0 +0:4/0/terrains_peering_bit/right_side = 0 +0:4/0/terrains_peering_bit/bottom_right_corner = 0 +0:4/0/terrains_peering_bit/top_right_corner = 0 +1:4/0 = 0 +1:4/0/terrain_set = 0 +1:4/0/terrain = 0 +1:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:4/0/physics_layer_0/angular_velocity = 0.0 +1:4/0/terrains_peering_bit/right_side = 0 +1:4/0/terrains_peering_bit/bottom_right_corner = 0 +1:4/0/terrains_peering_bit/bottom_side = 0 +1:4/0/terrains_peering_bit/bottom_left_corner = 0 +1:4/0/terrains_peering_bit/left_side = 0 +1:4/0/terrains_peering_bit/top_left_corner = 0 +1:4/0/terrains_peering_bit/top_side = 0 +1:4/0/terrains_peering_bit/top_right_corner = 0 +2:4/0 = 0 +2:4/0/terrain_set = 0 +2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:4/0/physics_layer_0/angular_velocity = 0.0 +2:4/0/terrains_peering_bit/bottom_left_corner = 0 +2:4/0/terrains_peering_bit/left_side = 0 +2:4/0/terrains_peering_bit/top_left_corner = 0 +3:4/0 = 0 +3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:4/0/physics_layer_0/angular_velocity = 0.0 +4:4/0 = 0 +4:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:4/0/physics_layer_0/angular_velocity = 0.0 +5:4/0 = 0 +5:4/0/terrain_set = 0 +5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:4/0/physics_layer_0/angular_velocity = 0.0 +5:4/0/terrains_peering_bit/right_side = 1 +5:4/0/terrains_peering_bit/bottom_right_corner = 1 +5:4/0/terrains_peering_bit/top_right_corner = 1 +6:4/0 = 0 +6:4/0/terrain_set = 0 +6:4/0/terrain = 1 +6:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:4/0/physics_layer_0/angular_velocity = 0.0 +6:4/0/terrains_peering_bit/right_side = 1 +6:4/0/terrains_peering_bit/bottom_right_corner = 1 +6:4/0/terrains_peering_bit/bottom_side = 1 +6:4/0/terrains_peering_bit/bottom_left_corner = 1 +6:4/0/terrains_peering_bit/left_side = 1 +6:4/0/terrains_peering_bit/top_left_corner = 1 +6:4/0/terrains_peering_bit/top_side = 1 +6:4/0/terrains_peering_bit/top_right_corner = 1 +7:4/0 = 0 +7:4/0/terrain_set = 0 +7:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:4/0/physics_layer_0/angular_velocity = 0.0 +7:4/0/terrains_peering_bit/bottom_left_corner = 1 +7:4/0/terrains_peering_bit/left_side = 1 +7:4/0/terrains_peering_bit/top_left_corner = 1 +0:5/0 = 0 +0:5/0/terrain_set = 0 +0:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:5/0/physics_layer_0/angular_velocity = 0.0 +0:5/0/terrains_peering_bit/top_right_corner = 0 +1:5/0 = 0 +1:5/0/terrain_set = 0 +1:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:5/0/physics_layer_0/angular_velocity = 0.0 +1:5/0/terrains_peering_bit/top_left_corner = 0 +1:5/0/terrains_peering_bit/top_side = 0 +1:5/0/terrains_peering_bit/top_right_corner = 0 +2:5/0 = 0 +2:5/0/terrain_set = 0 +2:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:5/0/physics_layer_0/angular_velocity = 0.0 +2:5/0/terrains_peering_bit/top_left_corner = 0 +3:5/0 = 0 +3:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:5/0/physics_layer_0/angular_velocity = 0.0 +4:5/0 = 0 +4:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:5/0/physics_layer_0/angular_velocity = 0.0 +5:5/0 = 0 +5:5/0/terrain_set = 0 +5:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:5/0/physics_layer_0/angular_velocity = 0.0 +5:5/0/terrains_peering_bit/top_right_corner = 1 +6:5/0 = 0 +6:5/0/terrain_set = 0 +6:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:5/0/physics_layer_0/angular_velocity = 0.0 +6:5/0/terrains_peering_bit/top_left_corner = 1 +6:5/0/terrains_peering_bit/top_side = 1 +6:5/0/terrains_peering_bit/top_right_corner = 1 +7:5/0 = 0 +7:5/0/terrain_set = 0 +7:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:5/0/physics_layer_0/angular_velocity = 0.0 +7:5/0/terrains_peering_bit/top_left_corner = 1 +0:6/0 = 0 +0:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:6/0/physics_layer_0/angular_velocity = 0.0 +1:6/0 = 0 +1:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:6/0/physics_layer_0/angular_velocity = 0.0 +2:6/0 = 0 +2:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:6/0/physics_layer_0/angular_velocity = 0.0 +3:6/0 = 0 +3:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:6/0/physics_layer_0/angular_velocity = 0.0 +4:6/0 = 0 +4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:6/0/physics_layer_0/angular_velocity = 0.0 +5:6/0 = 0 +5:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:6/0/physics_layer_0/angular_velocity = 0.0 +6:6/0 = 0 +6:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:6/0/physics_layer_0/angular_velocity = 0.0 +7:6/0 = 0 +7:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:6/0/physics_layer_0/angular_velocity = 0.0 +0:7/0 = 0 +0:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:7/0/physics_layer_0/angular_velocity = 0.0 +2:7/0 = 0 +2:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:7/0/physics_layer_0/angular_velocity = 0.0 +3:7/0 = 0 +3:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:7/0/physics_layer_0/angular_velocity = 0.0 +4:7/0 = 0 +4:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:7/0/physics_layer_0/angular_velocity = 0.0 +5:7/0 = 0 +5:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:7/0/physics_layer_0/angular_velocity = 0.0 +6:7/0 = 0 +6:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:7/0/physics_layer_0/angular_velocity = 0.0 +7:7/0 = 0 +7:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:7/0/physics_layer_0/angular_velocity = 0.0 +0:8/0 = 0 +0:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:8/0/physics_layer_0/angular_velocity = 0.0 +1:8/0 = 0 +1:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:8/0/physics_layer_0/angular_velocity = 0.0 +2:8/0 = 0 +2:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:8/0/physics_layer_0/angular_velocity = 0.0 +3:8/0 = 0 +3:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:8/0/physics_layer_0/angular_velocity = 0.0 +4:8/0 = 0 +4:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:8/0/physics_layer_0/angular_velocity = 0.0 +5:8/0 = 0 +5:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:8/0/physics_layer_0/angular_velocity = 0.0 +6:8/0 = 0 +6:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:8/0/physics_layer_0/angular_velocity = 0.0 +7:8/0 = 0 +7:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:8/0/physics_layer_0/angular_velocity = 0.0 +0:9/0 = 0 +0:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:9/0/physics_layer_0/angular_velocity = 0.0 +1:9/0 = 0 +1:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:9/0/physics_layer_0/angular_velocity = 0.0 +2:9/0 = 0 +2:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:9/0/physics_layer_0/angular_velocity = 0.0 +3:9/0 = 0 +3:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:9/0/physics_layer_0/angular_velocity = 0.0 +4:9/0 = 0 +4:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:9/0/physics_layer_0/angular_velocity = 0.0 +5:9/0 = 0 +5:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:9/0/physics_layer_0/angular_velocity = 0.0 +6:9/0 = 0 +6:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:9/0/physics_layer_0/angular_velocity = 0.0 +7:9/0 = 0 +7:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:9/0/physics_layer_0/angular_velocity = 0.0 +0:10/0 = 0 +0:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:10/0/physics_layer_0/angular_velocity = 0.0 +1:10/0 = 0 +1:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:10/0/physics_layer_0/angular_velocity = 0.0 +2:10/0 = 0 +2:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:10/0/physics_layer_0/angular_velocity = 0.0 +3:10/0 = 0 +3:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:10/0/physics_layer_0/angular_velocity = 0.0 +4:10/0 = 0 +4:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:10/0/physics_layer_0/angular_velocity = 0.0 +5:10/0 = 0 +5:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:10/0/physics_layer_0/angular_velocity = 0.0 +6:10/0 = 0 +6:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:10/0/physics_layer_0/angular_velocity = 0.0 +7:10/0 = 0 +7:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:10/0/physics_layer_0/angular_velocity = 0.0 +0:11/0 = 0 +0:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:11/0/physics_layer_0/angular_velocity = 0.0 +1:11/0 = 0 +1:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:11/0/physics_layer_0/angular_velocity = 0.0 +2:11/0 = 0 +2:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:11/0/physics_layer_0/angular_velocity = 0.0 +3:11/0 = 0 +3:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:11/0/physics_layer_0/angular_velocity = 0.0 +4:11/0 = 0 +4:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:11/0/physics_layer_0/angular_velocity = 0.0 +5:11/0 = 0 +5:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:11/0/physics_layer_0/angular_velocity = 0.0 +6:11/0 = 0 +6:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:11/0/physics_layer_0/angular_velocity = 0.0 +7:11/0 = 0 +7:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:11/0/physics_layer_0/angular_velocity = 0.0 +0:12/0 = 0 +0:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:12/0/physics_layer_0/angular_velocity = 0.0 +1:12/0 = 0 +1:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:12/0/physics_layer_0/angular_velocity = 0.0 +2:12/0 = 0 +2:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:12/0/physics_layer_0/angular_velocity = 0.0 +3:12/0 = 0 +3:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:12/0/physics_layer_0/angular_velocity = 0.0 +4:12/0 = 0 +4:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:12/0/physics_layer_0/angular_velocity = 0.0 +5:12/0 = 0 +5:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:12/0/physics_layer_0/angular_velocity = 0.0 +6:12/0 = 0 +6:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:12/0/physics_layer_0/angular_velocity = 0.0 +7:12/0 = 0 +7:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:12/0/physics_layer_0/angular_velocity = 0.0 +0:13/0 = 0 +0:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:13/0/physics_layer_0/angular_velocity = 0.0 +1:13/0 = 0 +1:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:13/0/physics_layer_0/angular_velocity = 0.0 +2:13/0 = 0 +2:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:13/0/physics_layer_0/angular_velocity = 0.0 +3:13/0 = 0 +3:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:13/0/physics_layer_0/angular_velocity = 0.0 +4:13/0 = 0 +4:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:13/0/physics_layer_0/angular_velocity = 0.0 +5:13/0 = 0 +5:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:13/0/physics_layer_0/angular_velocity = 0.0 +6:13/0 = 0 +6:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:13/0/physics_layer_0/angular_velocity = 0.0 +7:13/0 = 0 +7:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:13/0/physics_layer_0/angular_velocity = 0.0 +0:14/0 = 0 +0:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:14/0/physics_layer_0/angular_velocity = 0.0 +1:14/0 = 0 +1:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:14/0/physics_layer_0/angular_velocity = 0.0 +2:14/0 = 0 +2:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:14/0/physics_layer_0/angular_velocity = 0.0 +3:14/0 = 0 +3:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:14/0/physics_layer_0/angular_velocity = 0.0 +4:14/0 = 0 +4:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:14/0/physics_layer_0/angular_velocity = 0.0 +5:14/0 = 0 +5:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:14/0/physics_layer_0/angular_velocity = 0.0 +6:14/0 = 0 +6:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:14/0/physics_layer_0/angular_velocity = 0.0 +7:14/0 = 0 +7:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) +7:14/0/physics_layer_0/angular_velocity = 0.0 + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_knagf"] +texture = ExtResource("2_v3iem") +texture_region_size = Vector2i(48, 48) +4:6/size_in_atlas = Vector2i(4, 5) +4:6/0 = 0 +4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:6/0/physics_layer_0/angular_velocity = 0.0 +0:9/size_in_atlas = Vector2i(1, 2) +0:9/0 = 0 +0:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:9/0/physics_layer_0/angular_velocity = 0.0 +1:9/size_in_atlas = Vector2i(1, 2) +1:9/0 = 0 +1:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:9/0/physics_layer_0/angular_velocity = 0.0 +5:4/size_in_atlas = Vector2i(3, 2) +5:4/0 = 0 +5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:4/0/physics_layer_0/angular_velocity = 0.0 +3:4/size_in_atlas = Vector2i(2, 2) +3:4/0 = 0 +3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:4/0/physics_layer_0/angular_velocity = 0.0 +1:0/0 = 0 +1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:0/0/physics_layer_0/angular_velocity = 0.0 +2:0/0 = 0 +2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:0/0/physics_layer_0/angular_velocity = 0.0 +3:0/0 = 0 +3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:0/0/physics_layer_0/angular_velocity = 0.0 +4:0/0 = 0 +4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:0/0/physics_layer_0/angular_velocity = 0.0 +5:1/0 = 0 +5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:1/0/physics_layer_0/angular_velocity = 0.0 +6:1/size_in_atlas = Vector2i(2, 1) +6:1/0 = 0 +6:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:1/0/physics_layer_0/angular_velocity = 0.0 +2:4/size_in_atlas = Vector2i(1, 2) +2:4/0 = 0 +2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:4/0/physics_layer_0/angular_velocity = 0.0 +0:12/0 = 0 +0:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:12/0/physics_layer_0/angular_velocity = 0.0 +1:12/0 = 0 +1:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:12/0/physics_layer_0/angular_velocity = 0.0 +2:12/0 = 0 +2:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:12/0/physics_layer_0/angular_velocity = 0.0 +3:12/0 = 0 +3:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:12/0/physics_layer_0/angular_velocity = 0.0 +4:12/0 = 0 +4:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:12/0/physics_layer_0/angular_velocity = 0.0 +5:12/0 = 0 +5:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:12/0/physics_layer_0/angular_velocity = 0.0 +6:12/0 = 0 +6:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) +6:12/0/physics_layer_0/angular_velocity = 0.0 +0:13/size_in_atlas = Vector2i(3, 3) +0:13/0 = 0 +0:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:13/0/physics_layer_0/angular_velocity = 0.0 + +[resource] +tile_size = Vector2i(48, 48) +physics_layer_0/collision_layer = 1 +terrain_set_0/mode = 0 +terrain_set_0/terrain_0/name = "Path" +terrain_set_0/terrain_0/color = Color(0.407843, 0.407843, 0.407843, 1) +terrain_set_0/terrain_1/name = "Ground" +terrain_set_0/terrain_1/color = Color(0.345098, 0.254902, 0.196078, 1) +sources/0 = SubResource("TileSetAtlasSource_7yb1o") +sources/2 = SubResource("TileSetAtlasSource_knagf") diff --git a/scenes/stages/stage_1.tscn b/scenes/stages/stage_1.tscn index 571db7b..c60d7ec 100644 --- a/scenes/stages/stage_1.tscn +++ b/scenes/stages/stage_1.tscn @@ -1,8 +1,7 @@ -[gd_scene load_steps=14 format=3 uid="uid://btdewn34d67m"] +[gd_scene load_steps=10 format=3 uid="uid://btdewn34d67m"] [ext_resource type="Script" path="res://scripts/stages/1/game_manager.gd" id="1_aosti"] -[ext_resource type="Texture2D" uid="uid://cnxj0mf3luxo" path="res://assets/tileset/ashlands/tf_A5_ashlands_3.png" id="2_1njjc"] -[ext_resource type="Texture2D" uid="uid://danbfdqmqu23q" path="res://assets/tileset/ashlands/tf_B_ashlands_3.png" id="3_l5wod"] +[ext_resource type="TileSet" uid="uid://2u7m4ggcr08j" path="res://scenes/stages/stage_1.tres" id="2_3jjum"] [ext_resource type="Script" path="res://scripts/stages/1/summon.gd" id="4_gt08o"] [ext_resource type="PackedScene" uid="uid://bhnv1dsggssil" path="res://scenes/ui/pause_menu.tscn" id="5_0gif7"] [ext_resource type="PackedScene" uid="uid://cd5r1v6f8hahx" path="res://scenes/ui/tower_menu.tscn" id="5_3w5lp"] @@ -10,515 +9,6 @@ [ext_resource type="PackedScene" uid="uid://bvoenhbaqiqj2" path="res://scenes/towers/placement/placement.tscn" id="6_mao4r"] [ext_resource type="PackedScene" uid="uid://cikgeqqhctm7k" path="res://scenes/base/base.tscn" id="8_rsf1n"] -[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_7yb1o"] -texture = ExtResource("2_1njjc") -texture_region_size = Vector2i(48, 48) -1:0/0 = 0 -1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:0/0/physics_layer_0/angular_velocity = 0.0 -2:0/0 = 0 -2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:0/0/physics_layer_0/angular_velocity = 0.0 -3:0/0 = 0 -3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:0/0/physics_layer_0/angular_velocity = 0.0 -4:0/0 = 0 -4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:0/0/physics_layer_0/angular_velocity = 0.0 -5:0/0 = 0 -5:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:0/0/physics_layer_0/angular_velocity = 0.0 -6:0/0 = 0 -6:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:0/0/physics_layer_0/angular_velocity = 0.0 -7:0/0 = 0 -7:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:0/0/physics_layer_0/angular_velocity = 0.0 -0:1/0 = 0 -0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:1/0/physics_layer_0/angular_velocity = 0.0 -1:1/0 = 0 -1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:1/0/physics_layer_0/angular_velocity = 0.0 -2:1/0 = 0 -2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:1/0/physics_layer_0/angular_velocity = 0.0 -3:1/0 = 0 -3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:1/0/physics_layer_0/angular_velocity = 0.0 -4:1/0 = 0 -4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:1/0/physics_layer_0/angular_velocity = 0.0 -5:1/0 = 0 -5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:1/0/physics_layer_0/angular_velocity = 0.0 -6:1/0 = 0 -6:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:1/0/physics_layer_0/angular_velocity = 0.0 -7:1/0 = 0 -7:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:1/0/physics_layer_0/angular_velocity = 0.0 -0:2/0 = 0 -0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:2/0/physics_layer_0/angular_velocity = 0.0 -1:2/0 = 0 -1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:2/0/physics_layer_0/angular_velocity = 0.0 -2:2/0 = 0 -2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:2/0/physics_layer_0/angular_velocity = 0.0 -3:2/0 = 0 -3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:2/0/physics_layer_0/angular_velocity = 0.0 -4:2/0 = 0 -4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:2/0/physics_layer_0/angular_velocity = 0.0 -5:2/0 = 0 -5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:2/0/physics_layer_0/angular_velocity = 0.0 -6:2/0 = 0 -6:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:2/0/physics_layer_0/angular_velocity = 0.0 -7:2/0 = 0 -7:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:2/0/physics_layer_0/angular_velocity = 0.0 -0:3/0 = 0 -0:3/0/terrain_set = 0 -0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:3/0/physics_layer_0/angular_velocity = 0.0 -0:3/0/terrains_peering_bit/bottom_right_corner = 0 -1:3/0 = 0 -1:3/0/terrain_set = 0 -1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:3/0/physics_layer_0/angular_velocity = 0.0 -1:3/0/terrains_peering_bit/bottom_right_corner = 0 -1:3/0/terrains_peering_bit/bottom_side = 0 -1:3/0/terrains_peering_bit/bottom_left_corner = 0 -2:3/0 = 0 -2:3/0/terrain_set = 0 -2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:3/0/physics_layer_0/angular_velocity = 0.0 -2:3/0/terrains_peering_bit/bottom_left_corner = 0 -3:3/0 = 0 -3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:3/0/physics_layer_0/angular_velocity = 0.0 -4:3/0 = 0 -4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:3/0/physics_layer_0/angular_velocity = 0.0 -5:3/0 = 0 -5:3/0/terrain_set = 0 -5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:3/0/physics_layer_0/angular_velocity = 0.0 -5:3/0/terrains_peering_bit/bottom_right_corner = 1 -6:3/0 = 0 -6:3/0/terrain_set = 0 -6:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:3/0/physics_layer_0/angular_velocity = 0.0 -6:3/0/terrains_peering_bit/bottom_right_corner = 1 -6:3/0/terrains_peering_bit/bottom_side = 1 -6:3/0/terrains_peering_bit/bottom_left_corner = 1 -7:3/0 = 0 -7:3/0/terrain_set = 0 -7:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:3/0/physics_layer_0/angular_velocity = 0.0 -7:3/0/terrains_peering_bit/bottom_left_corner = 1 -0:4/0 = 0 -0:4/0/terrain_set = 0 -0:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:4/0/physics_layer_0/angular_velocity = 0.0 -0:4/0/terrains_peering_bit/right_side = 0 -0:4/0/terrains_peering_bit/bottom_right_corner = 0 -0:4/0/terrains_peering_bit/top_right_corner = 0 -1:4/0 = 0 -1:4/0/terrain_set = 0 -1:4/0/terrain = 0 -1:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:4/0/physics_layer_0/angular_velocity = 0.0 -1:4/0/terrains_peering_bit/right_side = 0 -1:4/0/terrains_peering_bit/bottom_right_corner = 0 -1:4/0/terrains_peering_bit/bottom_side = 0 -1:4/0/terrains_peering_bit/bottom_left_corner = 0 -1:4/0/terrains_peering_bit/left_side = 0 -1:4/0/terrains_peering_bit/top_left_corner = 0 -1:4/0/terrains_peering_bit/top_side = 0 -1:4/0/terrains_peering_bit/top_right_corner = 0 -2:4/0 = 0 -2:4/0/terrain_set = 0 -2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:4/0/physics_layer_0/angular_velocity = 0.0 -2:4/0/terrains_peering_bit/bottom_left_corner = 0 -2:4/0/terrains_peering_bit/left_side = 0 -2:4/0/terrains_peering_bit/top_left_corner = 0 -3:4/0 = 0 -3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:4/0/physics_layer_0/angular_velocity = 0.0 -4:4/0 = 0 -4:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:4/0/physics_layer_0/angular_velocity = 0.0 -5:4/0 = 0 -5:4/0/terrain_set = 0 -5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:4/0/physics_layer_0/angular_velocity = 0.0 -5:4/0/terrains_peering_bit/right_side = 1 -5:4/0/terrains_peering_bit/bottom_right_corner = 1 -5:4/0/terrains_peering_bit/top_right_corner = 1 -6:4/0 = 0 -6:4/0/terrain_set = 0 -6:4/0/terrain = 1 -6:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:4/0/physics_layer_0/angular_velocity = 0.0 -6:4/0/terrains_peering_bit/right_side = 1 -6:4/0/terrains_peering_bit/bottom_right_corner = 1 -6:4/0/terrains_peering_bit/bottom_side = 1 -6:4/0/terrains_peering_bit/bottom_left_corner = 1 -6:4/0/terrains_peering_bit/left_side = 1 -6:4/0/terrains_peering_bit/top_left_corner = 1 -6:4/0/terrains_peering_bit/top_side = 1 -6:4/0/terrains_peering_bit/top_right_corner = 1 -7:4/0 = 0 -7:4/0/terrain_set = 0 -7:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:4/0/physics_layer_0/angular_velocity = 0.0 -7:4/0/terrains_peering_bit/bottom_left_corner = 1 -7:4/0/terrains_peering_bit/left_side = 1 -7:4/0/terrains_peering_bit/top_left_corner = 1 -0:5/0 = 0 -0:5/0/terrain_set = 0 -0:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:5/0/physics_layer_0/angular_velocity = 0.0 -0:5/0/terrains_peering_bit/top_right_corner = 0 -1:5/0 = 0 -1:5/0/terrain_set = 0 -1:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:5/0/physics_layer_0/angular_velocity = 0.0 -1:5/0/terrains_peering_bit/top_left_corner = 0 -1:5/0/terrains_peering_bit/top_side = 0 -1:5/0/terrains_peering_bit/top_right_corner = 0 -2:5/0 = 0 -2:5/0/terrain_set = 0 -2:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:5/0/physics_layer_0/angular_velocity = 0.0 -2:5/0/terrains_peering_bit/top_left_corner = 0 -3:5/0 = 0 -3:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:5/0/physics_layer_0/angular_velocity = 0.0 -4:5/0 = 0 -4:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:5/0/physics_layer_0/angular_velocity = 0.0 -5:5/0 = 0 -5:5/0/terrain_set = 0 -5:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:5/0/physics_layer_0/angular_velocity = 0.0 -5:5/0/terrains_peering_bit/top_right_corner = 1 -6:5/0 = 0 -6:5/0/terrain_set = 0 -6:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:5/0/physics_layer_0/angular_velocity = 0.0 -6:5/0/terrains_peering_bit/top_left_corner = 1 -6:5/0/terrains_peering_bit/top_side = 1 -6:5/0/terrains_peering_bit/top_right_corner = 1 -7:5/0 = 0 -7:5/0/terrain_set = 0 -7:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:5/0/physics_layer_0/angular_velocity = 0.0 -7:5/0/terrains_peering_bit/top_left_corner = 1 -0:6/0 = 0 -0:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:6/0/physics_layer_0/angular_velocity = 0.0 -1:6/0 = 0 -1:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:6/0/physics_layer_0/angular_velocity = 0.0 -2:6/0 = 0 -2:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:6/0/physics_layer_0/angular_velocity = 0.0 -3:6/0 = 0 -3:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:6/0/physics_layer_0/angular_velocity = 0.0 -4:6/0 = 0 -4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:6/0/physics_layer_0/angular_velocity = 0.0 -5:6/0 = 0 -5:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:6/0/physics_layer_0/angular_velocity = 0.0 -6:6/0 = 0 -6:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:6/0/physics_layer_0/angular_velocity = 0.0 -7:6/0 = 0 -7:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:6/0/physics_layer_0/angular_velocity = 0.0 -0:7/0 = 0 -0:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:7/0/physics_layer_0/angular_velocity = 0.0 -2:7/0 = 0 -2:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:7/0/physics_layer_0/angular_velocity = 0.0 -3:7/0 = 0 -3:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:7/0/physics_layer_0/angular_velocity = 0.0 -4:7/0 = 0 -4:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:7/0/physics_layer_0/angular_velocity = 0.0 -5:7/0 = 0 -5:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:7/0/physics_layer_0/angular_velocity = 0.0 -6:7/0 = 0 -6:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:7/0/physics_layer_0/angular_velocity = 0.0 -7:7/0 = 0 -7:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:7/0/physics_layer_0/angular_velocity = 0.0 -0:8/0 = 0 -0:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:8/0/physics_layer_0/angular_velocity = 0.0 -1:8/0 = 0 -1:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:8/0/physics_layer_0/angular_velocity = 0.0 -2:8/0 = 0 -2:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:8/0/physics_layer_0/angular_velocity = 0.0 -3:8/0 = 0 -3:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:8/0/physics_layer_0/angular_velocity = 0.0 -4:8/0 = 0 -4:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:8/0/physics_layer_0/angular_velocity = 0.0 -5:8/0 = 0 -5:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:8/0/physics_layer_0/angular_velocity = 0.0 -6:8/0 = 0 -6:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:8/0/physics_layer_0/angular_velocity = 0.0 -7:8/0 = 0 -7:8/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:8/0/physics_layer_0/angular_velocity = 0.0 -0:9/0 = 0 -0:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:9/0/physics_layer_0/angular_velocity = 0.0 -1:9/0 = 0 -1:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:9/0/physics_layer_0/angular_velocity = 0.0 -2:9/0 = 0 -2:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:9/0/physics_layer_0/angular_velocity = 0.0 -3:9/0 = 0 -3:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:9/0/physics_layer_0/angular_velocity = 0.0 -4:9/0 = 0 -4:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:9/0/physics_layer_0/angular_velocity = 0.0 -5:9/0 = 0 -5:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:9/0/physics_layer_0/angular_velocity = 0.0 -6:9/0 = 0 -6:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:9/0/physics_layer_0/angular_velocity = 0.0 -7:9/0 = 0 -7:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:9/0/physics_layer_0/angular_velocity = 0.0 -0:10/0 = 0 -0:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:10/0/physics_layer_0/angular_velocity = 0.0 -1:10/0 = 0 -1:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:10/0/physics_layer_0/angular_velocity = 0.0 -2:10/0 = 0 -2:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:10/0/physics_layer_0/angular_velocity = 0.0 -3:10/0 = 0 -3:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:10/0/physics_layer_0/angular_velocity = 0.0 -4:10/0 = 0 -4:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:10/0/physics_layer_0/angular_velocity = 0.0 -5:10/0 = 0 -5:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:10/0/physics_layer_0/angular_velocity = 0.0 -6:10/0 = 0 -6:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:10/0/physics_layer_0/angular_velocity = 0.0 -7:10/0 = 0 -7:10/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:10/0/physics_layer_0/angular_velocity = 0.0 -0:11/0 = 0 -0:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:11/0/physics_layer_0/angular_velocity = 0.0 -1:11/0 = 0 -1:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:11/0/physics_layer_0/angular_velocity = 0.0 -2:11/0 = 0 -2:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:11/0/physics_layer_0/angular_velocity = 0.0 -3:11/0 = 0 -3:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:11/0/physics_layer_0/angular_velocity = 0.0 -4:11/0 = 0 -4:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:11/0/physics_layer_0/angular_velocity = 0.0 -5:11/0 = 0 -5:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:11/0/physics_layer_0/angular_velocity = 0.0 -6:11/0 = 0 -6:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:11/0/physics_layer_0/angular_velocity = 0.0 -7:11/0 = 0 -7:11/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:11/0/physics_layer_0/angular_velocity = 0.0 -0:12/0 = 0 -0:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:12/0/physics_layer_0/angular_velocity = 0.0 -1:12/0 = 0 -1:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:12/0/physics_layer_0/angular_velocity = 0.0 -2:12/0 = 0 -2:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:12/0/physics_layer_0/angular_velocity = 0.0 -3:12/0 = 0 -3:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:12/0/physics_layer_0/angular_velocity = 0.0 -4:12/0 = 0 -4:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:12/0/physics_layer_0/angular_velocity = 0.0 -5:12/0 = 0 -5:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:12/0/physics_layer_0/angular_velocity = 0.0 -6:12/0 = 0 -6:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:12/0/physics_layer_0/angular_velocity = 0.0 -7:12/0 = 0 -7:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:12/0/physics_layer_0/angular_velocity = 0.0 -0:13/0 = 0 -0:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:13/0/physics_layer_0/angular_velocity = 0.0 -1:13/0 = 0 -1:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:13/0/physics_layer_0/angular_velocity = 0.0 -2:13/0 = 0 -2:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:13/0/physics_layer_0/angular_velocity = 0.0 -3:13/0 = 0 -3:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:13/0/physics_layer_0/angular_velocity = 0.0 -4:13/0 = 0 -4:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:13/0/physics_layer_0/angular_velocity = 0.0 -5:13/0 = 0 -5:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:13/0/physics_layer_0/angular_velocity = 0.0 -6:13/0 = 0 -6:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:13/0/physics_layer_0/angular_velocity = 0.0 -7:13/0 = 0 -7:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:13/0/physics_layer_0/angular_velocity = 0.0 -0:14/0 = 0 -0:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:14/0/physics_layer_0/angular_velocity = 0.0 -1:14/0 = 0 -1:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:14/0/physics_layer_0/angular_velocity = 0.0 -2:14/0 = 0 -2:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:14/0/physics_layer_0/angular_velocity = 0.0 -3:14/0 = 0 -3:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:14/0/physics_layer_0/angular_velocity = 0.0 -4:14/0 = 0 -4:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:14/0/physics_layer_0/angular_velocity = 0.0 -5:14/0 = 0 -5:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:14/0/physics_layer_0/angular_velocity = 0.0 -6:14/0 = 0 -6:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:14/0/physics_layer_0/angular_velocity = 0.0 -7:14/0 = 0 -7:14/0/physics_layer_0/linear_velocity = Vector2(0, 0) -7:14/0/physics_layer_0/angular_velocity = 0.0 - -[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_knagf"] -texture = ExtResource("3_l5wod") -texture_region_size = Vector2i(48, 48) -4:6/size_in_atlas = Vector2i(4, 5) -4:6/0 = 0 -4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:6/0/physics_layer_0/angular_velocity = 0.0 -0:9/size_in_atlas = Vector2i(1, 2) -0:9/0 = 0 -0:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:9/0/physics_layer_0/angular_velocity = 0.0 -1:9/size_in_atlas = Vector2i(1, 2) -1:9/0 = 0 -1:9/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:9/0/physics_layer_0/angular_velocity = 0.0 -5:4/size_in_atlas = Vector2i(3, 2) -5:4/0 = 0 -5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:4/0/physics_layer_0/angular_velocity = 0.0 -3:4/size_in_atlas = Vector2i(2, 2) -3:4/0 = 0 -3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:4/0/physics_layer_0/angular_velocity = 0.0 -1:0/0 = 0 -1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:0/0/physics_layer_0/angular_velocity = 0.0 -2:0/0 = 0 -2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:0/0/physics_layer_0/angular_velocity = 0.0 -3:0/0 = 0 -3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:0/0/physics_layer_0/angular_velocity = 0.0 -4:0/0 = 0 -4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:0/0/physics_layer_0/angular_velocity = 0.0 -5:1/0 = 0 -5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:1/0/physics_layer_0/angular_velocity = 0.0 -6:1/size_in_atlas = Vector2i(2, 1) -6:1/0 = 0 -6:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:1/0/physics_layer_0/angular_velocity = 0.0 -2:4/size_in_atlas = Vector2i(1, 2) -2:4/0 = 0 -2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:4/0/physics_layer_0/angular_velocity = 0.0 -0:12/0 = 0 -0:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:12/0/physics_layer_0/angular_velocity = 0.0 -1:12/0 = 0 -1:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:12/0/physics_layer_0/angular_velocity = 0.0 -2:12/0 = 0 -2:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:12/0/physics_layer_0/angular_velocity = 0.0 -3:12/0 = 0 -3:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:12/0/physics_layer_0/angular_velocity = 0.0 -4:12/0 = 0 -4:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:12/0/physics_layer_0/angular_velocity = 0.0 -5:12/0 = 0 -5:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:12/0/physics_layer_0/angular_velocity = 0.0 -6:12/0 = 0 -6:12/0/physics_layer_0/linear_velocity = Vector2(0, 0) -6:12/0/physics_layer_0/angular_velocity = 0.0 -0:13/size_in_atlas = Vector2i(3, 3) -0:13/0 = 0 -0:13/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:13/0/physics_layer_0/angular_velocity = 0.0 - -[sub_resource type="TileSet" id="TileSet_eqd70"] -tile_size = Vector2i(48, 48) -physics_layer_0/collision_layer = 1 -terrain_set_0/mode = 0 -terrain_set_0/terrain_0/name = "Path" -terrain_set_0/terrain_0/color = Color(0.407843, 0.407843, 0.407843, 1) -terrain_set_0/terrain_1/name = "Ground" -terrain_set_0/terrain_1/color = Color(0.345098, 0.254902, 0.196078, 1) -sources/0 = SubResource("TileSetAtlasSource_7yb1o") -sources/2 = SubResource("TileSetAtlasSource_knagf") - [sub_resource type="Curve2D" id="Curve2D_csucy"] _data = { "points": PackedVector2Array(0, 0, 0, 0, -25, 212, 0, 0, 0, 0, 547, 216, 0, 0, 0, 0, 542, 498, 0, 0, 0, 0, 1176, 500) @@ -530,7 +20,7 @@ process_mode = 1 script = ExtResource("1_aosti") [node name="TileMap" type="TileMap" parent="."] -tile_set = SubResource("TileSet_eqd70") +tile_set = ExtResource("2_3jjum") format = 2 layer_0/name = "Background" layer_0/tile_data = PackedInt32Array(786454, 393216, 4, 786455, 458752, 4, 851991, 458752, 5, 851990, 393216, 5, 851989, 393216, 5, 786453, 393216, 4, 851988, 393216, 5, 786452, 393216, 4, 851987, 393216, 5, 786451, 393216, 4, 851986, 393216, 5, 786450, 393216, 4, 851985, 393216, 5, 786449, 393216, 4, 851984, 393216, 5, 786448, 393216, 4, 851983, 393216, 5, 786447, 393216, 4, 851982, 393216, 5, 786446, 393216, 4, 851981, 393216, 5, 786445, 393216, 4, 851980, 393216, 5, 786444, 393216, 4, 851979, 393216, 5, 786443, 393216, 4, 851978, 393216, 5, 786442, 393216, 4, 851977, 393216, 5, 786441, 393216, 4, 851976, 393216, 5, 786440, 393216, 4, 851975, 393216, 5, 786439, 393216, 4, 720903, 393216, 4, 851974, 393216, 5, 786438, 393216, 4, 720902, 393216, 4, 851973, 393216, 5, 786437, 393216, 4, 720901, 393216, 4, 851972, 393216, 5, 786436, 393216, 4, 720900, 393216, 4, 851971, 393216, 5, 786435, 393216, 4, 720899, 393216, 4, 851970, 393216, 5, 786434, 393216, 4, 720898, 393216, 4, 851969, 393216, 5, 786433, 393216, 4, 720897, 393216, 4, 851968, 327680, 5, 786432, 327680, 4, 720896, 327680, 4, 655360, 327680, 4, 655361, 393216, 4, 655362, 393216, 4, 589824, 327680, 4, 589825, 393216, 4, 589826, 393216, 4, 524288, 327680, 4, 524289, 393216, 4, 524290, 393216, 4, 458752, 327680, 4, 458753, 393216, 4, 458754, 393216, 4, 393216, 327680, 4, 393217, 393216, 4, 262144, 65536, 4, 262145, 65536, 4, 262146, 65536, 4, 65536, 327680, 4, 65537, 393216, 4, 65538, 393216, 4, 0, 327680, 3, 1, 393216, 3, 2, 393216, 3, 65539, 393216, 4, 3, 393216, 3, 65540, 393216, 4, 4, 393216, 3, 65541, 393216, 4, 5, 393216, 3, 65542, 393216, 4, 6, 393216, 3, 65543, 393216, 4, 7, 393216, 3, 65544, 393216, 4, 8, 393216, 3, 65545, 393216, 4, 9, 393216, 3, 65546, 393216, 4, 10, 393216, 3, 12, 393216, 3, 65549, 393216, 4, 13, 393216, 3, 65550, 393216, 4, 14, 393216, 3, 65551, 393216, 4, 131087, 393216, 4, 15, 393216, 3, 65552, 393216, 4, 16, 393216, 3, 65553, 393216, 4, 17, 393216, 3, 65554, 393216, 4, 131090, 393216, 4, 18, 393216, 3, 65555, 393216, 4, 19, 393216, 3, 65556, 393216, 4, 131092, 393216, 4, 20, 393216, 3, 65557, 393216, 4, 131093, 393216, 4, 21, 393216, 3, 65558, 393216, 4, 131094, 393216, 4, 22, 393216, 3, 65559, 458752, 4, 131095, 458752, 4, 23, 458752, 3, 196631, 458752, 4, 196630, 393216, 4, 196629, 393216, 4, 262167, 458752, 4, 262166, 393216, 4, 262165, 393216, 4, 327703, 458752, 4, 327702, 393216, 4, 327701, 393216, 4, 393239, 458752, 4, 393238, 393216, 4, 393237, 393216, 4, 458775, 458752, 4, 458774, 393216, 4, 458773, 393216, 4, 524311, 458752, 4, 524310, 393216, 4, 655383, 65536, 4, 655382, 65536, 4, 655381, 65536, 4, 131091, 393216, 4, 655378, 65536, 4, 655379, 65536, 4, 655380, 65536, 4, 589843, 65536, 3, 589844, 65536, 3, 589842, 65536, 3, 655377, 65536, 4, 655376, 65536, 4, 655375, 65536, 4, 655371, 65536, 4, 589835, 65536, 4, 524299, 65536, 4, 524300, 131072, 4, 458763, 65536, 4, 393227, 65536, 4, 393228, 131072, 4, 458764, 131072, 4, 262152, 65536, 4, 262151, 65536, 4, 262150, 65536, 4, 262149, 65536, 4, 262148, 65536, 4, 262147, 65536, 4, 327684, 65536, 5, 327685, 65536, 5, 327686, 65536, 5, 327687, 65536, 5, 327688, 65536, 5, 65547, 393216, 4, 327690, 65536, 4, 262155, 65536, 4, 262153, 65536, 4, 262154, 65536, 4, 327689, 65536, 5, 327691, 65536, 4, 327692, 131072, 4, 720911, 65536, 5, 720913, 65536, 5, 720914, 65536, 5, 720907, 65536, 5, 720906, 0, 5, 262156, 131072, 4, 196611, 65536, 3, 196612, 65536, 3, 196613, 65536, 3, 196614, 65536, 3, 196615, 65536, 3, 196616, 65536, 3, 196617, 65536, 3, 196618, 65536, 3, 196619, 65536, 3, 393226, 0, 4, 589834, 0, 4, 458762, 0, 4, 524298, 0, 4, 655370, 0, 4, 720912, 65536, 5, 589840, 65536, 3, 589841, 65536, 3, 655372, 65536, 4, 720909, 65536, 5, 720908, 65536, 5, 655374, 65536, 4, 720910, 65536, 5, 589836, 65536, 4, 655373, 65536, 4, 589838, 65536, 3, 589839, 65536, 3, 589837, 65536, 3, 589845, 65536, 3, 720917, 65536, 5, 720916, 65536, 5, 720915, 65536, 5, 720918, 65536, 5, 589846, 65536, 3, 589847, 65536, 3, 720919, 65536, 5, 196609, 65536, 3, 196610, 65536, 3, 196608, 65536, 3, 327682, 65536, 5, 327681, 65536, 5, 327680, 65536, 5, 327683, 65536, 5, 196628, 393216, 4, 262164, 393216, 4, 262163, 393216, 4, 196627, 393216, 4, 327700, 393216, 4, 327699, 393216, 4, 262162, 393216, 4, 196626, 393216, 4, 262161, 393216, 4, 196625, 393216, 4, 131089, 393216, 4, 262160, 393216, 4, 196624, 393216, 4, 131088, 393216, 4, 327698, 393216, 4, 327697, 393216, 4, 327696, 393216, 4, 327695, 393216, 4, 262159, 393216, 4, 196623, 393216, 4, 327694, 393216, 4, 262158, 393216, 4, 196622, 393216, 4, 393236, 393216, 4, 393235, 393216, 4, 458772, 393216, 4, 458771, 393216, 4, 458770, 393216, 4, 393234, 393216, 4, 458769, 393216, 4, 393233, 393216, 4, 458768, 393216, 4, 393232, 393216, 4, 458767, 393216, 4, 393231, 393216, 4, 393230, 393216, 4, 458766, 393216, 4, 393229, 393216, 4, 327693, 393216, 4, 262157, 393216, 4, 458765, 393216, 4, 196621, 393216, 4, 131085, 393216, 4, 131084, 393216, 4, 65548, 393216, 4, 131083, 393216, 4, 11, 393216, 3, 131082, 393216, 4, 131081, 393216, 4, 131080, 393216, 4, 131079, 393216, 4, 131078, 393216, 4, 131077, 393216, 4, 131076, 393216, 4, 131075, 393216, 4, 131074, 393216, 4, 131073, 393216, 4, 131072, 327680, 5, 131086, 393216, 4, 655363, 393216, 4, 655364, 393216, 4, 589827, 393216, 4, 589828, 393216, 4, 524291, 393216, 4, 524292, 393216, 4, 589829, 393216, 4, 655365, 393216, 4, 458755, 393216, 4, 458756, 393216, 4, 393218, 393216, 4, 393219, 393216, 4, 393220, 393216, 4, 458757, 393216, 4, 393221, 393216, 4, 524293, 393216, 4, 458758, 393216, 4, 524294, 393216, 4, 393222, 393216, 4, 458759, 393216, 4, 524295, 393216, 4, 393223, 393216, 4, 458760, 393216, 4, 524296, 393216, 4, 393224, 393216, 4, 458761, 393216, 4, 524297, 393216, 4, 393225, 393216, 4, 589833, 393216, 4, 589832, 393216, 4, 589831, 393216, 4, 589830, 393216, 4, 655367, 393216, 4, 655366, 393216, 4, 655368, 393216, 4, 655369, 393216, 4, 720904, 393216, 4, 720905, 393216, 4, 524309, 393216, 4, 524308, 393216, 4, 524301, 393216, 4, 524302, 393216, 4, 524303, 393216, 4, 524304, 393216, 4, 524305, 393216, 4, 524306, 393216, 4, 524307, 393216, 4, 196620, 131072, 3, 327679, 0, 4, 655384, 65536, 4) @@ -558,6 +48,7 @@ visible = false visible = false [node name="GameStats" parent="CanvasLayer" instance=ExtResource("6_hbxxi")] +metadata/_edit_use_anchors_ = true [node name="Placements" type="Node2D" parent="."] @@ -570,7 +61,15 @@ position = Vector2(676, 192) [node name="placement3" parent="Placements" instance=ExtResource("6_mao4r")] position = Vector2(844, 393) -[node name="base" parent="." instance=ExtResource("8_rsf1n")] +[node name="Bases" type="Node2D" parent="."] + +[node name="base" parent="Bases" instance=ExtResource("8_rsf1n")] position = Vector2(1179, 502) +[node name="base2" parent="Bases" instance=ExtResource("8_rsf1n")] +position = Vector2(1179, 543) + +[node name="base3" parent="Bases" instance=ExtResource("8_rsf1n")] +position = Vector2(1178, 460) + [connection signal="timeout" from="Path2D/Timer" to="Path2D" method="_on_timer_timeout"] diff --git a/scenes/stages/stage_2.tscn b/scenes/stages/stage_2.tscn new file mode 100644 index 0000000..a431f75 --- /dev/null +++ b/scenes/stages/stage_2.tscn @@ -0,0 +1,319 @@ +[gd_scene load_steps=13 format=3 uid="uid://bj5auw303w08w"] + +[ext_resource type="Script" path="res://scripts/stages/2/game_manager.gd" id="1_4r6ye"] +[ext_resource type="Texture2D" uid="uid://bq6hnxbt4w37u" path="res://assets/tileset/snowland/Snowland@64x64.png" id="1_d077v"] +[ext_resource type="PackedScene" uid="uid://bvoenhbaqiqj2" path="res://scenes/towers/placement/placement.tscn" id="2_4fmnc"] +[ext_resource type="PackedScene" uid="uid://bhnv1dsggssil" path="res://scenes/ui/pause_menu.tscn" id="2_qcxs4"] +[ext_resource type="Script" path="res://scripts/stages/2/summon.gd" id="3_5snh6"] +[ext_resource type="PackedScene" uid="uid://cd5r1v6f8hahx" path="res://scenes/ui/tower_menu.tscn" id="3_wmghq"] +[ext_resource type="PackedScene" uid="uid://cy88k4uxt1v37" path="res://scenes/ui/game_stats.tscn" id="4_puhii"] +[ext_resource type="PackedScene" uid="uid://cikgeqqhctm7k" path="res://scenes/base/base.tscn" id="6_e20hd"] + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_amj2r"] +texture = ExtResource("1_d077v") +texture_region_size = Vector2i(64, 64) +0:0/0 = 0 +1:0/0 = 0 +2:0/0 = 0 +3:0/0 = 0 +4:0/0 = 0 +5:0/0 = 0 +6:0/0 = 0 +7:0/0 = 0 +8:0/0 = 0 +9:0/0 = 0 +10:0/0 = 0 +11:0/0 = 0 +12:0/0 = 0 +13:0/0 = 0 +14:0/0 = 0 +15:0/0 = 0 +0:1/0 = 0 +1:1/0 = 0 +2:1/0 = 0 +3:1/0 = 0 +4:1/0 = 0 +5:1/0 = 0 +6:1/0 = 0 +7:1/0 = 0 +8:1/0 = 0 +9:1/0 = 0 +10:1/0 = 0 +11:1/0 = 0 +12:1/0 = 0 +13:1/0 = 0 +14:1/0 = 0 +15:1/0 = 0 +0:2/0 = 0 +1:2/0 = 0 +2:2/0 = 0 +3:2/0 = 0 +4:2/0 = 0 +5:2/0 = 0 +6:2/0 = 0 +7:2/0 = 0 +8:2/0 = 0 +9:2/0 = 0 +10:2/0 = 0 +11:2/0 = 0 +12:2/0 = 0 +13:2/0 = 0 +14:2/0 = 0 +15:2/0 = 0 +0:3/0 = 0 +1:3/0 = 0 +2:3/0 = 0 +3:3/0 = 0 +4:3/0 = 0 +5:3/0 = 0 +6:3/0 = 0 +7:3/0 = 0 +8:3/0 = 0 +9:3/0 = 0 +10:3/0 = 0 +11:3/0 = 0 +12:3/0 = 0 +13:3/0 = 0 +14:3/0 = 0 +15:3/0 = 0 +0:4/0 = 0 +1:4/0 = 0 +2:4/0 = 0 +3:4/0 = 0 +4:4/0 = 0 +5:4/0 = 0 +6:4/0 = 0 +7:4/0 = 0 +8:4/0 = 0 +9:4/0 = 0 +10:4/0 = 0 +11:4/0 = 0 +12:4/0 = 0 +13:4/0 = 0 +14:4/0 = 0 +15:4/0 = 0 +0:5/0 = 0 +1:5/0 = 0 +2:5/0 = 0 +3:5/0 = 0 +4:5/0 = 0 +5:5/0 = 0 +6:5/0 = 0 +7:5/0 = 0 +8:5/0 = 0 +9:5/0 = 0 +10:5/0 = 0 +11:5/0 = 0 +13:5/0 = 0 +14:5/0 = 0 +15:5/0 = 0 +0:6/0 = 0 +1:6/0 = 0 +2:6/0 = 0 +3:6/0 = 0 +4:6/0 = 0 +5:6/0 = 0 +6:6/0 = 0 +7:6/0 = 0 +8:6/0 = 0 +9:6/0 = 0 +10:6/0 = 0 +11:6/0 = 0 +13:6/0 = 0 +14:6/0 = 0 +15:6/0 = 0 +0:7/0 = 0 +1:7/0 = 0 +2:7/0 = 0 +3:7/0 = 0 +4:7/0 = 0 +5:7/0 = 0 +6:7/0 = 0 +7:7/0 = 0 +8:7/0 = 0 +9:7/0 = 0 +10:7/0 = 0 +11:7/0 = 0 +12:7/0 = 0 +13:7/0 = 0 +14:7/0 = 0 +15:7/0 = 0 +0:8/0 = 0 +1:8/0 = 0 +2:8/0 = 0 +3:8/0 = 0 +4:8/0 = 0 +5:8/0 = 0 +6:8/0 = 0 +9:8/0 = 0 +10:8/0 = 0 +12:8/0 = 0 +13:8/0 = 0 +14:8/0 = 0 +15:8/0 = 0 +0:9/0 = 0 +1:9/0 = 0 +2:9/0 = 0 +3:9/0 = 0 +4:9/0 = 0 +5:9/0 = 0 +6:9/0 = 0 +7:9/0 = 0 +8:9/0 = 0 +9:9/0 = 0 +10:9/0 = 0 +12:9/0 = 0 +13:9/0 = 0 +14:9/0 = 0 +15:9/0 = 0 +0:10/0 = 0 +1:10/0 = 0 +2:10/0 = 0 +3:10/0 = 0 +4:10/0 = 0 +5:10/0 = 0 +6:10/0 = 0 +7:10/0 = 0 +8:10/0 = 0 +9:10/0 = 0 +10:10/0 = 0 +11:10/0 = 0 +12:10/0 = 0 +13:10/0 = 0 +14:10/0 = 0 +15:10/0 = 0 +10:11/0 = 0 +11:11/0 = 0 +12:11/0 = 0 +13:11/0 = 0 +14:11/0 = 0 +15:11/0 = 0 +9:12/0 = 0 +10:12/0 = 0 +11:12/0 = 0 +12:12/0 = 0 +13:12/0 = 0 +14:12/0 = 0 +15:12/0 = 0 +12:13/0 = 0 +13:13/0 = 0 +14:13/0 = 0 +15:13/0 = 0 +8:14/0 = 0 +9:14/0 = 0 +10:14/0 = 0 +11:14/0 = 0 +12:14/0 = 0 +13:14/0 = 0 +14:14/0 = 0 +15:14/0 = 0 +8:15/0 = 0 +9:15/0 = 0 +10:15/0 = 0 +11:15/0 = 0 +12:15/0 = 0 +13:15/0 = 0 +14:15/0 = 0 +15:15/0 = 0 +11:8/0 = 0 +11:9/0 = 0 +8:8/0 = 0 +7:8/0 = 0 +9:11/0 = 0 +0:11/size_in_atlas = Vector2i(5, 5) +0:11/0 = 0 +5:11/size_in_atlas = Vector2i(3, 5) +5:11/0 = 0 +8:11/size_in_atlas = Vector2i(1, 3) +8:11/0 = 0 +9:13/size_in_atlas = Vector2i(3, 1) +9:13/0 = 0 +12:5/size_in_atlas = Vector2i(1, 2) +12:5/0 = 0 + +[sub_resource type="TileSet" id="TileSet_shiwu"] +tile_size = Vector2i(64, 64) +sources/0 = SubResource("TileSetAtlasSource_amj2r") + +[sub_resource type="Curve2D" id="Curve2D_jjgnp"] +_data = { +"points": PackedVector2Array(0, 0, 0, 0, 560, -42, 0, 0, 0, 0, 551, 156, 0, 0, 0, 0, 289, 163, 0, 0, 0, 0, 280, 481, 0, 0, 0, 0, 545, 482, 0, 0, 0, 0, 540, 683) +} +point_count = 6 + +[sub_resource type="Curve2D" id="Curve2D_pqknf"] +_data = { +"points": PackedVector2Array(0, 0, 0, 0, 593, -38, 0, 0, 0, 0, 591, 154, 0, 0, 0, 0, 851, 163, 0, 0, 0, 0, 850, 486, 0, 0, 0, 0, 588, 482, 0, 0, 0, 0, 584, 681) +} +point_count = 6 + +[node name="GameManager" type="Node2D"] +script = ExtResource("1_4r6ye") + +[node name="TileMap" type="TileMap" parent="."] +tile_set = SubResource("TileSet_shiwu") +format = 2 +layer_0/tile_data = PackedInt32Array(8, 524288, 1, 65544, 524288, 1, 589832, 524288, 1, 524296, 524288, 1, 458760, 524288, 1, 131080, 524288, 1, 131081, 524288, 1, 131082, 524288, 1, 131083, 524288, 1, 131084, 524288, 1, 131079, 524288, 1, 131078, 524288, 1, 131077, 524288, 1, 131076, 524288, 1, 196612, 524288, 1, 262148, 524288, 1, 327684, 524288, 1, 393220, 524288, 1, 458756, 524288, 1, 458757, 524288, 1, 458758, 524288, 1, 458759, 524288, 1, 458761, 524288, 1, 458762, 524288, 1, 458763, 524288, 1, 458764, 524288, 1, 393228, 393216, 3, 327692, 458752, 1, 262156, 458752, 1, 196620, 393216, 2, 7, 458752, 1, 65542, 524288, 0, 65543, 393216, 3, 196611, 458752, 1, 262147, 458752, 1, 327683, 458752, 1, 393219, 458752, 1, 458755, 458752, 1, 524291, 458752, 2, 524292, 524288, 2, 524293, 524288, 2, 524294, 524288, 2, 524295, 393216, 2, 589831, 458752, 1, 655368, 524288, 1, 655367, 458752, 1, 655369, 524288, 1, 589833, 524288, 1, 524297, 524288, 1, 524298, 327680, 2, 524299, 524288, 2, 524300, 524288, 2, 524301, 524288, 2, 458765, 524288, 1, 393229, 524288, 1, 327693, 524288, 1, 262157, 524288, 1, 196621, 524288, 1, 131085, 524288, 1, 65549, 524288, 0, 65548, 524288, 0, 65547, 524288, 0, 65541, 524288, 0, 65540, 524288, 0, 131075, 458752, 1, 65539, 458752, 0, -65528, 524288, 1, -65529, 458752, 1, 196613, 327680, 2, 262149, 589824, 1, 327685, 589824, 1, 262155, 65536, 1, 327691, 65536, 1, 196619, 524288, 2, 196618, 524288, 2, 196616, 524288, 2, 196617, 524288, 2, 196615, 524288, 2, 196614, 524288, 2, 393223, 524288, 0, 393225, 524288, 0, 393224, 524288, 0, 393222, 524288, 0, 393226, 524288, 0, 393227, 524288, 0, 393221, 327680, 3, 262150, 65536, 1, 327686, 65536, 1, 327687, 65536, 1, 262151, 65536, 1, 262152, 65536, 1, 327688, 65536, 1, 327689, 65536, 1, 262153, 65536, 1, 262154, 65536, 1, 327690, 65536, 1, 589841, 65536, 1, 524305, 65536, 1, 458769, 65536, 1, 393233, 65536, 1, 327697, 65536, 1, 262161, 65536, 1, 196625, 65536, 1, 131089, 65536, 1, 65553, 65536, 1, 17, 65536, 1, 11, 65536, 1, 12, 65536, 1, 13, 65536, 1, 14, 65536, 1, 15, 65536, 1, 16, 65536, 1, 65552, 65536, 1, 131088, 65536, 1, 196624, 65536, 1, 262160, 65536, 1, 327696, 65536, 1, 393232, 65536, 1, 458768, 65536, 1, 524304, 65536, 1, 589840, 65536, 1, 589839, 65536, 1, 589838, 65536, 1, 524302, 589824, 2, 458766, 589824, 1, 393230, 589824, 1, 327694, 589824, 1, 262158, 589824, 1, 196622, 589824, 1, 131086, 589824, 1, 65550, 589824, 0, 65551, 65536, 1, 131087, 65536, 1, 196623, 65536, 1, 262159, 65536, 1, 327695, 65536, 1, 393231, 65536, 1, 458767, 65536, 1, 524303, 65536, 1, 589834, 589824, 1, 589835, 65536, 1, 589836, 65536, 1, 589837, 65536, 1, 589830, 65536, 1, 589829, 65536, 1, 589828, 65536, 1, 589827, 65536, 1, 589826, 65536, 1, 589825, 65536, 1, 589824, 65536, 1, 524288, 65536, 1, 458752, 65536, 1, 393216, 65536, 1, 327680, 65536, 1, 262144, 65536, 1, 196608, 65536, 1, 131072, 65536, 1, 65536, 65536, 1, 0, 65536, 1, 1, 65536, 1, 2, 65536, 1, 3, 65536, 1, 4, 65536, 1, 5, 65536, 1, 6, 65536, 1, 65537, 65536, 1, 131073, 65536, 1, 196609, 65536, 1, 262145, 65536, 1, 327681, 65536, 1, 393217, 65536, 1, 458753, 65536, 1, 524289, 65536, 1, 524290, 65536, 1, 458754, 65536, 1, 393218, 65536, 1, 327682, 65536, 1, 262146, 65536, 1, 196610, 65536, 1, 131074, 65536, 1, 65538, 65536, 1, 65546, 327680, 3, 65545, 524288, 1, 9, 524288, 1, -65527, 524288, 1, 10, 589824, 1, -65526, 589824, 1, 655370, 589824, 1, 655371, 65536, 1, 655373, 65536, 1, 655374, 65536, 1, 655375, 65536, 1, 655376, 65536, 1, 655377, 65536, 1, 655372, 65536, 1, 655360, 65536, 1, 655361, 65536, 1, 655362, 65536, 1, 655363, 65536, 1, 655364, 65536, 1, 655365, 65536, 1, 655366, 65536, 1) +layer_1/name = "" +layer_1/enabled = true +layer_1/modulate = Color(1, 1, 1, 1) +layer_1/y_sort_enabled = false +layer_1/y_sort_origin = 0 +layer_1/z_index = 0 +layer_1/tile_data = PackedInt32Array(458768, 0, 11, 65537, 327680, 11, 458753, 524288, 11, 262152, 786432, 5, 262153, 655360, 11, 131088, 589824, 11, 262145, 589824, 12, 196608, 589824, 12) + +[node name="Path2D" type="Path2D" parent="."] +curve = SubResource("Curve2D_jjgnp") +script = ExtResource("3_5snh6") + +[node name="Timer" type="Timer" parent="Path2D"] + +[node name="Path2D2" type="Path2D" parent="."] +curve = SubResource("Curve2D_pqknf") +script = ExtResource("3_5snh6") +type = 1 + +[node name="Timer" type="Timer" parent="Path2D2"] +autostart = true + +[node name="CanvasLayer" type="CanvasLayer" parent="."] + +[node name="PauseMenu" parent="CanvasLayer" instance=ExtResource("2_qcxs4")] +visible = false + +[node name="TowerMenu" parent="CanvasLayer" instance=ExtResource("3_wmghq")] +visible = false + +[node name="GameStats" parent="CanvasLayer" instance=ExtResource("4_puhii")] +metadata/_edit_use_anchors_ = true + +[node name="Placements" type="Node2D" parent="."] + +[node name="placement" parent="Placements" instance=ExtResource("2_4fmnc")] +position = Vector2(438, 320) + +[node name="placement2" parent="Placements" instance=ExtResource("2_4fmnc")] +position = Vector2(711, 321) + +[node name="placement3" parent="Placements" instance=ExtResource("2_4fmnc")] +position = Vector2(743, 605) + +[node name="placement4" parent="Placements" instance=ExtResource("2_4fmnc")] +position = Vector2(401, 604) + +[node name="Bases" type="Node2D" parent="."] + +[node name="base" parent="Bases" instance=ExtResource("6_e20hd")] +position = Vector2(596, 678) + +[node name="base2" parent="Bases" instance=ExtResource("6_e20hd")] +position = Vector2(638, 677) + +[node name="base3" parent="Bases" instance=ExtResource("6_e20hd")] +position = Vector2(552, 679) + +[node name="base4" parent="Bases" instance=ExtResource("6_e20hd")] +position = Vector2(509, 680) + +[connection signal="timeout" from="Path2D/Timer" to="Path2D" method="_on_timer_timeout"] +[connection signal="timeout" from="Path2D2/Timer" to="Path2D2" method="_on_timer_timeout"] diff --git a/scripts/enemies/enemy.gd b/scripts/enemies/enemy.gd index a492559..5d462e9 100644 --- a/scripts/enemies/enemy.gd +++ b/scripts/enemies/enemy.gd @@ -19,8 +19,8 @@ func set_enemy(id: int): speed = config.enemy[enemy_id]['speed'] reward = config.enemy[enemy_id]['reward'] -func set_direction(): - var path_direction = config.game['path_direction'] +func set_direction(type: int): + var path_direction = config.game['path_direction'][type] for x in path_direction: direction_progress.append(x['progress']) direction.append(x['direction']) diff --git a/scripts/stages/1/config.gd b/scripts/stages/1/config.gd index ef3df80..dd7d95f 100644 --- a/scripts/stages/1/config.gd +++ b/scripts/stages/1/config.gd @@ -8,18 +8,20 @@ var game = { "spawn_timer": 3.0, "offset": [-30.0, 30.0], "path_direction": [ - { - "progress": 0, - "direction": "right", - }, - { - "progress": 570, - "direction": "front" - }, - { - "progress": 855, - "direction": "right" - } + [ + { + "progress": 0, + "direction": "right", + }, + { + "progress": 570, + "direction": "front" + }, + { + "progress": 855, + "direction": "right" + } + ] ] } diff --git a/scripts/stages/1/game_manager.gd b/scripts/stages/1/game_manager.gd index ad2d340..b0cdef6 100644 --- a/scripts/stages/1/game_manager.gd +++ b/scripts/stages/1/game_manager.gd @@ -16,7 +16,9 @@ func _ready(): $CanvasLayer/GameStats.connect("on_paused", on_game_paused) $CanvasLayer/PauseMenu.connect("on_resume", on_game_resume) $CanvasLayer/GameStats.set_resource(data['resource']) - $base.connect("enemy_entered_base", on_enemy_entered_base) + var bases = $Bases.get_children() + for base in bases: + base.connect("enemy_entered_base", on_enemy_entered_base) var placements = $Placements.get_children() for placement in placements: placement.connect("on_placement", on_tower_placement) diff --git a/scripts/stages/1/summon.gd b/scripts/stages/1/summon.gd index a00e45c..f801f86 100644 --- a/scripts/stages/1/summon.gd +++ b/scripts/stages/1/summon.gd @@ -1,6 +1,7 @@ extends Path2D @onready var timer = $Timer +@export var type: int = 0 var config_path = "res://scripts/stages/1/config.gd" var config = load(config_path).new() @@ -25,5 +26,5 @@ func summon(): add_child(enemy_instance) enemy_instance.set_config(config_path) enemy_instance.set_enemy(0) - enemy_instance.set_direction() + enemy_instance.set_direction(type) enemy_instance.set_v_offset(rng.randf_range(config.game['offset'][0], config.game['offset'][1])) diff --git a/scripts/stages/2/config.gd b/scripts/stages/2/config.gd new file mode 100644 index 0000000..cd1bb4a --- /dev/null +++ b/scripts/stages/2/config.gd @@ -0,0 +1,202 @@ +extends Node + + +var game = { + "health": 6, + "resource": 100, + "spawn_timer": 3.0, + "offset": [-40.0, 35.0], + "path_direction": [ + [ + { + "progress": 0, + "direction": "front", + }, + { + "progress": 200, + "direction": "left" + }, + { + "progress": 460, + "direction": "front" + }, + { + "progress": 780, + "direction": "right" + }, + { + "progress": 1043, + "direction": "front" + } + ], + [ + { + "progress": 0, + "direction": "front", + }, + { + "progress": 190, + "direction": "right" + }, + { + "progress": 450, + "direction": "front" + }, + { + "progress": 770, + "direction": "left" + }, + { + "progress": 1033, + "direction": "front" + } + ] + ] +} + +var menu = [ + { + "name": "Cannon", + "image": load("res://assets/icons/towers/cannon-1.png"), + "image_disabled": load("res://assets/icons/towers/cannon-1-disabled.png"), + "price": 10 + }, + { + "name": "Railgun", + "image": load("res://assets/icons/towers/railgun-1.png"), + "image_disabled": load("res://assets/icons/towers/railgun-1-disabled.png"), + "price": 20 + }, + { + "name": "Cannon (V2)", + "image": load("res://assets/icons/towers/cannon-2.png"), + "image_disabled": load("res://assets/icons/towers/cannon-2-disabled.png"), + "price": 50 + }, + { + "name": "Railgun (V2)", + "image": load("res://assets/icons/towers/railgun-2.png"), + "image_disabled": load("res://assets/icons/towers/railgun-2-disabled.png"), + "price": 60 + }, + { + "name": "Cannon (V3)", + "image": load("res://assets/icons/towers/cannon-3.png"), + "image_disabled": load("res://assets/icons/towers/cannon-3-disabled.png"), + "price": 90 + }, + { + "name": "Railgun (V3)", + "image": load("res://assets/icons/towers/railgun-3.png"), + "image_disabled": load("res://assets/icons/towers/railgun-3-disabled.png"), + "price": 100 + } +] + +var tower = [ + { + "name": "Cannon", + "asset": preload("res://scenes/towers/cannon_1.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 30, + "health": 100, + "durability_reduction": 10 + }, + { + "name": "Railgun", + "asset": preload("res://scenes/towers/railgun_1.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 40, + "health": 100, + "durability_reduction": 10 + }, + { + "name": "Cannon (V2)", + "asset": preload("res://scenes/towers/cannon_2.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 40, + "health": 100, + "durability_reduction": 10 + }, + { + "name": "Railgun (V2)", + "asset": preload("res://scenes/towers/railgun_2.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 40, + "health": 100, + "durability_reduction": 10 + }, + { + "name": "Cannon (V3)", + "asset": preload("res://scenes/towers/cannon_3.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 40, + "health": 100, + "durability_reduction": 10 + }, + { + "name": "Railgun (V3)", + "asset": preload("res://scenes/towers/railgun_3.tscn"), + "bullet": preload("res://scenes/bullets/bullet_1.tscn"), + "timer": 1, + "speed": 200, + "damage": 40, + "health": 100, + "durability_reduction": 10 + } +] + +var enemy = [ + { + "name": "Demon", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 10 + }, + { + "name": "Orc", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 20 + }, + { + "name": "Cyclops", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 30 + }, + { + "name": "Demon Boar", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 40 + }, + { + "name": "Demon Fungus", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 50 + }, + { + "name": "Demon Shark", + "health": 100, + "speed": 30, + "damage": 1, + "reward": 60 + } +] diff --git a/scripts/stages/2/game_manager.gd b/scripts/stages/2/game_manager.gd new file mode 100644 index 0000000..e9b5691 --- /dev/null +++ b/scripts/stages/2/game_manager.gd @@ -0,0 +1,93 @@ +extends Node2D + +var config_path = "res://scripts/stages/2/config.gd" +var config = load(config_path).new() + +var data = { + "paused": false, + "tower": {}, + "health": config.game['health'], + "resource": config.game['resource'] +} + +func _ready(): + $CanvasLayer/GameStats.connect("on_paused", on_game_paused) + $CanvasLayer/PauseMenu.connect("on_resume", on_game_resume) + $CanvasLayer/GameStats.set_resource(data['resource']) + var bases = $Bases.get_children() + for base in bases: + base.connect("enemy_entered_base", on_enemy_entered_base) + var placements = $Placements.get_children() + for placement in placements: + placement.connect("on_placement", on_tower_placement) + $CanvasLayer/TowerMenu.connect("build_tower", on_build_tower) + +func on_game_paused(): + data['paused'] = !data['paused'] + get_tree().paused = data['paused'] + $CanvasLayer/PauseMenu.show_menu() + +func on_game_resume(): + data['paused'] = !data['paused'] + get_tree().paused = data['paused'] + $CanvasLayer/PauseMenu.hide_menu() + +func on_tower_placement(pos, tower_placement_id): + var tower_id = null + var disabled = false + var disabled_2 = false + if data['tower'].has(str(tower_placement_id)): + match data['tower'][str(tower_placement_id)]['id']: + 0: + tower_id = 2 + 1: + tower_id = 3 + 2: + tower_id = 4 + 3: + tower_id = 5 + _: + tower_id = null + + if data['resource'] < config.menu[tower_id]['price']: + disabled = true + else: + if data['resource'] < config.menu[0]['price']: + disabled = true + if data['resource'] < config.menu[1]['price']: + disabled_2 = true + $CanvasLayer/TowerMenu.show_menu(tower_id, pos, tower_placement_id, disabled, disabled_2) + +func on_build_tower(pos, tower_id, tower_placement_id): + if data['tower'].has(str(tower_placement_id)): + var current_tower = get_tree().current_scene.get_node(str(data['tower'][str(tower_placement_id)]['name'])) + current_tower.queue_free() + else: + data['tower'][str(tower_placement_id)] = {} + + var tower = config.tower[tower_id]['asset'].instantiate() + get_tree().current_scene.add_child(tower) + tower.set_config(config_path) + tower.set_tower(tower_id, tower_placement_id) + tower.set_timer() + tower.global_position = pos + tower.connect("on_destroy", on_tower_destroy) + + data['tower'][str(tower_placement_id)]['id'] = tower_id + data['tower'][str(tower_placement_id)]['name'] = tower.name + data['resource'] -= config.menu[tower_id]['price'] + $CanvasLayer/GameStats.set_resource(data['resource']) + +func on_tower_destroy(tower_placement_id): + data['tower'].erase(str(tower_placement_id)) + +func on_enemy_entered_base(enemy): + data['health'] -= enemy.damage + $CanvasLayer/GameStats.set_damage(enemy.damage) + + if data['health'] < 1: + print("Game Over") + +func on_enemy_reward(value: int): + data['resource'] += value + $CanvasLayer/GameStats.set_resource(data['resource']) diff --git a/scripts/stages/2/summon.gd b/scripts/stages/2/summon.gd new file mode 100644 index 0000000..9300808 --- /dev/null +++ b/scripts/stages/2/summon.gd @@ -0,0 +1,30 @@ +extends Path2D + +@onready var timer = $Timer +@export var type: int = 0 + +var config_path = "res://scripts/stages/2/config.gd" +var config = load(config_path).new() + +var spawn_first: bool = true + +var enemy: PackedScene = preload("res://scenes/enemies/demon.tscn") + +func _ready(): + summon() + timer.wait_time = config.game['spawn_timer'] + timer.start() + +func _on_timer_timeout(): + summon() + timer.start() + +func summon(): + var rng = RandomNumberGenerator.new() + + var enemy_instance = enemy.instantiate() + add_child(enemy_instance) + enemy_instance.set_config(config_path) + enemy_instance.set_enemy(0) + enemy_instance.set_direction(type) + enemy_instance.set_v_offset(rng.randf_range(config.game['offset'][0], config.game['offset'][1]))