Skip to content

Commit e573ba8

Browse files
committed
Reopen dodge-the-creeps in Godot 4.0 stable editor
1 parent f9db5d6 commit e573ba8

File tree

4 files changed

+60
-31
lines changed

4 files changed

+60
-31
lines changed

examples/dodge-the-creeps/godot/Main.tscn

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
[ext_resource type="PackedScene" uid="uid://4vwrqjegqwpj" path="res://Player.tscn" id="3"]
44
[ext_resource type="PackedScene" uid="uid://b6f427lco0mqk" path="res://Hud.tscn" id="4"]
5-
[ext_resource type="AudioStream" uid="uid://jy3fk3ujnkpl" path="res://art/House In a Forest Loop.ogg" id="5"]
6-
[ext_resource type="AudioStream" uid="uid://cfb6f1t1p6axm" path="res://art/gameover.wav" id="6"]
5+
[ext_resource type="AudioStream" uid="uid://4nydgv0blw0f" path="res://art/House In a Forest Loop.ogg" id="5"]
6+
[ext_resource type="AudioStream" uid="uid://bfm4mpbt2cmpk" path="res://art/gameover.wav" id="6"]
77

88
[sub_resource type="Curve2D" id="1"]
99
_data = {

examples/dodge-the-creeps/godot/Mob.tscn

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,43 @@
11
[gd_scene load_steps=9 format=3 uid="uid://rkdnhqgf2hpj"]
22

3-
[ext_resource type="Texture2D" uid="uid://ch2bfqohapw00" path="res://art/enemyFlyingAlt_1.png" id="2"]
4-
[ext_resource type="Texture2D" uid="uid://uhy7j2necuj2" path="res://art/enemyFlyingAlt_2.png" id="3"]
5-
[ext_resource type="Texture2D" uid="uid://dd56ab6ouwms7" path="res://art/enemyWalking_1.png" id="4"]
6-
[ext_resource type="Texture2D" uid="uid://dulw5juue3ivn" path="res://art/enemyWalking_2.png" id="5"]
7-
[ext_resource type="Texture2D" uid="uid://cnwoep5enlhrj" path="res://art/enemySwimming_1.png" id="6"]
8-
[ext_resource type="Texture2D" uid="uid://eqshh2v5g0dn" path="res://art/enemySwimming_2.png" id="7"]
3+
[ext_resource type="Texture2D" uid="uid://cm5gcq5ye1dfp" path="res://art/enemyFlyingAlt_1.png" id="2"]
4+
[ext_resource type="Texture2D" uid="uid://bgm216v7s45eh" path="res://art/enemyFlyingAlt_2.png" id="3"]
5+
[ext_resource type="Texture2D" uid="uid://8mvo2d5mwhbr" path="res://art/enemyWalking_1.png" id="4"]
6+
[ext_resource type="Texture2D" uid="uid://c8wjbhrgviadh" path="res://art/enemyWalking_2.png" id="5"]
7+
[ext_resource type="Texture2D" uid="uid://bmw4gn8qp4owc" path="res://art/enemySwimming_1.png" id="6"]
8+
[ext_resource type="Texture2D" uid="uid://bciy3d2t3uuvf" path="res://art/enemySwimming_2.png" id="7"]
99

1010
[sub_resource type="SpriteFrames" id="1"]
1111
animations = [{
12-
"frames": [ExtResource("2"), ExtResource("3")],
12+
"frames": [{
13+
"duration": 1.0,
14+
"texture": ExtResource("2")
15+
}, {
16+
"duration": 1.0,
17+
"texture": ExtResource("3")
18+
}],
1319
"loop": true,
1420
"name": &"fly",
1521
"speed": 3.0
1622
}, {
17-
"frames": [ExtResource("6"), ExtResource("7")],
23+
"frames": [{
24+
"duration": 1.0,
25+
"texture": ExtResource("6")
26+
}, {
27+
"duration": 1.0,
28+
"texture": ExtResource("7")
29+
}],
1830
"loop": true,
1931
"name": &"swim",
2032
"speed": 4.0
2133
}, {
22-
"frames": [ExtResource("4"), ExtResource("5")],
34+
"frames": [{
35+
"duration": 1.0,
36+
"texture": ExtResource("4")
37+
}, {
38+
"duration": 1.0,
39+
"texture": ExtResource("5")
40+
}],
2341
"loop": true,
2442
"name": &"walk",
2543
"speed": 4.0
@@ -35,9 +53,8 @@ gravity_scale = 0.0
3553

3654
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
3755
scale = Vector2(0.75, 0.75)
38-
frames = SubResource("1")
39-
animation = &"walk"
40-
playing = true
56+
sprite_frames = SubResource("1")
57+
animation = &"fly"
4158

4259
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
4360
rotation = 1.5708

examples/dodge-the-creeps/godot/Player.tscn

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,30 @@
11
[gd_scene load_steps=12 format=3 uid="uid://4vwrqjegqwpj"]
22

3-
[ext_resource type="Texture2D" uid="uid://bei50n77gmlml" path="res://art/playerGrey_walk1.png" id="2"]
4-
[ext_resource type="Texture2D" uid="uid://bdkoaa5a3c44c" path="res://art/playerGrey_walk2.png" id="3"]
5-
[ext_resource type="Texture2D" uid="uid://qpg7fsh1wnd6" path="res://art/playerGrey_up1.png" id="4"]
6-
[ext_resource type="Texture2D" uid="uid://c4vx8t665is8j" path="res://art/playerGrey_up2.png" id="5"]
3+
[ext_resource type="Texture2D" uid="uid://bj4l4w7uqqvj8" path="res://art/playerGrey_walk1.png" id="2"]
4+
[ext_resource type="Texture2D" uid="uid://m72luixufvrn" path="res://art/playerGrey_walk2.png" id="3"]
5+
[ext_resource type="Texture2D" uid="uid://capk1keirob5u" path="res://art/playerGrey_up1.png" id="4"]
6+
[ext_resource type="Texture2D" uid="uid://l7hs5mf40b2s" path="res://art/playerGrey_up2.png" id="5"]
77

88
[sub_resource type="SpriteFrames" id="1"]
99
animations = [{
10-
"frames": [ExtResource("2"), ExtResource("3")],
10+
"frames": [{
11+
"duration": 1.0,
12+
"texture": ExtResource("2")
13+
}, {
14+
"duration": 1.0,
15+
"texture": ExtResource("3")
16+
}],
1117
"loop": true,
1218
"name": &"right",
1319
"speed": 5.0
1420
}, {
15-
"frames": [ExtResource("4"), ExtResource("5")],
21+
"frames": [{
22+
"duration": 1.0,
23+
"texture": ExtResource("4")
24+
}, {
25+
"duration": 1.0,
26+
"texture": ExtResource("5")
27+
}],
1628
"loop": true,
1729
"name": &"up",
1830
"speed": 5.0
@@ -46,7 +58,7 @@ z_index = 10
4658

4759
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
4860
scale = Vector2(0.5, 0.5)
49-
frames = SubResource("1")
61+
sprite_frames = SubResource("1")
5062
animation = &"right"
5163

5264
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
@@ -55,8 +67,8 @@ shape = SubResource("2")
5567
[node name="Trail" type="GPUParticles2D" parent="."]
5668
z_index = -1
5769
amount = 10
58-
speed_scale = 2.0
5970
process_material = SubResource("7")
6071
texture = ExtResource("2")
72+
speed_scale = 2.0
6173

6274
[connection signal="body_entered" from="." to="." method="on_player_body_entered"]

examples/dodge-the-creeps/godot/project.godot

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,39 +37,39 @@ window/stretch/mode="canvas_items"
3737

3838
move_left={
3939
"deadzone": 0.5,
40-
"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":16777231,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
41-
, 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":65,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
40+
"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":16777231,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
41+
, 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":65,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
4242
, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":14,"pressure":0.0,"pressed":false,"script":null)
4343
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":-1.0,"script":null)
4444
]
4545
}
4646
move_right={
4747
"deadzone": 0.5,
48-
"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":16777233,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
49-
, 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":68,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
48+
"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":16777233,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
49+
, 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":68,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
5050
, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":15,"pressure":0.0,"pressed":false,"script":null)
5151
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":1.0,"script":null)
5252
]
5353
}
5454
move_up={
5555
"deadzone": 0.5,
56-
"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":16777232,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
57-
, 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":87,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
56+
"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":16777232,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
57+
, 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":87,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
5858
, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":12,"pressure":0.0,"pressed":false,"script":null)
5959
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":-1.0,"script":null)
6060
]
6161
}
6262
move_down={
6363
"deadzone": 0.5,
64-
"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":16777234,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
65-
, 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":83,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
64+
"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":16777234,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
65+
, 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":83,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
6666
, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":13,"pressure":0.0,"pressed":false,"script":null)
6767
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":1.0,"script":null)
6868
]
6969
}
7070
start_game={
7171
"deadzone": 0.5,
72-
"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":16777221,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
72+
"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":16777221,"physical_keycode":0,"key_label":0,"unicode":0,"echo":false,"script":null)
7373
]
7474
}
7575

0 commit comments

Comments
 (0)