ajout de la porte et équilibrage des mutations
BIN
entities/interactables/door/assets/sprites/door_1.png
Normal file
|
After Width: | Height: | Size: 113 KiB |
40
entities/interactables/door/assets/sprites/door_1.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://s0bn2kt1bpkn"
|
||||
path="res://.godot/imported/door_1.png-dd51326c0be9b6ca6b377054f3b2e77d.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_1.png"
|
||||
dest_files=["res://.godot/imported/door_1.png-dd51326c0be9b6ca6b377054f3b2e77d.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_2.png
Normal file
|
After Width: | Height: | Size: 113 KiB |
40
entities/interactables/door/assets/sprites/door_2.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://bc1ab3tf6vpqy"
|
||||
path="res://.godot/imported/door_2.png-ffb500b8948b67d03b116bc31932d2e7.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_2.png"
|
||||
dest_files=["res://.godot/imported/door_2.png-ffb500b8948b67d03b116bc31932d2e7.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_3.png
Normal file
|
After Width: | Height: | Size: 109 KiB |
40
entities/interactables/door/assets/sprites/door_3.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://jmen57sr5vk4"
|
||||
path="res://.godot/imported/door_3.png-d482e5ec97272ac7dd5a7b3a5a9537ae.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_3.png"
|
||||
dest_files=["res://.godot/imported/door_3.png-d482e5ec97272ac7dd5a7b3a5a9537ae.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_4.png
Normal file
|
After Width: | Height: | Size: 105 KiB |
40
entities/interactables/door/assets/sprites/door_4.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://c5gstknno4mka"
|
||||
path="res://.godot/imported/door_4.png-3f16467270ce8b1707ea531e940f078d.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_4.png"
|
||||
dest_files=["res://.godot/imported/door_4.png-3f16467270ce8b1707ea531e940f078d.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_5.png
Normal file
|
After Width: | Height: | Size: 104 KiB |
40
entities/interactables/door/assets/sprites/door_5.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dd7jl1yyfs7l1"
|
||||
path="res://.godot/imported/door_5.png-119cfb6fd418806a8ada16cab3be9800.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_5.png"
|
||||
dest_files=["res://.godot/imported/door_5.png-119cfb6fd418806a8ada16cab3be9800.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_6.png
Normal file
|
After Width: | Height: | Size: 101 KiB |
40
entities/interactables/door/assets/sprites/door_6.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://cht54x4mugr5p"
|
||||
path="res://.godot/imported/door_6.png-e383976c062791fd56ea66dee70eef77.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_6.png"
|
||||
dest_files=["res://.godot/imported/door_6.png-e383976c062791fd56ea66dee70eef77.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_7.png
Normal file
|
After Width: | Height: | Size: 100 KiB |
40
entities/interactables/door/assets/sprites/door_7.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://1hac868r8p6j"
|
||||
path="res://.godot/imported/door_7.png-e59924662d7e8532a3fd4cd279271ad9.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_7.png"
|
||||
dest_files=["res://.godot/imported/door_7.png-e59924662d7e8532a3fd4cd279271ad9.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_8.png
Normal file
|
After Width: | Height: | Size: 98 KiB |
40
entities/interactables/door/assets/sprites/door_8.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dtyaykvtikvfx"
|
||||
path="res://.godot/imported/door_8.png-7f02c4bb4f5ac7ca8b7b1c6a36f870f5.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_8.png"
|
||||
dest_files=["res://.godot/imported/door_8.png-7f02c4bb4f5ac7ca8b7b1c6a36f870f5.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_9.png
Normal file
|
After Width: | Height: | Size: 97 KiB |
40
entities/interactables/door/assets/sprites/door_9.png.import
Normal file
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://ddmriwgrr3mj5"
|
||||
path="res://.godot/imported/door_9.png-ba922b9855fd185769933e59b1b2c98b.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_9.png"
|
||||
dest_files=["res://.godot/imported/door_9.png-ba922b9855fd185769933e59b1b2c98b.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
BIN
entities/interactables/door/assets/sprites/door_screen.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
@@ -0,0 +1,40 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dqjqwmck0rgkh"
|
||||
path="res://.godot/imported/door_screen.png-f9e60b58530d2cc65beea7b37c212496.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://entities/interactables/door/assets/sprites/door_screen.png"
|
||||
dest_files=["res://.godot/imported/door_screen.png-f9e60b58530d2cc65beea7b37c212496.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
@@ -1,22 +1,146 @@
|
||||
[gd_scene format=3 uid="uid://b8m537op75gib"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bmxuqj0c6h60d" path="res://entities/interactables/door/script/door.gd" id="1_8kdwv"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_8kdwv"]
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 1)
|
||||
|
||||
[sub_resource type="GradientTexture2D" id="GradientTexture2D_oarg0"]
|
||||
gradient = SubResource("Gradient_8kdwv")
|
||||
[ext_resource type="Texture2D" uid="uid://ddmriwgrr3mj5" path="res://entities/interactables/door/assets/sprites/door_9.png" id="2_0mw24"]
|
||||
[ext_resource type="Texture2D" uid="uid://be7ietbjlmgtt" path="res://common/icons/map-pin-empty.svg" id="2_6w4e0"]
|
||||
[ext_resource type="Texture2D" uid="uid://dtyaykvtikvfx" path="res://entities/interactables/door/assets/sprites/door_8.png" id="3_6w4e0"]
|
||||
[ext_resource type="Texture2D" uid="uid://1hac868r8p6j" path="res://entities/interactables/door/assets/sprites/door_7.png" id="4_tu3nm"]
|
||||
[ext_resource type="Texture2D" uid="uid://cht54x4mugr5p" path="res://entities/interactables/door/assets/sprites/door_6.png" id="5_wnnbj"]
|
||||
[ext_resource type="Texture2D" uid="uid://dd7jl1yyfs7l1" path="res://entities/interactables/door/assets/sprites/door_5.png" id="6_xqykn"]
|
||||
[ext_resource type="Texture2D" uid="uid://c5gstknno4mka" path="res://entities/interactables/door/assets/sprites/door_4.png" id="7_obnqv"]
|
||||
[ext_resource type="Texture2D" uid="uid://jmen57sr5vk4" path="res://entities/interactables/door/assets/sprites/door_3.png" id="8_0ctdk"]
|
||||
[ext_resource type="Texture2D" uid="uid://bc1ab3tf6vpqy" path="res://entities/interactables/door/assets/sprites/door_2.png" id="9_2jahp"]
|
||||
[ext_resource type="Texture2D" uid="uid://s0bn2kt1bpkn" path="res://entities/interactables/door/assets/sprites/door_1.png" id="10_8yes4"]
|
||||
[ext_resource type="Texture2D" uid="uid://dqjqwmck0rgkh" path="res://entities/interactables/door/assets/sprites/door_screen.png" id="12_6w4e0"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_y51rk"]
|
||||
size = Vector2(64, 64)
|
||||
size = Vector2(106, 120)
|
||||
|
||||
[sub_resource type="SpriteFrames" id="SpriteFrames_4aafg"]
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("2_0mw24")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("3_6w4e0")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("4_tu3nm")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("5_wnnbj")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("6_xqykn")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("7_obnqv")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("8_0ctdk")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("9_2jahp")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("10_8yes4")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"close",
|
||||
"speed": 20.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("10_8yes4")
|
||||
}],
|
||||
"loop": true,
|
||||
"name": &"closed",
|
||||
"speed": 5.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("10_8yes4")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("9_2jahp")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("8_0ctdk")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("7_obnqv")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("6_xqykn")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("5_wnnbj")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("4_tu3nm")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("3_6w4e0")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("2_0mw24")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"open",
|
||||
"speed": 20.0
|
||||
}, {
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": ExtResource("2_0mw24")
|
||||
}],
|
||||
"loop": false,
|
||||
"name": &"opened",
|
||||
"speed": 20.0
|
||||
}]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_tu3nm"]
|
||||
interpolation_mode = 1
|
||||
offsets = PackedFloat32Array(0, 0.91845495, 1)
|
||||
colors = PackedColorArray(0.0627451, 0.05882353, 0.16862746, 1, 0.06318334, 0.059500005, 0.17, 0, 1, 1, 1, 0)
|
||||
|
||||
[sub_resource type="GradientTexture2D" id="GradientTexture2D_wnnbj"]
|
||||
gradient = SubResource("Gradient_tu3nm")
|
||||
width = 125
|
||||
height = 126
|
||||
fill = 1
|
||||
fill_from = Vector2(0.5, 0.5)
|
||||
fill_to = Vector2(1, 0.5)
|
||||
|
||||
[node name="Door" type="Area2D" unique_id=2053096538]
|
||||
script = ExtResource("1_8kdwv")
|
||||
icon = ExtResource("2_6w4e0")
|
||||
available = false
|
||||
metadata/_custom_type_script = "uid://dyprcd68fjstf"
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="." unique_id=874210487]
|
||||
texture = SubResource("GradientTexture2D_oarg0")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="." unique_id=1809395872]
|
||||
shape = SubResource("RectangleShape2D_y51rk")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." unique_id=879120806]
|
||||
unique_name_in_owner = true
|
||||
scale = Vector2(0.33, 0.33)
|
||||
sprite_frames = SubResource("SpriteFrames_4aafg")
|
||||
animation = &"close"
|
||||
frame = 8
|
||||
frame_progress = 1.0
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="." unique_id=1875435966]
|
||||
position = Vector2(0.99999994, -41)
|
||||
scale = Vector2(0.2833334, 0.28333336)
|
||||
texture = SubResource("GradientTexture2D_wnnbj")
|
||||
|
||||
[node name="Icon" type="Sprite2D" parent="." unique_id=874210487]
|
||||
unique_name_in_owner = true
|
||||
position = Vector2(1, -42)
|
||||
scale = Vector2(0.4583333, 0.4583333)
|
||||
texture = ExtResource("2_6w4e0")
|
||||
|
||||
[node name="DoorScreen" type="Sprite2D" parent="." unique_id=236947304]
|
||||
position = Vector2(5.684342e-14, 2.2737368e-13)
|
||||
scale = Vector2(0.33, 0.33)
|
||||
texture = ExtResource("12_6w4e0")
|
||||
|
||||
@@ -3,9 +3,14 @@ extends Interactable
|
||||
class_name Door
|
||||
|
||||
@export var to_scene_id = ""
|
||||
@export var icon : Texture : set = set_icon
|
||||
|
||||
func _ready():
|
||||
modulate = Color.WHITE if available else Color.RED
|
||||
if available:
|
||||
%AnimatedSprite2D.play("opened")
|
||||
else:
|
||||
%AnimatedSprite2D.play("closed")
|
||||
set_icon()
|
||||
|
||||
func interact(_p : Player) -> bool:
|
||||
if available and to_scene_id:
|
||||
@@ -16,4 +21,14 @@ func interact(_p : Player) -> bool:
|
||||
|
||||
func set_available(v : bool):
|
||||
available = v
|
||||
modulate = Color.WHITE if available else Color.RED
|
||||
if is_node_ready():
|
||||
if available:
|
||||
AudioManager.play_sfx("DoorOpen")
|
||||
%AnimatedSprite2D.play("open")
|
||||
else:
|
||||
%AnimatedSprite2D.play("close")
|
||||
|
||||
func set_icon(i: Texture = icon):
|
||||
icon = i
|
||||
if is_node_ready():
|
||||
%Icon.texture = icon
|
||||
|
||||