sokoban
Diffstat (limited to 'Crate.tscn')
| -rw-r--r-- | Crate.tscn | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/Crate.tscn b/Crate.tscn new file mode 100644 index 0000000..077fc88 --- /dev/null +++ b/Crate.tscn @@ -0,0 +1,76 @@ +[gd_scene load_steps=7 format=2] + +[ext_resource path="res://box.png" type="Texture" id=1] +[ext_resource path="res://Box.gd" type="Script" id=2] +[ext_resource path="res://Check.png" type="Texture" id=3] +[ext_resource path="res://box_normal.png" type="Texture" id=4] + +[sub_resource type="RectangleShape2D" id=1] +extents = Vector2( 8.5, 8.5 ) + +[sub_resource type="OccluderPolygon2D" id=2] +polygon = PoolVector2Array( 0, 0, 0, 16, 16, 16, 16, 0 ) + +[node name="Crate" type="KinematicBody2D" groups=["crates"]] +script = ExtResource( 2 ) + +[node name="Crate" type="Sprite" parent="."] +light_mask = 3 +texture = ExtResource( 1 ) +normal_map = ExtResource( 4 ) +centered = false + +[node name="CheckSprite" type="Sprite" parent="."] +visible = false +light_mask = 0 +position = Vector2( 8, 8 ) +texture = ExtResource( 3 ) + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +visible = false +light_mask = 0 +position = Vector2( 8, 8 ) +shape = SubResource( 1 ) + +[node name="RayCast" type="RayCast2D" parent="."] +visible = false +position = Vector2( 8, 8 ) + +[node name="Tween" type="Tween" parent="."] + +[node name="LightOccluder2D" type="LightOccluder2D" parent="."] +visible = false +occluder = SubResource( 2 ) + +[node name="WallChecks" type="Node2D" parent="."] +visible = false + +[node name="LR" type="Node2D" parent="WallChecks"] + +[node name="Left" type="RayCast2D" parent="WallChecks/LR"] +position = Vector2( 8, 8 ) +enabled = true +cast_to = Vector2( -10, 0 ) +collision_mask = 2 + +[node name="Right" type="RayCast2D" parent="WallChecks/LR"] +position = Vector2( 8, 8 ) +enabled = true +cast_to = Vector2( 10, 0 ) +collision_mask = 2 + +[node name="DU" type="Node2D" parent="WallChecks"] + +[node name="Down" type="RayCast2D" parent="WallChecks/DU"] +position = Vector2( 8, 8 ) +enabled = true +cast_to = Vector2( 0, 10 ) +collision_mask = 2 + +[node name="Up" type="RayCast2D" parent="WallChecks/DU"] +position = Vector2( 8, 8 ) +enabled = true +cast_to = Vector2( 0, -10 ) +collision_mask = 2 + +[connection signal="tween_all_completed" from="Tween" to="." method="_on_Tween_tween_all_completed"] |