enemies, game controller, playerdeath, coins, player hurt
This commit is contained in:
1 parent
082386ee29
commit
8966ac2165
21 files changed
+718
-88
No files matched your search
@@ -0,0 +1,77 @@
|
||||
[gd_scene load_steps=9 format=3 uid="uid://bfex451nb78lt"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/badguy.gd" id="1_vier3"]
|
||||
[ext_resource type="Texture2D" uid="uid://cshrbm2roxdfc" path="res://assets/graphics/enemies/slime_green.png" id="1_x0bq5"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_1yklg"]
|
||||
size = Vector2(12.6615, 13.5659)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_nlkx5"]
|
||||
atlas = ExtResource("1_x0bq5")
|
||||
region = Rect2(0, 24, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_imbiq"]
|
||||
atlas = ExtResource("1_x0bq5")
|
||||
region = Rect2(24, 24, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_46pxa"]
|
||||
atlas = ExtResource("1_x0bq5")
|
||||
region = Rect2(48, 24, 24, 24)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_xkbu6"]
|
||||
atlas = ExtResource("1_x0bq5")
|
||||
region = Rect2(72, 24, 24, 24)
|
||||
|
||||
[sub_resource type="SpriteFrames" id="SpriteFrames_yljrg"]
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_nlkx5")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_imbiq")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_46pxa")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_xkbu6")
|
||||
}],
|
||||
"loop": true,
|
||||
"name": &"idle",
|
||||
"speed": 12.0
|
||||
}]
|
||||
|
||||
[node name="Area2D" type="Area2D"]
|
||||
script = ExtResource("1_vier3")
|
||||
metadata/_edit_group_ = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
position = Vector2(5.96046e-08, -0.5)
|
||||
scale = Vector2(1.10571, 1.10571)
|
||||
shape = SubResource("RectangleShape2D_1yklg")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
texture_filter = 1
|
||||
position = Vector2(0, -5)
|
||||
sprite_frames = SubResource("SpriteFrames_yljrg")
|
||||
animation = &"idle"
|
||||
autoplay = "idle"
|
||||
frame = 2
|
||||
frame_progress = 0.395087
|
||||
|
||||
[node name="CastRight" type="RayCast2D" parent="."]
|
||||
target_position = Vector2(13, 0)
|
||||
|
||||
[node name="CastLeft" type="RayCast2D" parent="."]
|
||||
target_position = Vector2(-13, 0)
|
||||
|
||||
[node name="CastFloorRight" type="RayCast2D" parent="."]
|
||||
position = Vector2(7, 1)
|
||||
target_position = Vector2(0, 8)
|
||||
|
||||
[node name="CastFloorLeft" type="RayCast2D" parent="."]
|
||||
position = Vector2(-7, 1)
|
||||
target_position = Vector2(0, 8)
|
||||
|
||||
[connection signal="body_entered" from="." to="." method="_on_body_entered"]
|
||||
@@ -1,6 +1,8 @@
|
||||
[gd_scene load_steps=28 format=3 uid="uid://b6vk2imhuhv0j"]
|
||||
[gd_scene load_steps=44 format=3 uid="uid://b6vk2imhuhv0j"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/dudecontroller.gd" id="1_esbkk"]
|
||||
[ext_resource type="Texture2D" uid="uid://4hq64jj4kprc" path="res://assets/graphics/player/death/Player Death 64x64.png" id="2_bws84"]
|
||||
[ext_resource type="Texture2D" uid="uid://bibmmytjgw0nl" path="res://assets/graphics/player/hurt/Player Hurt 48x48.png" id="2_gm3uu"]
|
||||
[ext_resource type="Texture2D" uid="uid://da3mdnk0s8bxc" path="res://assets/graphics/player/idle/Player Idle 48x48.png" id="2_jvkyl"]
|
||||
[ext_resource type="Texture2D" uid="uid://cfmrxvwojl071" path="res://assets/graphics/player/jump/player jump 48x48.png" id="3_nnfwu"]
|
||||
[ext_resource type="Texture2D" uid="uid://lk01unajxhx0" path="res://assets/graphics/player/run/player run 48x48.png" id="3_qml56"]
|
||||
@@ -8,6 +10,62 @@
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_drde1"]
|
||||
radius = 15.0
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_36q7i"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_j4tb0"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_wghdt"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_bh361"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_7wfdh"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(192, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_o0mvc"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(240, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_p2eca"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(288, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_jc1nd"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(336, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_q1uk6"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(384, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_gqkgi"]
|
||||
atlas = ExtResource("2_bws84")
|
||||
region = Rect2(432, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_6lqi3"]
|
||||
atlas = ExtResource("2_gm3uu")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_sserb"]
|
||||
atlas = ExtResource("2_gm3uu")
|
||||
region = Rect2(48, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_tkl74"]
|
||||
atlas = ExtResource("2_gm3uu")
|
||||
region = Rect2(96, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_7br0y"]
|
||||
atlas = ExtResource("2_gm3uu")
|
||||
region = Rect2(144, 0, 48, 48)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_v6vtg"]
|
||||
atlas = ExtResource("2_jvkyl")
|
||||
region = Rect2(0, 0, 48, 48)
|
||||
@@ -96,6 +154,58 @@ region = Rect2(336, 0, 48, 48)
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_36q7i")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_j4tb0")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_wghdt")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_bh361")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_7wfdh")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_o0mvc")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_p2eca")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_jc1nd")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_q1uk6")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_gqkgi")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"death",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_6lqi3")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_sserb")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_tkl74")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_7br0y")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"hurt",
|
||||
"speed": 12.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_v6vtg")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
@@ -198,8 +308,10 @@ position = Vector2(-16, -5)
|
||||
texture_filter = 1
|
||||
position = Vector2(0, -1)
|
||||
sprite_frames = SubResource("SpriteFrames_xt5u3")
|
||||
animation = &"idle"
|
||||
animation = &"death"
|
||||
autoplay = "idle"
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="."]
|
||||
offset = Vector2(0, -40)
|
||||
|
||||
[connection signal="animation_finished" from="AnimatedSprite2D" to="." method="_on_animation_finished"]
|
||||
@@ -0,0 +1,113 @@
|
||||
[gd_scene load_steps=17 format=3 uid="uid://bc6587qq8v636"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://cxil0e8gvkg18" path="res://assets/graphics/pickups/coin.png" id="1_gau74"]
|
||||
[ext_resource type="Script" path="res://scripts/coin.gd" id="1_ydk8w"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_7tg8h"]
|
||||
radius = 5.0
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_7r3qr"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(0, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_fsm1g"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(16, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_34y51"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(32, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_r3sgi"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(48, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_3oltj"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(64, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_p6mss"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(80, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_oj8qo"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(96, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_iorej"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(112, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_xhjtr"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(128, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_dpmih"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(144, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_cnmdp"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(160, 0, 16, 16)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_qxp47"]
|
||||
atlas = ExtResource("1_gau74")
|
||||
region = Rect2(176, 0, 16, 16)
|
||||
|
||||
[sub_resource type="SpriteFrames" id="SpriteFrames_dbf75"]
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_7r3qr")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_fsm1g")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_34y51")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_r3sgi")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_3oltj")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_p6mss")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_oj8qo")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_iorej")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_xhjtr")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_dpmih")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_cnmdp")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_qxp47")
|
||||
}],
|
||||
"loop": true,
|
||||
"name": &"default",
|
||||
"speed": 12.0
|
||||
}]
|
||||
|
||||
[node name="Area2D" type="Area2D"]
|
||||
script = ExtResource("1_ydk8w")
|
||||
metadata/_edit_group_ = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("CircleShape2D_7tg8h")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
texture_filter = 1
|
||||
sprite_frames = SubResource("SpriteFrames_dbf75")
|
||||
autoplay = "default"
|
||||
|
||||
[connection signal="body_entered" from="." to="." method="_on_body_entered"]
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=16 format=4 uid="uid://dmk3hbsrqhgad"]
|
||||
[gd_scene load_steps=18 format=4 uid="uid://dmk3hbsrqhgad"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://dv6amvxucgy0g" path="res://assets/graphics/enviroment/terrain/Terrain (32x32).png" id="1_ab3a4"]
|
||||
[ext_resource type="PackedScene" uid="uid://flumvyk8tafw" path="res://scenes/box.tscn" id="1_ixp3c"]
|
||||
@@ -9,6 +9,8 @@
|
||||
[ext_resource type="Texture2D" uid="uid://bihm8chupdlu2" path="res://assets/graphics/enviroment/background/stratosphere.png" id="2_l8kko"]
|
||||
[ext_resource type="Texture2D" uid="uid://lj1cipgutadw" path="res://assets/graphics/enviroment/background/midground.png" id="2_w7c1m"]
|
||||
[ext_resource type="PackedScene" uid="uid://e4o5ja1w0gph" path="res://scenes/bullet.tscn" id="4_7436f"]
|
||||
[ext_resource type="PackedScene" uid="uid://bc6587qq8v636" path="res://scenes/coin.tscn" id="10_akvym"]
|
||||
[ext_resource type="PackedScene" uid="uid://bfex451nb78lt" path="res://scenes/badguy.tscn" id="11_387qc"]
|
||||
|
||||
[sub_resource type="TileMapPattern" id="TileMapPattern_fkdsw"]
|
||||
tile_data = PackedInt32Array(0, 262144, 0, 65536, 262144, 1, 131072, 262144, 2)
|
||||
@@ -430,10 +432,10 @@ shape = SubResource("RectangleShape2D_0jo0r")
|
||||
debug_color = Color(0.774214, 0.233911, 0.917118, 0.42)
|
||||
|
||||
[node name="RigidBody2D" parent="." instance=ExtResource("1_ixp3c")]
|
||||
position = Vector2(399, 48)
|
||||
position = Vector2(466, 45)
|
||||
|
||||
[node name="RigidBody2D2" parent="." instance=ExtResource("1_ixp3c")]
|
||||
position = Vector2(525, 46)
|
||||
position = Vector2(546, 45)
|
||||
|
||||
[node name="RigidBody2D3" parent="." instance=ExtResource("1_ixp3c")]
|
||||
position = Vector2(634, 44)
|
||||
@@ -457,4 +459,23 @@ repeat_size = Vector2(320, 0)
|
||||
position = Vector2(180, 120)
|
||||
texture = ExtResource("2_w7c1m")
|
||||
|
||||
[node name="Coins" type="Node" parent="."]
|
||||
|
||||
[node name="Coin" parent="Coins" instance=ExtResource("10_akvym")]
|
||||
position = Vector2(79, 80)
|
||||
|
||||
[node name="Coin2" parent="Coins" instance=ExtResource("10_akvym")]
|
||||
position = Vector2(143, 18)
|
||||
|
||||
[node name="Coin3" parent="Coins" instance=ExtResource("10_akvym")]
|
||||
position = Vector2(143, -43)
|
||||
|
||||
[node name="Coin4" parent="Coins" instance=ExtResource("10_akvym")]
|
||||
position = Vector2(47, -50)
|
||||
|
||||
[node name="enemies" type="Node" parent="."]
|
||||
|
||||
[node name="Area2D3" parent="enemies" instance=ExtResource("11_387qc")]
|
||||
position = Vector2(391, 122)
|
||||
|
||||
[connection signal="body_entered" from="Area2D" to="Area2D" method="_on_body_entered"]
|
||||
Reference in new issue
Block a user