custom resources, player damage, bad guy damage, animations, ui
This commit is contained in:
1 parent
7f787903b7
commit
a93515f621
20 files changed
+418
-36
No files matched your search
@@ -20,4 +20,5 @@ position = Vector2(4, 3)
|
||||
scale = Vector2(0.1, 0.1)
|
||||
texture = ExtResource("2_y25gk")
|
||||
|
||||
[connection signal="area_entered" from="." to="." method="_on_area_entered"]
|
||||
[connection signal="body_entered" from="." to="." method="_on_body_entered"]
|
||||
+8
-3
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=20 format=4 uid="uid://cwuxdg5c8ylmp"]
|
||||
[gd_scene load_steps=21 format=4 uid="uid://cwuxdg5c8ylmp"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bus3b1g717jlm" path="res://scripts/scene_manager.gd" id="2_lbhrr"]
|
||||
[ext_resource type="PackedScene" uid="uid://cgk1d1f5ffbbd" path="res://scenes/player.tscn" id="2_lnu2h"]
|
||||
@@ -13,6 +13,7 @@
|
||||
[ext_resource type="Texture2D" uid="uid://bu2davrqnpe" path="res://assets/graphics/background/plane.png" id="6_kvuet"]
|
||||
[ext_resource type="PackedScene" uid="uid://c0b4iaixh56in" path="res://scenes/coin.tscn" id="12_dinhu"]
|
||||
[ext_resource type="PackedScene" uid="uid://cro4avvf0dbbr" path="res://scenes/slime.tscn" id="13_kvuet"]
|
||||
[ext_resource type="PackedScene" uid="uid://c5onww62xhfy" path="res://scenes/ui.tscn" id="14_trtic"]
|
||||
|
||||
[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_gee14"]
|
||||
texture = ExtResource("3_u5sy4")
|
||||
@@ -487,7 +488,7 @@ shape = SubResource("WorldBoundaryShape2D_16wxc")
|
||||
[node name="crates" type="Node2D" parent="."]
|
||||
|
||||
[node name="RigidBody2D3" parent="crates" instance=ExtResource("4_iywne")]
|
||||
position = Vector2(367, 271)
|
||||
position = Vector2(242, 215)
|
||||
|
||||
[node name="triggers" type="Node2D" parent="."]
|
||||
|
||||
@@ -514,10 +515,14 @@ position = Vector2(557, 314)
|
||||
[node name="enemies" type="Node2D" parent="."]
|
||||
|
||||
[node name="Area2D" parent="enemies" instance=ExtResource("13_kvuet")]
|
||||
position = Vector2(396, 275)
|
||||
position = Vector2(396, 276)
|
||||
|
||||
[node name="Area2D2" parent="enemies" instance=ExtResource("13_kvuet")]
|
||||
position = Vector2(594, 309)
|
||||
|
||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
||||
|
||||
[node name="ui" parent="CanvasLayer" instance=ExtResource("14_trtic")]
|
||||
|
||||
[connection signal="triggerFired" from="triggers/Trigger" to="." method="_on_trigger_fired"]
|
||||
[connection signal="triggerFired" from="triggers/Trigger2" to="." method="_on_trigger_fired"]
|
||||
+112
-2
@@ -1,17 +1,75 @@
|
||||
[gd_scene load_steps=35 format=3 uid="uid://cgk1d1f5ffbbd"]
|
||||
[gd_scene load_steps=51 format=3 uid="uid://cgk1d1f5ffbbd"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dmchcjip7pcfj" path="res://scripts/player.gd" id="1_3vyb7"]
|
||||
[ext_resource type="Texture2D" uid="uid://x7vc805d7m4t" path="res://assets/graphics/player/jump/player jump 48x48.png" id="2_dqkch"]
|
||||
[ext_resource type="Texture2D" uid="uid://bgcr86uy5kqei" path="res://assets/graphics/player/death/Player Death 64x64.png" id="2_fjrip"]
|
||||
[ext_resource type="Texture2D" uid="uid://dbcs1873oc7m7" path="res://assets/graphics/player/idle/Player Idle 48x48.png" id="2_g2els"]
|
||||
[ext_resource type="Texture2D" uid="uid://chiih26xngprp" path="res://assets/graphics/player/run/player run 48x48.png" id="3_qhqgy"]
|
||||
[ext_resource type="Texture2D" uid="uid://dqwcn03jnrupq" path="res://assets/graphics/player/melee/Player Punch 64x64.png" id="4_qlg0r"]
|
||||
[ext_resource type="Texture2D" uid="uid://bvp2ecy6hu04v" path="res://assets/graphics/player/hurt/Player Hurt 48x48.png" id="4_smehm"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_ryu2m"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_pf23h"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_dt7fs"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_wqfne"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_wnwbv"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_gl8cc"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(192, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_487ah"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(240, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_md1ol"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(288, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_bj30b"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(336, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_jc3p3"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(384, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_hax0n"]
|
||||
atlas = ExtResource("2_fjrip")
|
||||
region = Rect2(432, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_i4ail"]
|
||||
atlas = ExtResource("2_dqkch")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_t4otl"]
|
||||
atlas = ExtResource("4_smehm")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_j2b1d"]
|
||||
atlas = ExtResource("4_smehm")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_cs1tg"]
|
||||
atlas = ExtResource("4_smehm")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_2dvfe"]
|
||||
atlas = ExtResource("4_smehm")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_qhqgy"]
|
||||
atlas = ExtResource("2_g2els")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
@@ -112,6 +170,41 @@ region = Rect2(336, 0, 48, 48)
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_pf23h")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_dt7fs")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_wqfne")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_wnwbv")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_gl8cc")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_487ah")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_md1ol")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_bj30b")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_jc3p3")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_hax0n")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"death",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_i4ail")
|
||||
}],
|
||||
"loop": false,
|
||||
@@ -120,6 +213,23 @@ animations = [{
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_t4otl")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_j2b1d")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_cs1tg")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_2dvfe")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"hurt",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_qhqgy")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
@@ -248,7 +358,7 @@ one_shot = true
|
||||
texture_filter = 1
|
||||
position = Vector2(0, -7)
|
||||
sprite_frames = SubResource("SpriteFrames_jej6c")
|
||||
animation = &"idle"
|
||||
animation = &"death"
|
||||
autoplay = "idle"
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="."]
|
||||
|
||||
+35
-3
@@ -1,8 +1,24 @@
|
||||
[gd_scene load_steps=9 format=3 uid="uid://cro4avvf0dbbr"]
|
||||
[gd_scene load_steps=13 format=3 uid="uid://cro4avvf0dbbr"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bk0hrjj1738iy" path="res://scripts/slime.gd" id="1_p2gj0"]
|
||||
[ext_resource type="Texture2D" uid="uid://bc5qrj3rg2rey" path="res://assets/graphics/enemies/slime_green.png" id="2_n6pvg"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_p2gj0"]
|
||||
atlas = ExtResource("2_n6pvg")
|
||||
region = Rect2(0, 48, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_n6pvg"]
|
||||
atlas = ExtResource("2_n6pvg")
|
||||
region = Rect2(24, 48, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_v5wyi"]
|
||||
atlas = ExtResource("2_n6pvg")
|
||||
region = Rect2(48, 48, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_0l8pv"]
|
||||
atlas = ExtResource("2_n6pvg")
|
||||
region = Rect2(72, 48, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_pjw23"]
|
||||
atlas = ExtResource("2_n6pvg")
|
||||
region = Rect2(0, 24, 24, 24)
|
||||
@@ -23,6 +39,23 @@ region = Rect2(72, 24, 24, 24)
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_p2gj0")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_n6pvg")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_v5wyi")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_0l8pv")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"hurt",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_pjw23")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
@@ -48,9 +81,8 @@ script = ExtResource("1_p2gj0")
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
texture_filter = 1
|
||||
sprite_frames = SubResource("SpriteFrames_v5wyi")
|
||||
animation = &"run"
|
||||
animation = &"hurt"
|
||||
autoplay = "run"
|
||||
frame_progress = 0.677109
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
position = Vector2(0, 4.5)
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://c5onww62xhfy"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://daslx4en4rji1" path="res://scripts/ui.gd" id="1_nt7q6"]
|
||||
|
||||
[node name="Control" type="Control"]
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
script = ExtResource("1_nt7q6")
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="."]
|
||||
layout_mode = 1
|
||||
anchors_preset = 10
|
||||
anchor_right = 1.0
|
||||
grow_horizontal = 2
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="health" type="Label" parent="VBoxContainer/HBoxContainer/MarginContainer"]
|
||||
layout_mode = 2
|
||||
text = "Health"
|
||||
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="timer" type="Label" parent="VBoxContainer/HBoxContainer/MarginContainer2"]
|
||||
layout_mode = 2
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="MarginContainer3" type="MarginContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="coins" type="Label" parent="VBoxContainer/HBoxContainer/MarginContainer3"]
|
||||
layout_mode = 2
|
||||
text = "Coins"
|
||||
horizontal_alignment = 2
|
||||
Reference in new issue
Block a user