diff --git a/Assets/Graphics/Environment/Terrain/coin.png b/Assets/Graphics/Environment/Terrain/coin.png new file mode 100644 index 0000000..01ae33d Binary files /dev/null and b/Assets/Graphics/Environment/Terrain/coin.png differ diff --git a/Assets/Graphics/Environment/Terrain/coin.png.import b/Assets/Graphics/Environment/Terrain/coin.png.import new file mode 100644 index 0000000..0709469 --- /dev/null +++ b/Assets/Graphics/Environment/Terrain/coin.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://x6abskwkyh71" +path="res://.godot/imported/coin.png-e426a2965d4269bc7b7e16ff32a4af9f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/Terrain/coin.png" +dest_files=["res://.godot/imported/coin.png-e426a2965d4269bc7b7e16ff32a4af9f.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/Assets/Graphics/Environment/Terrain/mushroom_32x64.png b/Assets/Graphics/Environment/Terrain/mushroom_32x64.png new file mode 100644 index 0000000..9dca2d0 Binary files /dev/null and b/Assets/Graphics/Environment/Terrain/mushroom_32x64.png differ diff --git a/Assets/Graphics/Environment/Terrain/mushroom_32x64.png.import b/Assets/Graphics/Environment/Terrain/mushroom_32x64.png.import new file mode 100644 index 0000000..9482a07 --- /dev/null +++ b/Assets/Graphics/Environment/Terrain/mushroom_32x64.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bwkmj6d04qt2t" +path="res://.godot/imported/mushroom_32x64.png-3b8e5e0c463b56bb27fb0912a5025f04.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/Terrain/mushroom_32x64.png" +dest_files=["res://.godot/imported/mushroom_32x64.png-3b8e5e0c463b56bb27fb0912a5025f04.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/Assets/Graphics/Environment/Terrain/veg_32x32.png b/Assets/Graphics/Environment/Terrain/veg_32x32.png new file mode 100644 index 0000000..4e09fa9 Binary files /dev/null and b/Assets/Graphics/Environment/Terrain/veg_32x32.png differ diff --git a/Assets/Graphics/Environment/Terrain/veg_32x32.png.import b/Assets/Graphics/Environment/Terrain/veg_32x32.png.import new file mode 100644 index 0000000..5626044 --- /dev/null +++ b/Assets/Graphics/Environment/Terrain/veg_32x32.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dk2y2xyrujfhp" +path="res://.godot/imported/veg_32x32.png-5172de603fd7829d42a523415f607df5.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/Terrain/veg_32x32.png" +dest_files=["res://.godot/imported/veg_32x32.png-5172de603fd7829d42a523415f607df5.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/Assets/Graphics/Environment/backgrounds/forestbackground.png b/Assets/Graphics/Environment/backgrounds/forestbackground.png new file mode 100644 index 0000000..975c185 Binary files /dev/null and b/Assets/Graphics/Environment/backgrounds/forestbackground.png differ diff --git a/Assets/Graphics/Environment/backgrounds/forestbackground.png.import b/Assets/Graphics/Environment/backgrounds/forestbackground.png.import new file mode 100644 index 0000000..e6945c1 --- /dev/null +++ b/Assets/Graphics/Environment/backgrounds/forestbackground.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ci24qqcr5e33x" +path="res://.godot/imported/forestbackground.png-3a9b70e7e16666431ef4655d4efcf461.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/backgrounds/forestbackground.png" +dest_files=["res://.godot/imported/forestbackground.png-3a9b70e7e16666431ef4655d4efcf461.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/Assets/Graphics/Environment/objects/coin.png b/Assets/Graphics/Environment/objects/coin.png new file mode 100644 index 0000000..01ae33d Binary files /dev/null and b/Assets/Graphics/Environment/objects/coin.png differ diff --git a/Assets/Graphics/Environment/objects/coin.png.import b/Assets/Graphics/Environment/objects/coin.png.import new file mode 100644 index 0000000..0ea9995 --- /dev/null +++ b/Assets/Graphics/Environment/objects/coin.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b835uigojqjah" +path="res://.godot/imported/coin.png-e86948cac6bc4bb3d5449883ddf94b9f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/objects/coin.png" +dest_files=["res://.godot/imported/coin.png-e86948cac6bc4bb3d5449883ddf94b9f.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/Assets/Graphics/Environment/objects/crate.png b/Assets/Graphics/Environment/objects/crate.png new file mode 100644 index 0000000..2b8bdcd Binary files /dev/null and b/Assets/Graphics/Environment/objects/crate.png differ diff --git a/Assets/Graphics/Environment/objects/crate.png.import b/Assets/Graphics/Environment/objects/crate.png.import new file mode 100644 index 0000000..dc2dc7d --- /dev/null +++ b/Assets/Graphics/Environment/objects/crate.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b0mowaont3r1s" +path="res://.godot/imported/crate.png-d6f7abb9ade25e8c9c66417ac144497d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/objects/crate.png" +dest_files=["res://.godot/imported/crate.png-d6f7abb9ade25e8c9c66417ac144497d.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/Assets/Graphics/Environment/objects/pixel_bullet.png b/Assets/Graphics/Environment/objects/pixel_bullet.png new file mode 100644 index 0000000..900d030 Binary files /dev/null and b/Assets/Graphics/Environment/objects/pixel_bullet.png differ diff --git a/Assets/Graphics/Environment/objects/pixel_bullet.png.import b/Assets/Graphics/Environment/objects/pixel_bullet.png.import new file mode 100644 index 0000000..fb911cf --- /dev/null +++ b/Assets/Graphics/Environment/objects/pixel_bullet.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bhbxm8xtwu53h" +path="res://.godot/imported/pixel_bullet.png-86f483e186371db84048120634c2ce40.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Assets/Graphics/Environment/objects/pixel_bullet.png" +dest_files=["res://.godot/imported/pixel_bullet.png-86f483e186371db84048120634c2ce40.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/Scenes/Crate.tscn b/Scenes/Crate.tscn index 07a27f9..101fa42 100644 --- a/Scenes/Crate.tscn +++ b/Scenes/Crate.tscn @@ -1,8 +1,10 @@ -[gd_scene load_steps=3 format=3 uid="uid://lwju71dirkcy"] +[gd_scene load_steps=4 format=3 uid="uid://lwju71dirkcy"] [ext_resource type="Script" uid="uid://diuug3xgjo1se" path="res://scripts/crate.gd" id="1_qgfyo"] +[ext_resource type="Texture2D" uid="uid://b0mowaont3r1s" path="res://Assets/Graphics/Environment/objects/crate.png" id="2_7msr7"] [sub_resource type="RectangleShape2D" id="RectangleShape2D_r8wv2"] +size = Vector2(18.0392, 20.8045) [node name="Crate" type="RigidBody2D" groups=["pushable"]] rotation = 0.90108 @@ -10,5 +12,13 @@ script = ExtResource("1_qgfyo") metadata/_edit_group_ = true [node name="CollisionShape2D" type="CollisionShape2D" parent="."] +texture_filter = 1 +position = Vector2(-0.21268, -1.8462) +scale = Vector2(1.26954, 1.12898) shape = SubResource("RectangleShape2D_r8wv2") debug_color = Color(0.875314, 0.341029, 0.122297, 0.42) + +[node name="Sprite2D" type="Sprite2D" parent="."] +texture_filter = 1 +scale = Vector2(0.09, 0.09) +texture = ExtResource("2_7msr7") diff --git a/Scenes/bullet.tscn b/Scenes/bullet.tscn index 86343bd..0671627 100644 --- a/Scenes/bullet.tscn +++ b/Scenes/bullet.tscn @@ -1,10 +1,16 @@ -[gd_scene load_steps=3 format=3 uid="uid://vycud8mssmb3"] +[gd_scene load_steps=4 format=3 uid="uid://vycud8mssmb3"] [ext_resource type="Script" uid="uid://doxxkkrf00ef2" path="res://scripts/bullet.gd" id="1_xjght"] +[ext_resource type="Texture2D" uid="uid://bhbxm8xtwu53h" path="res://Assets/Graphics/Environment/objects/pixel_bullet.png" id="2_oduel"] [sub_resource type="CapsuleShape2D" id="CapsuleShape2D_4mw4s"] +radius = 4.9812 +height = 21.9964 [node name="bullet" type="Area2D"] +show_behind_parent = true +z_index = 1 +position = Vector2(1, -1) script = ExtResource("1_xjght") metadata/_edit_group_ = true @@ -12,4 +18,10 @@ metadata/_edit_group_ = true rotation = 1.58879 shape = SubResource("CapsuleShape2D_4mw4s") +[node name="bullet_graphic" type="Sprite2D" parent="."] +position = Vector2(-6, -5) +rotation = 3.14159 +scale = Vector2(0.2, 0.2) +texture = ExtResource("2_oduel") + [connection signal="body_entered" from="." to="." method="_on_body_entered"] diff --git a/Scenes/coin.tscn b/Scenes/coin.tscn new file mode 100644 index 0000000..06734bd --- /dev/null +++ b/Scenes/coin.tscn @@ -0,0 +1,115 @@ +[gd_scene load_steps=17 format=3 uid="uid://1lqblxtwgxwx"] + +[ext_resource type="Texture2D" uid="uid://b835uigojqjah" path="res://Assets/Graphics/Environment/objects/coin.png" id="1_2qo34"] +[ext_resource type="Script" uid="uid://bxb3b804re3sr" path="res://scripts/coin.gd" id="1_jgi06"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_jgi06"] +atlas = ExtResource("1_2qo34") +region = Rect2(0, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_g537i"] +atlas = ExtResource("1_2qo34") +region = Rect2(16, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_h2p6v"] +atlas = ExtResource("1_2qo34") +region = Rect2(32, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ffmqm"] +atlas = ExtResource("1_2qo34") +region = Rect2(48, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_81h6x"] +atlas = ExtResource("1_2qo34") +region = Rect2(64, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_qbp07"] +atlas = ExtResource("1_2qo34") +region = Rect2(80, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_2l7mo"] +atlas = ExtResource("1_2qo34") +region = Rect2(96, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_q30xt"] +atlas = ExtResource("1_2qo34") +region = Rect2(112, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_7w2r2"] +atlas = ExtResource("1_2qo34") +region = Rect2(128, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_tthw5"] +atlas = ExtResource("1_2qo34") +region = Rect2(144, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6pu15"] +atlas = ExtResource("1_2qo34") +region = Rect2(160, 0, 16, 16) + +[sub_resource type="AtlasTexture" id="AtlasTexture_vgc30"] +atlas = ExtResource("1_2qo34") +region = Rect2(176, 0, 16, 16) + +[sub_resource type="SpriteFrames" id="SpriteFrames_qtgto"] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_jgi06") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_g537i") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_h2p6v") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ffmqm") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_81h6x") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_qbp07") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_2l7mo") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_q30xt") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_7w2r2") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_tthw5") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6pu15") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_vgc30") +}], +"loop": true, +"name": &"idle", +"speed": 12.0 +}] + +[sub_resource type="CircleShape2D" id="CircleShape2D_m55n1"] +radius = 5.0 + +[node name="coin" type="Area2D"] +texture_filter = 1 +script = ExtResource("1_jgi06") + +[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] +sprite_frames = SubResource("SpriteFrames_qtgto") +animation = &"idle" +autoplay = "idle" +frame_progress = 0.668838 + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource("CircleShape2D_m55n1") +debug_color = Color(0.656987, 0.515779, 0.0416574, 0.42) + +[connection signal="body_entered" from="." to="." method="_on_body_entered"] diff --git a/Scenes/player.tscn b/Scenes/player.tscn index 867e501..33082e6 100644 --- a/Scenes/player.tscn +++ b/Scenes/player.tscn @@ -211,4 +211,7 @@ autoplay = "IDLE" frame = 1 frame_progress = 1.0 +[node name="Camera2D" type="Camera2D" parent="PlayerGraphic"] +offset = Vector2(0, -30) + [connection signal="animation_finished" from="PlayerGraphic" to="." method="_on_animation_finished"] diff --git a/Scenes/reallygoodgame.tscn b/Scenes/reallygoodgame.tscn index 493d74e..86d613a 100644 --- a/Scenes/reallygoodgame.tscn +++ b/Scenes/reallygoodgame.tscn @@ -1,67 +1,424 @@ -[gd_scene load_steps=11 format=4 uid="uid://ibkufgrwjwro"] +[gd_scene load_steps=17 format=4 uid="uid://ibkufgrwjwro"] [ext_resource type="Script" uid="uid://buhkldpol3slp" path="res://scripts/gamecontroller.gd" id="1_3d84a"] [ext_resource type="PackedScene" uid="uid://4a4u47173cyb" path="res://Scenes/trigger.tscn" id="2_lptsb"] [ext_resource type="Script" uid="uid://bo0opwq3l73ec" path="res://scripts/scene_manager.gd" id="2_t43dh"] [ext_resource type="Texture2D" uid="uid://binxtl7gl8psd" path="res://Assets/Graphics/Environment/Terrain/Terrain (32x32).png" id="3_f0he5"] [ext_resource type="PackedScene" uid="uid://lwju71dirkcy" path="res://Scenes/Crate.tscn" id="3_u2cf2"] +[ext_resource type="Texture2D" uid="uid://ci24qqcr5e33x" path="res://Assets/Graphics/Environment/backgrounds/forestbackground.png" id="3_vmqmt"] [ext_resource type="PackedScene" uid="uid://c5uf1o0s4syv7" path="res://Scenes/player.tscn" id="4_f0he5"] +[ext_resource type="Texture2D" uid="uid://dk2y2xyrujfhp" path="res://Assets/Graphics/Environment/Terrain/veg_32x32.png" id="4_g7vkj"] [ext_resource type="PackedScene" uid="uid://bex5lhiuhhnq6" path="res://Scenes/static_body_2d.tscn" id="4_xqt3w"] +[ext_resource type="Texture2D" uid="uid://bwkmj6d04qt2t" path="res://Assets/Graphics/Environment/Terrain/mushroom_32x64.png" id="5_vmqmt"] +[ext_resource type="PackedScene" uid="uid://1lqblxtwgxwx" path="res://Scenes/coin.tscn" id="11_g25fg"] [sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_xqt3w"] texture = ExtResource("3_f0he5") texture_region_size = Vector2i(32, 32) 0:0/0 = 0 +0:0/0/terrain_set = 0 +0:0/0/terrain = 0 +0:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 0.700989, -2.36583, 0.175247, -2.36583, 16, -16, 16) +0:0/0/terrains_peering_bit/right_side = 0 +0:0/0/terrains_peering_bit/bottom_right_corner = 0 +0:0/0/terrains_peering_bit/bottom_side = 0 1:0/0 = 0 +1:0/0/terrain_set = 0 +1:0/0/terrain = 0 +1:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, -2.27821, -16, -2.9792) +1:0/0/terrains_peering_bit/right_side = 0 +1:0/0/terrains_peering_bit/bottom_right_corner = 0 +1:0/0/terrains_peering_bit/bottom_side = 0 +1:0/0/terrains_peering_bit/bottom_left_corner = 0 +1:0/0/terrains_peering_bit/left_side = 0 2:0/0 = 0 +2:0/0/terrain_set = 0 +2:0/0/terrain = 0 +2:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, 4.1183, 16, 4.64404, -0.175247, -16, -0.525742) +2:0/0/terrains_peering_bit/bottom_side = 0 +2:0/0/terrains_peering_bit/bottom_left_corner = 0 +2:0/0/terrains_peering_bit/left_side = 0 4:0/0 = 0 +4:0/0/terrain_set = 0 +4:0/0/terrain = 0 +4:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +4:0/0/terrains_peering_bit/bottom_side = 0 6:0/0 = 0 +6:0/0/terrain_set = 0 +6:0/0/terrain = 0 +6:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +6:0/0/terrains_peering_bit/right_side = 0 +6:0/0/terrains_peering_bit/bottom_side = 0 +6:0/0/terrains_peering_bit/bottom_left_corner = 0 +6:0/0/terrains_peering_bit/left_side = 0 +6:0/0/terrains_peering_bit/top_left_corner = 0 +6:0/0/terrains_peering_bit/top_side = 0 +6:0/0/terrains_peering_bit/top_right_corner = 0 7:0/0 = 0 +7:0/0/terrain_set = 0 +7:0/0/terrain = 0 +7:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +7:0/0/terrains_peering_bit/right_side = 0 +7:0/0/terrains_peering_bit/bottom_right_corner = 0 +7:0/0/terrains_peering_bit/bottom_side = 0 +7:0/0/terrains_peering_bit/left_side = 0 +7:0/0/terrains_peering_bit/top_left_corner = 0 +7:0/0/terrains_peering_bit/top_side = 0 +7:0/0/terrains_peering_bit/top_right_corner = 0 9:0/0 = 0 +9:0/0/terrain_set = 0 +9:0/0/terrain = 0 +9:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +9:0/0/terrains_peering_bit/right_side = 0 +9:0/0/terrains_peering_bit/bottom_right_corner = 0 +9:0/0/terrains_peering_bit/bottom_side = 0 +9:0/0/terrains_peering_bit/bottom_left_corner = 0 +9:0/0/terrains_peering_bit/left_side = 0 +9:0/0/terrains_peering_bit/top_side = 0 10:0/0 = 0 +10:0/0/terrain_set = 0 +10:0/0/terrain = 0 +10:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +10:0/0/terrains_peering_bit/right_side = 0 +10:0/0/terrains_peering_bit/bottom_side = 0 +10:0/0/terrains_peering_bit/bottom_left_corner = 0 +10:0/0/terrains_peering_bit/left_side = 0 +10:0/0/terrains_peering_bit/top_left_corner = 0 +10:0/0/terrains_peering_bit/top_side = 0 12:0/0 = 0 +12:0/0/terrain_set = 0 +12:0/0/terrain = 0 +12:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +12:0/0/terrains_peering_bit/right_side = 0 +12:0/0/terrains_peering_bit/bottom_right_corner = 0 +12:0/0/terrains_peering_bit/bottom_side = 0 +12:0/0/terrains_peering_bit/top_side = 0 13:0/0 = 0 +13:0/0/terrain_set = 0 +13:0/0/terrain = 0 +13:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +13:0/0/terrains_peering_bit/right_side = 0 +13:0/0/terrains_peering_bit/bottom_side = 0 +13:0/0/terrains_peering_bit/bottom_left_corner = 0 +13:0/0/terrains_peering_bit/left_side = 0 +13:0/0/terrains_peering_bit/top_side = 0 15:0/0 = 0 +15:0/0/terrain_set = 0 +15:0/0/terrain = 0 +15:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +15:0/0/terrains_peering_bit/bottom_side = 0 +15:0/0/terrains_peering_bit/top_side = 0 0:1/0 = 0 +0:1/0/terrain_set = 0 +0:1/0/terrain = 0 +0:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, -3.59256, -16, -5.16978, 16, -16, 16) +0:1/0/terrains_peering_bit/right_side = 0 +0:1/0/terrains_peering_bit/bottom_right_corner = 0 +0:1/0/terrains_peering_bit/bottom_side = 0 +0:1/0/terrains_peering_bit/top_side = 0 +0:1/0/terrains_peering_bit/top_right_corner = 0 1:1/0 = 0 +1:1/0/terrain_set = 0 +1:1/0/terrain = 0 +1:1/0/terrains_peering_bit/right_side = 0 +1:1/0/terrains_peering_bit/bottom_right_corner = 0 +1:1/0/terrains_peering_bit/bottom_side = 0 +1:1/0/terrains_peering_bit/bottom_left_corner = 0 +1:1/0/terrains_peering_bit/left_side = 0 +1:1/0/terrains_peering_bit/top_left_corner = 0 +1:1/0/terrains_peering_bit/top_side = 0 +1:1/0/terrains_peering_bit/top_right_corner = 0 2:1/0 = 0 +2:1/0/terrain_set = 0 +2:1/0/terrain = 0 +2:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(4.29355, -16, 16, -16, 16, 16, 3.76781, 16) +2:1/0/terrains_peering_bit/bottom_side = 0 +2:1/0/terrains_peering_bit/bottom_left_corner = 0 +2:1/0/terrains_peering_bit/left_side = 0 +2:1/0/terrains_peering_bit/top_left_corner = 0 +2:1/0/terrains_peering_bit/top_side = 0 4:1/0 = 0 +4:1/0/terrain_set = 0 +4:1/0/terrain = 0 +4:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +4:1/0/terrains_peering_bit/bottom_side = 0 +4:1/0/terrains_peering_bit/top_side = 0 6:1/0 = 0 +6:1/0/terrain_set = 0 +6:1/0/terrain = 0 +6:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +6:1/0/terrains_peering_bit/right_side = 0 +6:1/0/terrains_peering_bit/bottom_right_corner = 0 +6:1/0/terrains_peering_bit/bottom_side = 0 +6:1/0/terrains_peering_bit/bottom_left_corner = 0 +6:1/0/terrains_peering_bit/left_side = 0 +6:1/0/terrains_peering_bit/top_left_corner = 0 +6:1/0/terrains_peering_bit/top_side = 0 7:1/0 = 0 +7:1/0/terrain_set = 0 +7:1/0/terrain = 0 +7:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +7:1/0/terrains_peering_bit/right_side = 0 +7:1/0/terrains_peering_bit/bottom_right_corner = 0 +7:1/0/terrains_peering_bit/bottom_side = 0 +7:1/0/terrains_peering_bit/bottom_left_corner = 0 +7:1/0/terrains_peering_bit/left_side = 0 +7:1/0/terrains_peering_bit/top_side = 0 +7:1/0/terrains_peering_bit/top_right_corner = 0 9:1/0 = 0 +9:1/0/terrain_set = 0 +9:1/0/terrain = 0 +9:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +9:1/0/terrains_peering_bit/right_side = 0 +9:1/0/terrains_peering_bit/bottom_right_corner = 0 +9:1/0/terrains_peering_bit/bottom_side = 0 +9:1/0/terrains_peering_bit/top_side = 0 +9:1/0/terrains_peering_bit/top_right_corner = 0 10:1/0 = 0 +10:1/0/terrain_set = 0 +10:1/0/terrain = 0 +10:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +10:1/0/terrains_peering_bit/right_side = 0 +10:1/0/terrains_peering_bit/bottom_side = 0 +10:1/0/terrains_peering_bit/left_side = 0 +10:1/0/terrains_peering_bit/top_left_corner = 0 +10:1/0/terrains_peering_bit/top_side = 0 +10:1/0/terrains_peering_bit/top_right_corner = 0 12:1/0 = 0 +12:1/0/terrain_set = 0 +12:1/0/terrain = 0 +12:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +12:1/0/terrains_peering_bit/right_side = 0 +12:1/0/terrains_peering_bit/bottom_side = 0 +12:1/0/terrains_peering_bit/top_side = 0 +12:1/0/terrains_peering_bit/top_right_corner = 0 13:1/0 = 0 +13:1/0/terrain_set = 0 +13:1/0/terrain = 0 +13:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +13:1/0/terrains_peering_bit/right_side = 0 +13:1/0/terrains_peering_bit/bottom_side = 0 +13:1/0/terrains_peering_bit/left_side = 0 +13:1/0/terrains_peering_bit/top_left_corner = 0 +13:1/0/terrains_peering_bit/top_side = 0 15:1/0 = 0 +15:1/0/terrain_set = 0 +15:1/0/terrain = 0 +15:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +15:1/0/terrains_peering_bit/right_side = 0 +15:1/0/terrains_peering_bit/bottom_right_corner = 0 +15:1/0/terrains_peering_bit/bottom_side = 0 +15:1/0/terrains_peering_bit/bottom_left_corner = 0 +15:1/0/terrains_peering_bit/left_side = 0 +15:1/0/terrains_peering_bit/top_side = 0 +15:1/0/terrains_peering_bit/top_right_corner = 0 16:1/0 = 0 +16:1/0/terrain_set = 0 +16:1/0/terrain = 0 +16:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +16:1/0/terrains_peering_bit/right_side = 0 +16:1/0/terrains_peering_bit/bottom_right_corner = 0 +16:1/0/terrains_peering_bit/bottom_side = 0 +16:1/0/terrains_peering_bit/bottom_left_corner = 0 +16:1/0/terrains_peering_bit/left_side = 0 +16:1/0/terrains_peering_bit/top_left_corner = 0 +16:1/0/terrains_peering_bit/top_side = 0 0:2/0 = 0 +0:2/0/terrain_set = 0 +0:2/0/terrain = 0 +0:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, -4.4688, -16, -3.41732, 5.43266, 16, 5.6079, 16, 16, -4.81929, 16, -12.0044, 11.7415, -16, 4.90691) +0:2/0/terrains_peering_bit/right_side = 0 +0:2/0/terrains_peering_bit/top_side = 0 +0:2/0/terrains_peering_bit/top_right_corner = 0 1:2/0 = 0 +1:2/0/terrain_set = 0 +1:2/0/terrain = 0 +1:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, 6.65938, 16, 6.30889, 16, 16, -16, 16) +1:2/0/terrains_peering_bit/right_side = 0 +1:2/0/terrains_peering_bit/left_side = 0 +1:2/0/terrains_peering_bit/top_left_corner = 0 +1:2/0/terrains_peering_bit/top_side = 0 +1:2/0/terrains_peering_bit/top_right_corner = 0 2:2/0 = 0 +2:2/0/terrain_set = 0 +2:2/0/terrain = 0 +2:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(2.54108, 4.55642, 3.06682, -16, 16, -16, 16, 16, -16, 16, -16, 4.20592) +2:2/0/terrains_peering_bit/left_side = 0 +2:2/0/terrains_peering_bit/top_left_corner = 0 +2:2/0/terrains_peering_bit/top_side = 0 4:2/0 = 0 +4:2/0/terrain_set = 0 +4:2/0/terrain = 0 +4:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +4:2/0/terrains_peering_bit/top_side = 0 6:3/0 = 0 +6:3/0/terrain_set = 0 +6:3/0/terrain = 0 +6:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +6:3/0/terrains_peering_bit/right_side = 0 +6:3/0/terrains_peering_bit/bottom_right_corner = 0 +6:3/0/terrains_peering_bit/bottom_side = 0 +6:3/0/terrains_peering_bit/top_side = 0 +6:3/0/terrains_peering_bit/top_right_corner = 0 7:3/0 = 0 +7:3/0/terrain_set = 0 +7:3/0/terrain = 0 +7:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +7:3/0/terrains_peering_bit/bottom_side = 0 +7:3/0/terrains_peering_bit/bottom_left_corner = 0 +7:3/0/terrains_peering_bit/left_side = 0 +7:3/0/terrains_peering_bit/top_left_corner = 0 +7:3/0/terrains_peering_bit/top_side = 0 9:3/0 = 0 +9:3/0/terrain_set = 0 +9:3/0/terrain = 0 +9:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, 5.16978, 16, 4.99454, 0.700989, -16, 0.525742) +9:3/0/terrains_peering_bit/right_side = 0 +9:3/0/terrains_peering_bit/bottom_side = 0 +9:3/0/terrains_peering_bit/bottom_left_corner = 0 +9:3/0/terrains_peering_bit/left_side = 0 10:3/0 = 0 +10:3/0/terrain_set = 0 +10:3/0/terrain = 0 +10:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, -0.700989, -4.64404, -0.876236, -4.1183, 16, -16, 16, -16, 0.525742) +10:3/0/terrains_peering_bit/right_side = 0 +10:3/0/terrains_peering_bit/bottom_right_corner = 0 +10:3/0/terrains_peering_bit/bottom_side = 0 +10:3/0/terrains_peering_bit/left_side = 0 12:3/0 = 0 +12:3/0/terrain_set = 0 +12:3/0/terrain = 0 +12:3/0/terrains_peering_bit/right_side = 0 +12:3/0/terrains_peering_bit/bottom_side = 0 +12:3/0/terrains_peering_bit/top_side = 0 13:3/0 = 0 +13:3/0/terrain_set = 0 +13:3/0/terrain = 0 +13:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +13:3/0/terrains_peering_bit/right_side = 0 +13:3/0/terrains_peering_bit/bottom_side = 0 +13:3/0/terrains_peering_bit/left_side = 0 15:3/0 = 0 +15:3/0/terrain_set = 0 +15:3/0/terrain = 0 +15:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +15:3/0/terrains_peering_bit/right_side = 0 +15:3/0/terrains_peering_bit/bottom_side = 0 16:3/0 = 0 +16:3/0/terrain_set = 0 +16:3/0/terrain = 0 +16:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +16:3/0/terrains_peering_bit/bottom_side = 0 +16:3/0/terrains_peering_bit/left_side = 0 0:4/0 = 0 +0:4/0/terrain_set = 0 +0:4/0/terrain = 0 +0:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +0:4/0/terrains_peering_bit/right_side = 0 1:4/0 = 0 +1:4/0/terrain_set = 0 +1:4/0/terrain = 0 +1:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +1:4/0/terrains_peering_bit/right_side = 0 +1:4/0/terrains_peering_bit/left_side = 0 2:4/0 = 0 +2:4/0/terrain_set = 0 +2:4/0/terrain = 0 +2:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) +2:4/0/terrains_peering_bit/left_side = 0 4:4/0 = 0 +4:4/0/terrain_set = 0 +4:4/0/terrain = 0 +4:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 14.1074, 9.46333, 9.02522, 14.195, -8.49948, 14.195, -13.5816, 8.06136) 6:4/0 = 0 +6:4/0/terrain_set = 0 +6:4/0/terrain = 0 +6:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +6:4/0/terrains_peering_bit/right_side = 0 +6:4/0/terrains_peering_bit/bottom_right_corner = 0 +6:4/0/terrains_peering_bit/bottom_side = 0 +6:4/0/terrains_peering_bit/top_side = 0 7:4/0 = 0 +7:4/0/terrain_set = 0 +7:4/0/terrain = 0 +7:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +7:4/0/terrains_peering_bit/bottom_side = 0 +7:4/0/terrains_peering_bit/bottom_left_corner = 0 +7:4/0/terrains_peering_bit/left_side = 0 +7:4/0/terrains_peering_bit/top_side = 0 9:4/0 = 0 +9:4/0/terrain_set = 0 +9:4/0/terrain = 0 +9:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, 2.10296, 5.87077, 2.6287, 5.16978, -14.3702, 16, -16, 16, 16, -16, 16) +9:4/0/terrains_peering_bit/right_side = 0 +9:4/0/terrains_peering_bit/left_side = 0 +9:4/0/terrains_peering_bit/top_left_corner = 0 +9:4/0/terrains_peering_bit/top_side = 0 10:4/0 = 0 +10:4/0/terrain_set = 0 +10:4/0/terrain = 0 +10:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, -6.39651, -16, -6.92225, 1.40197, 16, 1.40197, 16, 16, -16, 16, -16, -14.896) +10:4/0/terrains_peering_bit/right_side = 0 +10:4/0/terrains_peering_bit/left_side = 0 +10:4/0/terrains_peering_bit/top_side = 0 +10:4/0/terrains_peering_bit/top_right_corner = 0 12:4/0 = 0 +12:4/0/terrain_set = 0 +12:4/0/terrain = 0 +12:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, -3.59256, -16, -5.16978, 16, -16, 16) +12:4/0/terrains_peering_bit/right_side = 0 +12:4/0/terrains_peering_bit/left_side = 0 +12:4/0/terrains_peering_bit/top_side = 0 13:4/0 = 0 +13:4/0/terrain_set = 0 +13:4/0/terrain = 0 +13:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, -3.59256, -16, -5.16978, 16, -16, 16) +13:4/0/terrains_peering_bit/bottom_side = 0 +13:4/0/terrains_peering_bit/bottom_left_corner = 0 +13:4/0/terrains_peering_bit/left_side = 0 +13:4/0/terrains_peering_bit/top_side = 0 15:4/0 = 0 +15:4/0/terrain_set = 0 +15:4/0/terrain = 0 +15:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +15:4/0/terrains_peering_bit/right_side = 0 +15:4/0/terrains_peering_bit/top_side = 0 16:4/0 = 0 +16:4/0/terrain_set = 0 +16:4/0/terrain = 0 +16:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-16, -16, 16, -16, 16, 16, -16, 16) +16:4/0/terrains_peering_bit/left_side = 0 +16:4/0/terrains_peering_bit/top_side = 0 + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_g25fg"] +texture = ExtResource("4_g7vkj") +texture_region_size = Vector2i(32, 32) +0:0/0 = 0 +0:0/0/terrain_set = 0 +0:0/0/terrain = 1 + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_7bu6d"] +texture = ExtResource("5_vmqmt") +texture_region_size = Vector2i(32, 32) +0:0/0 = 0 +0:0/0/terrain_set = 0 +0:0/0/terrains_peering_bit/bottom_side = 1 +0:1/0 = 0 +0:1/0/terrain_set = 0 +0:1/0/terrain = 1 +0:1/0/terrains_peering_bit/top_side = 1 [sub_resource type="TileSet" id="TileSet_g7vkj"] tile_size = Vector2i(32, 32) +physics_layer_0/collision_layer = 1 +terrain_set_0/mode = 0 +terrain_set_0/terrain_0/name = "leafy dirt" +terrain_set_0/terrain_0/color = Color(0.5, 0.34375, 0.25, 1) +terrain_set_0/terrain_1/name = "veg" +terrain_set_0/terrain_1/color = Color(0.5, 0.4375, 0.25, 1) sources/0 = SubResource("TileSetAtlasSource_xqt3w") +sources/1 = SubResource("TileSetAtlasSource_g25fg") +sources/2 = SubResource("TileSetAtlasSource_7bu6d") [sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_ag0er"] @@ -72,44 +429,70 @@ script = ExtResource("1_3d84a") unique_name_in_owner = true script = ExtResource("2_t43dh") +[node name="sky layer" type="Parallax2D" parent="."] +repeat_size = Vector2(320, 180) + +[node name="Sprite2D" type="Sprite2D" parent="sky layer"] +position = Vector2(160, 90) +texture = ExtResource("3_vmqmt") + +[node name="Parallax2D2" type="Parallax2D" parent="."] +scroll_scale = Vector2(1.2, 0) +repeat_size = Vector2(320, 0) + +[node name="Sprite2D" type="Sprite2D" parent="Parallax2D2"] +position = Vector2(160, 320) +texture = ExtResource("3_vmqmt") + [node name="TileMapLayer" type="TileMapLayer" parent="."] texture_filter = 1 -scale = Vector2(1.00124, 0.995921) -tile_map_data = PackedByteArray("AAACAAQAAAAAAAAAAAADAAQAAAABAAAAAAAEAAQAAAACAAAAAAAGAAQAAAAAAAAAAAAIAAQAAAACAAAAAAAHAAQAAAABAAAAAAA=") +position = Vector2(162, 257) +scale = Vector2(0.994297, 0.997115) +tile_map_data = PackedByteArray("AAAWAAEAAAAAAAAAAAAXAAEAAAABAAAAAAAYAAEAAAABAAAAAAAZAAEAAAABAAAAAAAaAAEAAAABAAAAAAAbAAEAAAACAAAAAAAbAAIAAAAGAAEAAAAcAAIAAAABAAAAAAAbAAMAAAABAAEAAAAaAAIAAAABAAEAAAAaAAMAAAABAAEAAAAZAAMAAAABAAEAAAAYAAMAAAABAAEAAAAYAAQAAAABAAEAAAAXAAQAAAAGAAMAAAAXAAUAAAAAAAIAAAAYAAUAAAAHAAAAAAAYAAYAAAAAAAIAAAAZAAcAAAAAAAIAAAAaAAcAAAABAAIAAAAbAAcAAAAHAAAAAAAbAAgAAAAAAAIAAAAcAAgAAAABAAIAAAAdAAgAAAABAAIAAAAeAAgAAAACAAIAAAAeAAcAAAAHAAMAAAAeAAYAAAACAAEAAAAdAAYAAAABAAEAAAAcAAYAAAABAAEAAAAbAAYAAAABAAEAAAAaAAYAAAABAAEAAAAZAAYAAAAHAAAAAAAcAAcAAAABAAEAAAAdAAcAAAABAAEAAAAeAAUAAAAHAAMAAAAdAAUAAAABAAEAAAAcAAUAAAABAAEAAAAbAAUAAAABAAEAAAAaAAUAAAABAAEAAAAZAAUAAAABAAEAAAAZAAQAAAABAAEAAAAaAAQAAAABAAEAAAAbAAQAAAABAAEAAAAcAAQAAAABAAEAAAAdAAQAAAABAAEAAAAeAAQAAAAGAAAAAAAfAAQAAAACAAIAAAAdAAMAAAAGAAEAAAAcAAMAAAABAAEAAAAdAAIAAAACAAAAAAAeAAMAAAABAAAAAAAfAAMAAAACAAAAAAAZAAIAAAABAAEAAAAYAAIAAAABAAEAAAAXAAIAAAABAAEAAAAWAAIAAAAJAAEAAAAWAAMAAAAAAAIAAAAXAAMAAAAHAAAAAAAeAP7/AAAHAAAAAAAeAP3/AAABAAAAAAAfAP3/AAABAAAAAAAgAP3/AAACAAAAAAAgAP7/AAABAAEAAAAhAP7/AAACAAAAAAAhAP//AAAGAAEAAAAiAP//AAABAAAAAAAiAAAAAAABAAIAAAAhAAAAAAABAAIAAAAgAAAAAAABAAIAAAAfAAAAAAAAAAIAAAAeAP//AAAAAAIAAAAfAP7/AAABAAEAAAAgAP//AAABAAEAAAAfAP//AAAHAAAAAAAdAP7/AAABAAIAAAAcAP7/AAAAAAIAAAAcAP3/AAAAAAAAAAAdAP3/AAABAAAAAAAjAAAAAAABAAIAAAAjAP//AAABAAAAAAAkAP//AAACAAAAAAAkAAAAAAACAAIAAAAGAAkAAAAAAAAAAAAHAAkAAAABAAAAAAAIAAkAAAABAAAAAAAJAAkAAAABAAAAAAAKAAkAAAABAAAAAAALAAkAAAACAAAAAAAMAAoAAAACAAQAAAALAAoAAAAJAAQAAAAKAAoAAAABAAIAAAAJAAoAAAABAAIAAAAIAAoAAAABAAIAAAAHAAoAAAABAAIAAAAGAAoAAAAAAAIAAAALAAgAAQAAAAAAAAAHAAgAAQAAAAAAAAAMAAkAAgAAAAEAAAAMAAgAAgAAAAAAAAAKAAgAAgAAAAEAAAAKAAcAAgAAAAAAAAAOAAgAAAAAAAIAAAAOAAcAAAAHAAAAAAANAAcAAAAAAAIAAAANAAYAAAAAAAAAAAAOAAYAAAABAAAAAAAPAAYAAAACAAAAAAAPAAcAAAAGAAEAAAAQAAcAAAABAAAAAAARAAcAAAABAAAAAAASAAcAAAACAAAAAAASAAgAAAACAAIAAAARAAgAAAAGAAAAAAAQAAgAAAAHAAAAAAAPAAgAAAABAAIAAAAQAAkAAAAAAAIAAAARAAkAAAACAAIAAAADAAYAAAAAAAAAAAAEAAYAAAABAAAAAAAFAAYAAAAJAAMAAAAGAAYAAAACAAQAAAADAAcAAAAAAAIAAAAEAAcAAAABAAIAAAAFAAcAAAACAAIAAAAIAAcAAAAEAAQAAAA=") tile_set = SubResource("TileSet_g7vkj") [node name="StaticBody2D" parent="." instance=ExtResource("4_xqt3w")] -position = Vector2(113, 143) +position = Vector2(284, 402) scale = Vector2(1.11201, 1.40772) -[node name="StaticBody2D2" parent="." instance=ExtResource("4_xqt3w")] -position = Vector2(240, 143) - [node name="Crate1" parent="." instance=ExtResource("3_u2cf2")] -position = Vector2(90, 106) - -[node name="Crate2" parent="." instance=ExtResource("3_u2cf2")] -position = Vector2(233, 107) - -[node name="Crate" parent="." instance=ExtResource("3_u2cf2")] -position = Vector2(265, 107) - -[node name="Crate3" parent="." instance=ExtResource("3_u2cf2")] -position = Vector2(250, 84) +position = Vector2(385, 528) [node name="ground" type="StaticBody2D" parent="."] -position = Vector2(175, 236) +position = Vector2(338, 642) +scale = Vector2(2.15299, 1) metadata/_edit_group_ = true [node name="CollisionShape2D" type="CollisionShape2D" parent="ground"] shape = SubResource("WorldBoundaryShape2D_ag0er") [node name="Player" parent="." instance=ExtResource("4_f0he5")] -position = Vector2(127, 108) +position = Vector2(473, 529) [node name="Triggers" type="Node2D" parent="."] -position = Vector2(176, 113) +position = Vector2(339, 369) [node name="player hurt" parent="Triggers" instance=ExtResource("2_lptsb")] +position = Vector2(300, -7) + +[node name="Coins" type="Node2D" parent="."] + +[node name="coin" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(516, 532) + +[node name="coin2" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(420, 533) + +[node name="coin3" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(439, 537) + +[node name="coin4" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(432, 467) + +[node name="coin5" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(431, 446) + +[node name="coin6" parent="Coins" instance=ExtResource("11_g25fg")] +position = Vector2(491, 447) [connection signal="areaTriggerSignal" from="Triggers/player hurt" to="." method="_on_trigger"] diff --git a/Scenes/static_body_2d.tscn b/Scenes/static_body_2d.tscn index 15cc3cd..070c41b 100644 --- a/Scenes/static_body_2d.tscn +++ b/Scenes/static_body_2d.tscn @@ -9,3 +9,4 @@ metadata/_edit_group_ = true [node name="CollisionShape2D" type="CollisionShape2D" parent="."] shape = SubResource("RectangleShape2D_ag0er") +debug_color = Color(0, 0.6, 0.121569, 0.0823529) diff --git a/project.godot b/project.godot index 1c25b39..35a1a17 100644 --- a/project.godot +++ b/project.godot @@ -15,6 +15,14 @@ run/main_scene="uid://ibkufgrwjwro" config/features=PackedStringArray("4.4", "Forward Plus") config/icon="res://icon.svg" +[display] + +window/size/viewport_width=320 +window/size/viewport_height=180 +window/size/window_width_override=960 +window/size/window_height_override=540 +window/stretch/mode="viewport" + [input] ForcePush={ @@ -24,6 +32,6 @@ ForcePush={ } Shoot={ "deadzone": 0.2, -"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) +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"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":0,"location":0,"echo":false,"script":null) ] } diff --git a/scripts/bullet.gd b/scripts/bullet.gd index 2255946..ae5be6a 100644 --- a/scripts/bullet.gd +++ b/scripts/bullet.gd @@ -1,11 +1,17 @@ class_name Bullet extends Area2D +@onready var bullet_graphic: Sprite2D = $bullet_graphic + var speed: float = 700 signal bulletDamageSignal(target: Node2D, bullet: Node2D) -func setSpeed(val: float): - speed = val - +func setSpeed(value: float): + speed = value + if value<0: + bullet_graphic.flip_h = true + if value>0: + bullet_graphic.flip_h= false + func _physics_process(delta: float) -> void: position+=transform.x*speed*delta diff --git a/scripts/coin.gd b/scripts/coin.gd new file mode 100644 index 0000000..5855f0d --- /dev/null +++ b/scripts/coin.gd @@ -0,0 +1,7 @@ +class_name coin extends Area2D + +signal coincollectedsignal(body, coin) + +func _on_body_entered(body: Node2D) -> void: + print("coin collision") + coincollectedsignal.emit(body,self) diff --git a/scripts/coin.gd.uid b/scripts/coin.gd.uid new file mode 100644 index 0000000..7596bb2 --- /dev/null +++ b/scripts/coin.gd.uid @@ -0,0 +1 @@ +uid://bxb3b804re3sr diff --git a/scripts/gamecontroller.gd b/scripts/gamecontroller.gd index 39fa027..2e0e19f 100644 --- a/scripts/gamecontroller.gd +++ b/scripts/gamecontroller.gd @@ -27,3 +27,8 @@ func bulletDamage(target: Node2D, bullet: Node2D): print("GC sees a hit") target.queue_free() bullet.visible = false + +func coincollected(body, coin): + print("coincollected") + coin.queue_free() + diff --git a/scripts/scene_manager.gd b/scripts/scene_manager.gd index 4f3223b..e12fca3 100644 --- a/scripts/scene_manager.gd +++ b/scripts/scene_manager.gd @@ -3,12 +3,18 @@ class_name SCENEMANAGER extends Node2D const bulletscn = preload("res://Scenes/bullet.tscn") @onready var game: Node2D = $".." @onready var triggers: Node2D = $"../Triggers" +@onready var coins: Node2D = $"../Coins" func _ready() -> void: if triggers: for obj in triggers.get_children(): if obj is Trigger: obj.areaTriggerSignal.connect(game._on_trigger) + if coins: + for obj in coins.get_children(): + if obj is coin: + obj.coincollectedsignal.connect(game.coincollected) + var bullets: Array[Bullet] = [] const MAX_BULLETS = 10