player death, player hurt, ui
This commit is contained in:
1 parent
ce71477b76
commit
321259532e
14 files changed
+376
-42
No files matched your search
@@ -20,4 +20,5 @@ rotation = 3.14159
|
||||
scale = Vector2(0.117753, 0.117753)
|
||||
texture = ExtResource("2_pcjo1")
|
||||
|
||||
[connection signal="area_entered" from="." to="." method="_on_area_entered"]
|
||||
[connection signal="body_entered" from="." to="." method="_on_body_entered"]
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=15 format=4 uid="uid://cxnmaxykhbgaq"]
|
||||
[gd_scene load_steps=16 format=4 uid="uid://cxnmaxykhbgaq"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://63qb2drh1l33" path="res://scenes/crate.tscn" id="1_0wmww"]
|
||||
[ext_resource type="Script" path="res://scripts/Trigger.gd" id="3_4laji"]
|
||||
@@ -10,6 +10,7 @@
|
||||
[ext_resource type="Texture2D" uid="uid://c7gfcwmohp6th" path="res://assets/graphics/terrains/Terrain (32x32).png" id="7_ogiiy"]
|
||||
[ext_resource type="PackedScene" uid="uid://crtf2vkqussp6" path="res://scenes/coin.tscn" id="9_5tydy"]
|
||||
[ext_resource type="PackedScene" uid="uid://cydfsa8y0pare" path="res://scenes/purpleslime.tscn" id="10_6gyln"]
|
||||
[ext_resource type="PackedScene" uid="uid://dc1gigufw7iv6" path="res://scenes/ui.tscn" id="11_stjw2"]
|
||||
|
||||
[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_06fpy"]
|
||||
texture = ExtResource("7_ogiiy")
|
||||
@@ -395,6 +396,10 @@ radius = 34.1321
|
||||
unique_name_in_owner = true
|
||||
script = ExtResource("6_duuox")
|
||||
|
||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
||||
|
||||
[node name="ui" parent="CanvasLayer" instance=ExtResource("11_stjw2")]
|
||||
|
||||
[node name="Background" type="Parallax2D" parent="."]
|
||||
scroll_scale = Vector2(0.1, 1)
|
||||
repeat_size = Vector2(320, 0)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
[gd_scene load_steps=15 format=4 uid="uid://o0v5c7tcpi8o"]
|
||||
[gd_scene load_steps=16 format=4 uid="uid://o0v5c7tcpi8o"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/scene_manager.gd" id="1_rlteh"]
|
||||
[ext_resource type="PackedScene" uid="uid://dc1gigufw7iv6" path="res://scenes/ui.tscn" id="2_n27lq"]
|
||||
[ext_resource type="Texture2D" uid="uid://cpnkcukncgjj6" path="res://assets/graphics/terrains/backgrounds/skystrip.png" id="2_yeti2"]
|
||||
[ext_resource type="Texture2D" uid="uid://xfytknjv7u4t" path="res://assets/graphics/terrains/backgrounds/forestbackground.png" id="3_r50tl"]
|
||||
[ext_resource type="Texture2D" uid="uid://ywtw6acl17qh" path="res://assets/graphics/terrains/backgrounds/trees.png" id="4_axi0m"]
|
||||
@@ -395,6 +396,10 @@ radius = 34.1321
|
||||
unique_name_in_owner = true
|
||||
script = ExtResource("1_rlteh")
|
||||
|
||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
||||
|
||||
[node name="ui" parent="CanvasLayer" instance=ExtResource("2_n27lq")]
|
||||
|
||||
[node name="Background" type="Parallax2D" parent="."]
|
||||
scroll_scale = Vector2(0.1, 1)
|
||||
repeat_size = Vector2(320, 0)
|
||||
|
||||
@@ -1,12 +1,70 @@
|
||||
[gd_scene load_steps=28 format=3 uid="uid://c1cuiluq1fcpk"]
|
||||
[gd_scene load_steps=44 format=3 uid="uid://c1cuiluq1fcpk"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/player.gd" id="1_s1kdl"]
|
||||
[ext_resource type="Texture2D" uid="uid://dmatixjfu6l4x" path="res://assets/graphics/player/death/Player Death 64x64.png" id="2_cy83k"]
|
||||
[ext_resource type="Texture2D" uid="uid://cv2rxkxb3qt8d" path="res://assets/graphics/player/idle/Player Idle 48x48.png" id="2_h20by"]
|
||||
[ext_resource type="Texture2D" uid="uid://cnya66cp8q1jw" path="res://assets/graphics/player/jump/player jump 48x48.png" id="3_fr7w2"]
|
||||
[ext_resource type="Texture2D" uid="uid://ds0ii0prt3pij" path="res://assets/graphics/player/run/player run 48x48.png" id="3_gom75"]
|
||||
[ext_resource type="Texture2D" uid="uid://dbrn5rtx4ncnb" path="res://assets/graphics/player/hurt/Player Hurt 48x48.png" id="3_krvug"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_y4y41"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_u6c1c"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_3fhqy"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_e287b"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_133il"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_0kl6l"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(192, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_3s0rc"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(240, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_w1lsm"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(288, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_twkd7"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(336, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_otxiu"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(384, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_jhl08"]
|
||||
atlas = ExtResource("2_cy83k")
|
||||
region = Rect2(432, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_d2i3x"]
|
||||
atlas = ExtResource("3_krvug")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_kdvla"]
|
||||
atlas = ExtResource("3_krvug")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_bbh0j"]
|
||||
atlas = ExtResource("3_krvug")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_52xvf"]
|
||||
atlas = ExtResource("3_krvug")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_mww1u"]
|
||||
atlas = ExtResource("2_h20by")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
@@ -95,6 +153,58 @@ region = Rect2(336, 0, 48, 48)
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_u6c1c")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_3fhqy")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_e287b")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_133il")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_0kl6l")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_3s0rc")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_w1lsm")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_twkd7")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_otxiu")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_jhl08")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"death",
|
||||
"speed": 6.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_d2i3x")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_kdvla")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_bbh0j")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_52xvf")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"hurt",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_mww1u")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
@@ -194,13 +304,15 @@ position = Vector2(10, -5)
|
||||
position = Vector2(-10, -5)
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="."]
|
||||
offset = Vector2(0, -60)
|
||||
offset = Vector2(0, -20)
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
texture_filter = 1
|
||||
position = Vector2(0, -5)
|
||||
sprite_frames = SubResource("SpriteFrames_gcr48")
|
||||
animation = &"jump"
|
||||
animation = &"death"
|
||||
autoplay = "jump"
|
||||
frame = 2
|
||||
frame = 9
|
||||
frame_progress = 1.0
|
||||
|
||||
[connection signal="animation_finished" from="AnimatedSprite2D" to="." method="_on_animation_finished"]
|
||||
@@ -0,0 +1,46 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://dc1gigufw7iv6"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/ui.gd" id="1_t3bu7"]
|
||||
|
||||
[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_t3bu7")
|
||||
|
||||
[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="MarginContainer3" type="MarginContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="timer" type="Label" parent="VBoxContainer/HBoxContainer/MarginContainer3"]
|
||||
layout_mode = 2
|
||||
text = "10"
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="coins" type="Label" parent="VBoxContainer/HBoxContainer/MarginContainer2"]
|
||||
layout_mode = 2
|
||||
text = "COINS"
|
||||
horizontal_alignment = 2
|
||||
Reference in new issue
Block a user