added blocking doors to paths.
This commit is contained in:
114
src/scenes/TeleporterIntoClosedRoom.tscn
Normal file
114
src/scenes/TeleporterIntoClosedRoom.tscn
Normal file
@@ -0,0 +1,114 @@
|
||||
[gd_scene format=3 uid="uid://d24xrw86pfg1s"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://b4wejvn0dfrji" path="res://scripts/teleporter_into_closed_room.gd" id="1_g3s7f"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_skeae"]
|
||||
offsets = PackedFloat32Array(0, 0.9883721)
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0)
|
||||
|
||||
[sub_resource type="GradientTexture2D" id="GradientTexture2D_g3s7f"]
|
||||
gradient = SubResource("Gradient_skeae")
|
||||
width = 32
|
||||
height = 32
|
||||
fill = 1
|
||||
fill_from = Vector2(0.4957265, 0.4871795)
|
||||
fill_to = Vector2(0.525641, 0.42307693)
|
||||
|
||||
[sub_resource type="Curve" id="Curve_7twcj"]
|
||||
_data = [Vector2(0, 1), 0.0, 0.0, 0, 0, Vector2(0.74757284, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), 0.0, 0.0, 0, 0]
|
||||
point_count = 3
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_sgnaw"]
|
||||
curve = SubResource("Curve_7twcj")
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_iemw3"]
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 1)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_paieq"]
|
||||
gradient = SubResource("Gradient_iemw3")
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_1qst8"]
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 1)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_cqcet"]
|
||||
gradient = SubResource("Gradient_1qst8")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_7kx0f"]
|
||||
_limits = [-1.0, 1.0, 0.0, 1.0]
|
||||
_data = [Vector2(0, 1), 0.0, 0.0, 0, 0, Vector2(1e-05, -0.11255813), 0.0, 0.0, 0, 0, Vector2(0.055825245, -0.43906975), 0.0, 0.0, 0, 0, Vector2(0.1553398, 0.58883727), 0.0, 0.0, 0, 0, Vector2(0.30339807, -0.2697674), 0.0, 0.0, 0, 0, Vector2(0.44902915, 0.73395354), 0.0, 0.0, 0, 0, Vector2(0.657767, -0.13674414), 0.0, 0.0, 0, 0, Vector2(0.8009709, -0.4511627), 0.0, 0.0, 0, 0]
|
||||
point_count = 8
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_g8xsh"]
|
||||
curve = SubResource("Curve_7kx0f")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_d4f27"]
|
||||
_data = [Vector2(0, 0.4134884), 0.0, 0.0, 0, 0, Vector2(0.2354369, 0.49813956), 0.0, 0.0, 0, 0, Vector2(0.4830097, 0.18976748), 0.0, 0.0, 0, 0, Vector2(0.5873787, 0.8186047), 0.0, 0.0, 0, 0, Vector2(1, 1), 0.0, 0.0, 0, 0]
|
||||
point_count = 5
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_nhcxx"]
|
||||
curve = SubResource("Curve_d4f27")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_l8b8y"]
|
||||
_limits = [0.0, 1000.0, 0.0, 1000.0]
|
||||
_data = [Vector2(0, 413.48828), 0.0, 0.0, 0, 0, Vector2(67.96117, 467.90692), 0.0, 0.0, 0, 0, Vector2(189.3204, 213.95343), 0.0, 0.0, 0, 0, Vector2(269.41748, 50.69763), 0.0, 0.0, 0, 0, Vector2(456.31067, 280.46503), 0.0, 0.0, 0, 0]
|
||||
point_count = 5
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_hd4yi"]
|
||||
curve = SubResource("Curve_l8b8y")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_n1yim"]
|
||||
particle_flag_disable_z = true
|
||||
direction = Vector3(0, -1, 0)
|
||||
spread = 6.844
|
||||
initial_velocity_min = 50.76
|
||||
initial_velocity_max = 65.99
|
||||
angular_velocity_min = -36.550014
|
||||
angular_velocity_max = 21.929983
|
||||
orbit_velocity_min = -0.77199996
|
||||
orbit_velocity_max = 0.5480001
|
||||
orbit_velocity_curve = SubResource("CurveTexture_g8xsh")
|
||||
radial_velocity_min = -2.2351742e-05
|
||||
radial_velocity_max = 101.51997
|
||||
radial_velocity_curve = SubResource("CurveTexture_nhcxx")
|
||||
velocity_limit_curve = SubResource("CurveTexture_hd4yi")
|
||||
gravity = Vector3(0, 0, 0)
|
||||
color = Color(0.61982733, 0.94004476, 1, 1)
|
||||
color_ramp = SubResource("GradientTexture1D_cqcet")
|
||||
color_initial_ramp = SubResource("GradientTexture1D_paieq")
|
||||
alpha_curve = SubResource("CurveTexture_sgnaw")
|
||||
hue_variation_min = -0.06000002
|
||||
hue_variation_max = 0.049999975
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_pp12y"]
|
||||
size = Vector2(16, 16)
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_7twcj"]
|
||||
size = Vector2(32, 32)
|
||||
|
||||
[node name="TeleporterIntoClosedRoom" type="Node2D" unique_id=1871154484]
|
||||
script = ExtResource("1_g3s7f")
|
||||
|
||||
[node name="GPUParticles2D" type="GPUParticles2D" parent="." unique_id=1725884303]
|
||||
emitting = false
|
||||
amount = 32
|
||||
texture = SubResource("GradientTexture2D_g3s7f")
|
||||
lifetime = 0.54
|
||||
randomness = 1.0
|
||||
process_material = SubResource("ParticleProcessMaterial_n1yim")
|
||||
|
||||
[node name="AreaWhichTeleportsPlayerIntoRoom" type="Area2D" parent="." unique_id=47060921]
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="AreaWhichTeleportsPlayerIntoRoom" unique_id=1803123867]
|
||||
shape = SubResource("RectangleShape2D_pp12y")
|
||||
|
||||
[node name="AreaToStartEmit" type="Area2D" parent="." unique_id=1219098269]
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="AreaToStartEmit" unique_id=700191159]
|
||||
shape = SubResource("RectangleShape2D_7twcj")
|
||||
debug_color = Color(0.6530463, 0.21585448, 0.70196074, 0.41960785)
|
||||
|
||||
[connection signal="body_entered" from="AreaWhichTeleportsPlayerIntoRoom" to="." method="_on_area_which_teleports_player_into_room_body_entered"]
|
||||
[connection signal="body_entered" from="AreaToStartEmit" to="." method="_on_area_to_start_emit_body_entered"]
|
||||
[connection signal="body_exited" from="AreaToStartEmit" to="." method="_on_area_to_start_emit_body_exited"]
|
||||
@@ -2,8 +2,10 @@
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://cckiqfs0kwuuh" path="res://assets/gfx/door_barred.png" id="1_hpvv5"]
|
||||
[ext_resource type="Script" uid="uid://do4062ppepheo" path="res://scripts/door.gd" id="1_uvdjg"]
|
||||
[ext_resource type="PackedScene" uid="uid://d24xrw86pfg1s" path="res://scenes/TeleporterIntoClosedRoom.tscn" id="2_q5w8r"]
|
||||
[ext_resource type="AudioStream" uid="uid://dfolu80c534j4" path="res://assets/audio/sfx/environment/keydoor/unlock.mp3" id="3_la1wf"]
|
||||
[ext_resource type="AudioStream" uid="uid://2w73l4k3704x" path="res://assets/audio/sfx/environment/pot/pot_drag1.mp3" id="4_18pbm"]
|
||||
[ext_resource type="AudioStream" uid="uid://c6bp156a5ggdf" path="res://assets/audio/sfx/environment/keydoor/door_closes.mp3" id="5_18pbm"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_uvdjg"]
|
||||
size = Vector2(26, 14)
|
||||
@@ -15,6 +17,9 @@ size = Vector2(22, 18)
|
||||
collision_layer = 64
|
||||
script = ExtResource("1_uvdjg")
|
||||
|
||||
[node name="TeleporterIntoClosedRoom" parent="." unique_id=1871154484 instance=ExtResource("2_q5w8r")]
|
||||
position = Vector2(0, -16)
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="." unique_id=1520856168]
|
||||
texture = ExtResource("1_hpvv5")
|
||||
|
||||
@@ -35,3 +40,8 @@ stream = ExtResource("4_18pbm")
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="KeyInteractionArea" unique_id=1640987231]
|
||||
shape = SubResource("RectangleShape2D_la1wf")
|
||||
debug_color = Color(0.70196074, 0.67558956, 0.17869899, 0.41960785)
|
||||
|
||||
[node name="SfxDoorCloses" type="AudioStreamPlayer2D" parent="." unique_id=1074871158]
|
||||
stream = ExtResource("5_18pbm")
|
||||
max_distance = 1333.0
|
||||
attenuation = 5.8563395
|
||||
|
||||
43
src/scenes/door.tscn3989767106.tmp
Normal file
43
src/scenes/door.tscn3989767106.tmp
Normal file
@@ -0,0 +1,43 @@
|
||||
[gd_scene format=3 uid="uid://02opigrv0qff"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://cckiqfs0kwuuh" path="res://assets/gfx/door_barred.png" id="1_hpvv5"]
|
||||
[ext_resource type="Script" uid="uid://do4062ppepheo" path="res://scripts/door.gd" id="1_uvdjg"]
|
||||
[ext_resource type="AudioStream" uid="uid://dfolu80c534j4" path="res://assets/audio/sfx/environment/keydoor/unlock.mp3" id="3_la1wf"]
|
||||
[ext_resource type="AudioStream" uid="uid://2w73l4k3704x" path="res://assets/audio/sfx/environment/pot/pot_drag1.mp3" id="4_18pbm"]
|
||||
[ext_resource type="AudioStream" uid="uid://c6bp156a5ggdf" path="res://assets/audio/sfx/environment/keydoor/door_closes.mp3" id="5_18pbm"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_uvdjg"]
|
||||
size = Vector2(26, 14)
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_la1wf"]
|
||||
size = Vector2(22, 18)
|
||||
|
||||
[node name="Door" type="StaticBody2D" unique_id=371155975]
|
||||
collision_layer = 64
|
||||
script = ExtResource("1_uvdjg")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="." unique_id=1520856168]
|
||||
texture = ExtResource("1_hpvv5")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="." unique_id=1691515105]
|
||||
shape = SubResource("RectangleShape2D_uvdjg")
|
||||
|
||||
[node name="SfxOpenKeyDoor" type="AudioStreamPlayer2D" parent="." unique_id=47303726]
|
||||
stream = ExtResource("3_la1wf")
|
||||
|
||||
[node name="SfxOpenStoneDoor" type="AudioStreamPlayer2D" parent="." unique_id=885417421]
|
||||
stream = ExtResource("4_18pbm")
|
||||
|
||||
[node name="SfxOpenGateDoor" type="AudioStreamPlayer2D" parent="." unique_id=442358170]
|
||||
stream = ExtResource("4_18pbm")
|
||||
|
||||
[node name="KeyInteractionArea" type="Area2D" parent="." unique_id=982067740]
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="KeyInteractionArea" unique_id=1640987231]
|
||||
shape = SubResource("RectangleShape2D_la1wf")
|
||||
debug_color = Color(0.70196074, 0.67558956, 0.17869899, 0.41960785)
|
||||
|
||||
[node name="SfxDoorCloses" type="AudioStreamPlayer2D" parent="." unique_id=1074871158]
|
||||
stream = ExtResource("5_18pbm")
|
||||
max_distance = 1333.0
|
||||
attenuation = 5.8563395
|
||||
@@ -1,14 +1,24 @@
|
||||
[gd_scene format=3 uid="uid://floating_text"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/floating_text.gd" id="1"]
|
||||
[ext_resource type="FontFile" uid="uid://cbmcfue0ek0tk" path="res://assets/fonts/dmg_numbers.png" id="2_dmg_font"]
|
||||
|
||||
[sub_resource type="Theme" id="Theme_floating_text"]
|
||||
default_font = ExtResource("2_dmg_font")
|
||||
default_font_size = 12
|
||||
|
||||
[node name="FloatingText" type="Node2D"]
|
||||
script = ExtResource("1")
|
||||
|
||||
[node name="ItemSprite" type="Sprite2D" parent="."]
|
||||
visible = false
|
||||
offset = Vector2(0, -20)
|
||||
scale = Vector2(1, 1)
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
offset_right = 64.0
|
||||
offset_bottom = 24.0
|
||||
theme_override_font_sizes/font_size = 18
|
||||
theme = SubResource("Theme_floating_text")
|
||||
text = "+1 coin"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
[ext_resource type="Script" uid="uid://bax7e73v836nx" path="res://scripts/player_manager.gd" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://cxfvw8y7jqn2p" path="res://scenes/player.tscn" id="2"]
|
||||
[ext_resource type="PackedScene" uid="uid://b7qx8y2jqn3r" path="res://scenes/interactable_object.tscn" id="3"]
|
||||
[ext_resource type="Script" uid="uid://db58xcyo4cjk" path="res://scripts/game_world.gd" id="4"]
|
||||
[ext_resource type="Script" uid="uid://wff5063ctp7g" path="res://scripts/debug_overlay.gd" id="5"]
|
||||
[ext_resource type="TileSet" uid="uid://dqem5tbvooxrg" path="res://assets/gfx/RPG DUNGEON VOL 3.tres" id="9"]
|
||||
@@ -28,46 +27,9 @@ modulate = Color(1, 1, 1, 0.77254903)
|
||||
z_index = 1
|
||||
tile_set = ExtResource("9")
|
||||
|
||||
[node name="Floor" type="Polygon2D" parent="Environment" unique_id=1715441485]
|
||||
visible = false
|
||||
color = Color(0.3, 0.3, 0.3, 1)
|
||||
polygon = PackedVector2Array(-1000, -1000, 1000, -1000, 1000, 1000, -1000, 1000)
|
||||
metadata/_edit_lock_ = true
|
||||
|
||||
[node name="Walls" type="StaticBody2D" parent="Environment" unique_id=336033150]
|
||||
collision_layer = 4
|
||||
collision_mask = 3
|
||||
|
||||
[node name="WallTop" type="CollisionPolygon2D" parent="Environment/Walls" unique_id=1311846641]
|
||||
polygon = PackedVector2Array(-1020, -1020, 1020, -1020, 1020, -980, -1020, -980)
|
||||
|
||||
[node name="WallBottom" type="CollisionPolygon2D" parent="Environment/Walls" unique_id=902776066]
|
||||
polygon = PackedVector2Array(-1020, 980, 1020, 980, 1020, 1020, -1020, 1020)
|
||||
|
||||
[node name="WallLeft" type="CollisionPolygon2D" parent="Environment/Walls" unique_id=1762713816]
|
||||
polygon = PackedVector2Array(-1020, -980, -980, -980, -980, 980, -1020, 980)
|
||||
|
||||
[node name="WallRight" type="CollisionPolygon2D" parent="Environment/Walls" unique_id=540990153]
|
||||
polygon = PackedVector2Array(980, -980, 1020, -980, 1020, 980, 980, 980)
|
||||
|
||||
[node name="Entities" type="Node2D" parent="." unique_id=1447395523]
|
||||
y_sort_enabled = true
|
||||
|
||||
[node name="Box1" parent="Entities" unique_id=2016646819 instance=ExtResource("3")]
|
||||
position = Vector2(101, 66)
|
||||
|
||||
[node name="Box2" parent="Entities" unique_id=219568153 instance=ExtResource("3")]
|
||||
position = Vector2(100, 133)
|
||||
|
||||
[node name="Box3" parent="Entities" unique_id=1831798906 instance=ExtResource("3")]
|
||||
position = Vector2(113, 9)
|
||||
|
||||
[node name="Box4" parent="Entities" unique_id=140447274 instance=ExtResource("3")]
|
||||
position = Vector2(198, 58)
|
||||
|
||||
[node name="Box5" parent="Entities" unique_id=284709248 instance=ExtResource("3")]
|
||||
position = Vector2(74, 12)
|
||||
|
||||
[node name="DebugOverlay" type="CanvasLayer" parent="." unique_id=1325005956]
|
||||
script = ExtResource("5")
|
||||
|
||||
|
||||
@@ -1,14 +1,12 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://bqvx8y2jqn4s"]
|
||||
[gd_scene format=3 uid="uid://bqvx8y2jqn4s"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/smoke_puff.gd" id="1_puff"]
|
||||
[ext_resource type="Script" uid="uid://px6532483e6t" path="res://scripts/smoke_puff.gd" id="1_puff"]
|
||||
[ext_resource type="Texture2D" uid="uid://bknascfv4twmi" path="res://assets/gfx/smoke_puffs.png" id="2_smoke"]
|
||||
|
||||
[node name="SmokePuff" type="Node2D"]
|
||||
[node name="SmokePuff" type="Node2D" unique_id=243995580]
|
||||
script = ExtResource("1_puff")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
[node name="Sprite2D" type="Sprite2D" parent="." unique_id=1282738570]
|
||||
texture = ExtResource("2_smoke")
|
||||
hframes = 4
|
||||
vframes = 2
|
||||
frame = 0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user