Skip to content

Commit 065a94d

Browse files
committed
Replace scenes with named classes in pong_game.tscn
https://phabricator.endlessm.com/T35545
1 parent 4223e6e commit 065a94d

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

addons/block_code/examples/pong_game/pong_game.tscn

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

33
[ext_resource type="PackedScene" uid="uid://cg8ibi18um3vg" path="res://addons/block_code/examples/pong_game/space.tscn" id="1_y56ac"]
44
[ext_resource type="Script" path="res://addons/block_code/block_code_node/block_code.gd" id="3_6jaq8"]
5-
[ext_resource type="PackedScene" uid="uid://ddx1cd5q6t61o" path="res://addons/block_code/simple_nodes/simple_character/simple_character.tscn" id="3_hjpbs"]
5+
[ext_resource type="Script" path="res://addons/block_code/simple_nodes/simple_character/simple_character.gd" id="3_mdrcv"]
66
[ext_resource type="Script" path="res://addons/block_code/ui/block_canvas/serialized_block_tree_node.gd" id="4_qtggh"]
77
[ext_resource type="Texture2D" uid="uid://tplpgtnfeda0" path="res://addons/block_code/examples/pong_game/assets/paddle.png" id="4_ra7bh"]
88
[ext_resource type="Script" path="res://addons/block_code/ui/block_canvas/serialized_block.gd" id="5_wr38c"]
99
[ext_resource type="Script" path="res://addons/block_code/ui/block_canvas/serialized_block_tree_node_array.gd" id="6_ppdc3"]
1010
[ext_resource type="Script" path="res://addons/block_code/block_script_data/block_script_data.gd" id="7_uuuue"]
11-
[ext_resource type="PackedScene" uid="uid://bis7afjjuwypq" path="res://addons/block_code/simple_nodes/simple_scoring/simple_scoring.tscn" id="8_yg457"]
1211
[ext_resource type="PackedScene" uid="uid://c7l70grmkauij" path="res://addons/block_code/examples/pong_game/ball.tscn" id="9_xrqll"]
1312
[ext_resource type="PackedScene" uid="uid://fhoapg3anjsu" path="res://addons/block_code/examples/pong_game/goal_area.tscn" id="12_nqmxu"]
13+
[ext_resource type="Script" path="res://addons/block_code/simple_nodes/simple_scoring/simple_scoring.gd" id="13_tg3yk"]
1414

1515
[sub_resource type="Resource" id="Resource_k6jw1"]
1616
script = ExtResource("5_wr38c")
@@ -796,20 +796,22 @@ version = 0
796796

797797
[node name="Space" parent="." instance=ExtResource("1_y56ac")]
798798

799-
[node name="PaddleLeft" parent="." groups=["paddles"] instance=ExtResource("3_hjpbs")]
799+
[node name="PaddleLeft" type="CharacterBody2D" parent="." groups=["paddles"]]
800800
modulate = Color(0.509804, 0.360784, 0.972549, 1)
801801
position = Vector2(64, 544)
802802
collision_mask = 5
803+
script = ExtResource("3_mdrcv")
803804
texture = ExtResource("4_ra7bh")
804805

805806
[node name="BlockCode" type="Node" parent="PaddleLeft"]
806807
script = ExtResource("3_6jaq8")
807808
block_script = SubResource("Resource_qmak3")
808809

809-
[node name="PaddleRight" parent="." groups=["paddles"] instance=ExtResource("3_hjpbs")]
810+
[node name="PaddleRight" type="CharacterBody2D" parent="." groups=["paddles"]]
810811
modulate = Color(0.509804, 0.360784, 0.972549, 1)
811812
position = Vector2(1856, 544)
812813
collision_mask = 5
814+
script = ExtResource("3_mdrcv")
813815
texture = ExtResource("4_ra7bh")
814816

815817
[node name="BlockCode" type="Node" parent="PaddleRight"]
@@ -839,8 +841,9 @@ position = Vector2(1984, 544)
839841
script = ExtResource("3_6jaq8")
840842
block_script = SubResource("Resource_6drva")
841843

842-
[node name="SimpleScoring" parent="." instance=ExtResource("8_yg457")]
844+
[node name="SimpleScoring" type="CanvasLayer" parent="." groups=["hud"]]
843845
follow_viewport_enabled = true
846+
script = ExtResource("13_tg3yk")
844847

845848
[node name="BlockCode" type="Node" parent="SimpleScoring"]
846849
script = ExtResource("3_6jaq8")

0 commit comments

Comments
 (0)