diff --git a/addons/property-inspector/pro_animation_sprite2d/pro_animated_sprite.gd b/addons/property-inspector/pro_animation_sprite2d/pro_animated_sprite.gd index 417b3af2..cd633332 100644 --- a/addons/property-inspector/pro_animation_sprite2d/pro_animated_sprite.gd +++ b/addons/property-inspector/pro_animation_sprite2d/pro_animated_sprite.gd @@ -1,6 +1,8 @@ @tool class_name ProAnimatedSprite2D extends AnimatedSprite2D +signal position_updated(global_pos: Vector2) + @export var autostart := true @export var action_configs: Array[Dictionary] = [] @export var move_configs: Array[Dictionary] = [] @@ -92,7 +94,7 @@ func _debug_mov_projection(): # 展示 accumulated animation 的目标位置 debug_mov_onion_sprite2d.position.x = ( mov_config.movement_x * (-1 if flip_h else 1) / scale.x - ) + ) * sign(mov_config.velocity.x) debug_mov_onion_sprite2d.texture = sprite_frames.get_frame_texture(debug_mov_animation, 0) debug_mov_onion_sprite2d.flip_h = flip_h elif debug_mov_animation: @@ -190,12 +192,12 @@ func _physics_process(delta: float) -> void: "切换 animation:", mov_x_next_animation, " accumulated_mov_x=", accumulated_mov_x ) play(mov_x_next_animation) - if not velocity.y: - return - if flip_v: - position.y -= velocity.y * delta - else: - position.y += velocity.y * delta + if velocity.y: + if flip_v: + position.y -= velocity.y * delta + else: + position.y += velocity.y * delta + position_updated.emit(global_position) # temporary set velocity diff --git a/asset/art/gif/c03_二楼/c03_二楼_frames.tres b/asset/art/gif/c03_二楼/c03_二楼_frames.tres index 9897bc81..d0bc124a 100644 --- a/asset/art/gif/c03_二楼/c03_二楼_frames.tres +++ b/asset/art/gif/c03_二楼/c03_二楼_frames.tres @@ -1,31 +1,31 @@ [gd_resource type="SpriteFrames" load_steps=19 format=3 uid="uid://cee76qwjhw268"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_偷听呼吸/0.png" id="1_hl1q0"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/0.png" id="1_lfyu7"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/1.png" id="2_53eth"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_偷听呼吸/1.png" id="2_g7758"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/2.png" id="3_ednhc"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/3.png" id="4_4e7e3"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/4.png" id="5_omgqx"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/5.png" id="6_gjyqo"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/6.png" id="7_mwxuw"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/7.png" id="8_2tm2e"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/0.png" id="11_mdlpw"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/1.png" id="12_matei"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/2.png" id="13_iu8u1"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/3.png" id="14_pjp2a"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/4.png" id="15_s740e"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/5.png" id="16_nij6e"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/6.png" id="17_rgha8"] -[ext_resource type="Texture2D" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/7.png" id="18_7aqib"] +[ext_resource type="Texture2D" uid="uid://04c3avsip8pq" path="res://asset/art/gif/c03_二楼/疯子_偷听呼吸/0.png" id="1_hl1q0"] +[ext_resource type="Texture2D" uid="uid://cvjlhycvn8jwy" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/0.png" id="1_lfyu7"] +[ext_resource type="Texture2D" uid="uid://dhdeexnsttj48" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/1.png" id="2_53eth"] +[ext_resource type="Texture2D" uid="uid://c7760r5k4mr8" path="res://asset/art/gif/c03_二楼/疯子_偷听呼吸/1.png" id="2_g7758"] +[ext_resource type="Texture2D" uid="uid://dka38neh5tv6e" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/2.png" id="3_ednhc"] +[ext_resource type="Texture2D" uid="uid://d23y4gduqm30m" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/3.png" id="4_4e7e3"] +[ext_resource type="Texture2D" uid="uid://dti2lkk20j32p" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/4.png" id="5_omgqx"] +[ext_resource type="Texture2D" uid="uid://cppfk3uoblr38" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/5.png" id="6_gjyqo"] +[ext_resource type="Texture2D" uid="uid://hw6ltmxjnker" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/6.png" id="7_mwxuw"] +[ext_resource type="Texture2D" uid="uid://boipydm7o1c3l" path="res://asset/art/gif/c03_二楼/疯子_慌张跑开/7.png" id="8_2tm2e"] +[ext_resource type="Texture2D" uid="uid://dj6hlax6dhe2u" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/0.png" id="11_mdlpw"] +[ext_resource type="Texture2D" uid="uid://dw8g3eop55vtp" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/1.png" id="12_matei"] +[ext_resource type="Texture2D" uid="uid://b20v56d2cijjc" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/2.png" id="13_iu8u1"] +[ext_resource type="Texture2D" uid="uid://dfd7od52nh3mm" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/3.png" id="14_pjp2a"] +[ext_resource type="Texture2D" uid="uid://x7qlausaja31" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/4.png" id="15_s740e"] +[ext_resource type="Texture2D" uid="uid://tq0a7n85gt7k" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/5.png" id="16_nij6e"] +[ext_resource type="Texture2D" uid="uid://ddmjdhfcjefvt" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/6.png" id="17_rgha8"] +[ext_resource type="Texture2D" uid="uid://b14h0rdu2ucjh" path="res://asset/art/gif/c03_二楼/疯子_慌张转身/7.png" id="18_7aqib"] [resource] animations = [{ "frames": [{ -"duration": 30.0, +"duration": 18.0, "texture": ExtResource("1_hl1q0") }, { -"duration": 30.0, +"duration": 18.0, "texture": ExtResource("2_g7758") }], "loop": true, @@ -86,7 +86,7 @@ animations = [{ "duration": 6.0, "texture": ExtResource("18_7aqib") }], -"loop": true, +"loop": false, "name": &"疯子_慌张转身", "speed": 30.0 }] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png.import similarity index 68% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png.import index f0cfebd2..583d1a0c 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://c12xhretrdxs6" -path="res://.godot/imported/1大头.png-9bf48f22cf97b3de8c6ad2db9604d1b8.ctex" +path="res://.godot/imported/1大头.png-f46c28640f53536755bc177bb0394203.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/1大头.png" -dest_files=["res://.godot/imported/1大头.png-9bf48f22cf97b3de8c6ad2db9604d1b8.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png" +dest_files=["res://.godot/imported/1大头.png-f46c28640f53536755bc177bb0394203.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png.import similarity index 66% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png.import index 0953b802..82c884c9 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://bmsm01xyej06f" -path="res://.godot/imported/1大头带纸钱.png-4e41de5a5e7a11b813287a2cd2f93a03.ctex" +path="res://.godot/imported/1大头带纸钱.png-a7b998297a8e3123c9eacc5da81786f8.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/1大头带纸钱.png" -dest_files=["res://.godot/imported/1大头带纸钱.png-4e41de5a5e7a11b813287a2cd2f93a03.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头带纸钱.png" +dest_files=["res://.godot/imported/1大头带纸钱.png-a7b998297a8e3123c9eacc5da81786f8.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png.import similarity index 67% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png.import index 0d31be8c..6bcebbe9 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://cpri1f3b2blfw" -path="res://.godot/imported/1辫子散开.png-6b5a42c136b25c3d1764773b682def1e.ctex" +path="res://.godot/imported/1辫子散开.png-c1151ab4a1a7cec13310afb9577d8f3e.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子散开.png" -dest_files=["res://.godot/imported/1辫子散开.png-6b5a42c136b25c3d1764773b682def1e.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子散开.png" +dest_files=["res://.godot/imported/1辫子散开.png-c1151ab4a1a7cec13310afb9577d8f3e.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png.import similarity index 66% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png.import index dea62243..fdde9319 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://cxlwpf82sqc8p" -path="res://.godot/imported/1辫子没剪开.png-5f8c9bf6b06eecdbb61a9ac086051a20.ctex" +path="res://.godot/imported/1辫子没剪开.png-ccf05d92a94d8f170f5d28c6ede9a232.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/1辫子没剪开.png" -dest_files=["res://.godot/imported/1辫子没剪开.png-5f8c9bf6b06eecdbb61a9ac086051a20.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png" +dest_files=["res://.godot/imported/1辫子没剪开.png-ccf05d92a94d8f170f5d28c6ede9a232.ctex"] [params] diff --git a/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png new file mode 100644 index 00000000..a1ab4761 Binary files /dev/null and b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png differ diff --git a/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png.import new file mode 100644 index 00000000..cc12804d --- /dev/null +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cqrc7v5lg2cey" +path="res://.godot/imported/l_辫子.png-216f20c5048db71aa405fa33859462f2.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png" +dest_files=["res://.godot/imported/l_辫子.png-216f20c5048db71aa405fa33859462f2.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png.import similarity index 67% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png.import index f95bf94b..c22e8701 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://ypl41mx0etds" -path="res://.godot/imported/伤口 拷贝.png-de4bb1865b2db67835fb4800c8c5e226.ctex" +path="res://.godot/imported/伤口.png-1781314ac218b57a49cf241467850104.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/伤口 拷贝.png" -dest_files=["res://.godot/imported/伤口 拷贝.png-de4bb1865b2db67835fb4800c8c5e226.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口.png" +dest_files=["res://.godot/imported/伤口.png-1781314ac218b57a49cf241467850104.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png.import similarity index 68% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png.import index d02d72a2..e1afd6ef 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://doqxrw48g45iy" -path="res://.godot/imported/1伤口.png-ffc877bfab97fdb6a42e59dcd79acb1c.ctex" +path="res://.godot/imported/伤口_头.png-64373a06a959c6c11d32f5421584beac.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/1伤口.png" -dest_files=["res://.godot/imported/1伤口.png-ffc877bfab97fdb6a42e59dcd79acb1c.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png" +dest_files=["res://.godot/imported/伤口_头.png-64373a06a959c6c11d32f5421584beac.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png.import similarity index 66% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png.import index f134fc29..18ae70d9 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://dfxbi6wc0dneu" -path="res://.godot/imported/头 啥也没有.png-aae458c474bf37ec30d422e2dd353ae9.ctex" +path="res://.godot/imported/头 啥也没有.png-44a502a439e26d916215e1a5cbe16ad7.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/头 啥也没有.png" -dest_files=["res://.godot/imported/头 啥也没有.png-aae458c474bf37ec30d422e2dd353ae9.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/头 啥也没有.png" +dest_files=["res://.godot/imported/头 啥也没有.png-44a502a439e26d916215e1a5cbe16ad7.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png.import similarity index 69% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png.import index 174906a6..f19a1441 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://4d5q3fxuras4" -path="res://.godot/imported/暗角.png-d72c30c0f8eb21bec4b5af0e7406c66c.ctex" +path="res://.godot/imported/暗角.png-3b319fe81112ffb2c4c6afec1a279f0e.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/暗角.png" -dest_files=["res://.godot/imported/暗角.png-d72c30c0f8eb21bec4b5af0e7406c66c.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/暗角.png" +dest_files=["res://.godot/imported/暗角.png-3b319fe81112ffb2c4c6afec1a279f0e.ctex"] [params] diff --git a/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png new file mode 100644 index 00000000..cd1626d5 Binary files /dev/null and b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png differ diff --git a/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png.import new file mode 100644 index 00000000..75a570a5 --- /dev/null +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://vyuf0wekr1lq" +path="res://.godot/imported/纸钱1.png-6d34bbdbd0d1aed397602346c93f6eee.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png" +dest_files=["res://.godot/imported/纸钱1.png-6d34bbdbd0d1aed397602346c93f6eee.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png new file mode 100644 index 00000000..49b2d628 Binary files /dev/null and b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png differ diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png.import similarity index 68% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png.import index acd14200..e1657a87 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://fspvmlydy3hu" -path="res://.godot/imported/纸钱.png-8c6a0daa0fc84a0699dc0020881fd00e.ctex" +path="res://.godot/imported/纸钱2.png-e7126dc5afe987c434e7bd5253ba59ea.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png" -dest_files=["res://.godot/imported/纸钱.png-8c6a0daa0fc84a0699dc0020881fd00e.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png" +dest_files=["res://.godot/imported/纸钱2.png-e7126dc5afe987c434e7bd5253ba59ea.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png.import similarity index 69% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png.import index 29485af9..e5989a4b 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://e88x3ihvhetd" -path="res://.godot/imported/背景.png-32b0cd4a2309982fdc7e08dcfffac353.ctex" +path="res://.godot/imported/背景.png-17ce3b0644368ec78ce2cec84f600657.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/背景.png" -dest_files=["res://.godot/imported/背景.png-32b0cd4a2309982fdc7e08dcfffac353.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png" +dest_files=["res://.godot/imported/背景.png-17ce3b0644368ec78ce2cec84f600657.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png.import similarity index 69% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png.import index 6a8ba13d..d381a8b4 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://7l54efft1woi" -path="res://.godot/imported/衣服.png-f388e4f1aec2fcd5913256005513e5e4.ctex" +path="res://.godot/imported/衣服.png-e26a610dc9bbd343a00b751db86ace8b.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/衣服.png" -dest_files=["res://.godot/imported/衣服.png-f388e4f1aec2fcd5913256005513e5e4.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/衣服.png" +dest_files=["res://.godot/imported/衣服.png-e26a610dc9bbd343a00b751db86ace8b.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png.import similarity index 69% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png.import index 0a37458b..15c23bf5 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://rmtxmnx7afo" -path="res://.godot/imported/辫子.png-4f8711c047b7b233ddd4d6574cc9a08a.ctex" +path="res://.godot/imported/辫子.png-4d1a30565d97a54c828b52227b8f5032.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/辫子.png" -dest_files=["res://.godot/imported/辫子.png-4f8711c047b7b233ddd4d6574cc9a08a.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子.png" +dest_files=["res://.godot/imported/辫子.png-4d1a30565d97a54c828b52227b8f5032.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png similarity index 100% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png.import b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png.import similarity index 67% rename from asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png.import rename to asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png.import index 07aa9464..90d69253 100644 --- a/asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png.import +++ b/asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://b7s25rgph0111" -path="res://.godot/imported/辫子散了.png-23b1e50baccf99f80c9f8e682109fd3b.ctex" +path="res://.godot/imported/辫子散了.png-35cea3e4ff77e533b3823de366d926b4.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://asset/art/scene/c03/s04_李癞房间/癞子特写/辫子散了.png" -dest_files=["res://.godot/imported/辫子散了.png-23b1e50baccf99f80c9f8e682109fd3b.ctex"] +source_file="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png" +dest_files=["res://.godot/imported/辫子散了.png-35cea3e4ff77e533b3823de366d926b4.ctex"] [params] diff --git a/asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png b/asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png deleted file mode 100644 index 1167ae29..00000000 Binary files a/asset/art/scene/c03/s04_李癞房间/癞子特写/纸钱.png and /dev/null differ diff --git a/asset/dialogue/event_stage.dialogue b/asset/dialogue/event_stage.dialogue index a8fbde96..7a301ca2 100644 --- a/asset/dialogue/event_stage.dialogue +++ b/asset/dialogue/event_stage.dialogue @@ -11,7 +11,8 @@ c02_ball_game_stage: 0:初始化 1:寻找弹珠_老虎钳可以换弹珠 2:给 ~ EventStage_c03 c03_s01_meat_put: 0:初始化 1:已放肉 -c03_invite_xchan_supper: 0:初始化 1:已偷听_需邀请 2:已完成邀请 +c03_invite_xchan_supper: 0:初始化 1:已偷听_需邀请 2:完成邀请 +c03_laizi_braid: 0:初始化 1:已使用剪刀 2:已剪下 c03_before_mahjong_game: 0:初始化 1:粘舌头和刀把 2:给药 4:准备好进入游戏 c03_mahjong_game: 0::麻将理牌 1:麻将出千 2:麻将结束 3:演出结束 => END diff --git a/asset/dialogue/item_description.csv b/asset/dialogue/item_description.csv index 0cd28dbe..f612ca7a 100644 --- a/asset/dialogue/item_description.csv +++ b/asset/dialogue/item_description.csv @@ -33,6 +33,7 @@ ui_notify_mem_update,回忆已更新,,,,,Memories updated ui_center_notify_press_e_to_interact,按 E 可与场景互动,,,,,Press E to interact ui_center_notify_press_q_to_exit,按 Q 可退出,,,,,Press Q to exit ui_center_notify_use_prop,按 E 使用道具,,,,,Press E to use item +ui_center_notify_lack_of_prop,缺少道具,,,,, ui_center_notify_check_note,按 N 查看线索笔记,,,,,Press N to check clue notes ui_center_notify_check_bag,按 B 查看重要物品,,,,,Press B to check important items ui_center_notify_right_click_prop,右键点击可检阅道具,,,,,Right-click to examine item @@ -117,6 +118,12 @@ prop_药包,药包,,,[#texture=c03/药包.png][#inspect=c03/ux_药包.png],, prop_药包_说明,说明,,,,, prop_菜刀,菜刀,,,[#texture=c03/菜刀.png][#inspect=c03/ux_菜刀.png],, prop_菜刀_说明,说明,,,,, +prop_1015钥匙,1015钥匙,,,[#texture=c03/1015钥匙.png],, +prop_1015钥匙_说明,说明,,,,, +prop_2013钥匙,2013钥匙,,,[#texture=c03/2013钥匙.png],, +prop_2013钥匙_说明,说明,,,,, +prop_胖子的钥匙,胖子的钥匙,,,[#texture=c03/胖子的钥匙.png],, +prop_胖子的钥匙_说明,说明,,,,, prop_院长的信,院长的信,,,[#texture=c01/院长的信物品.png][#inspect=c01/院长的信.png],,Director's Letter prop_院长的信_说明,小萍:{br}你现下境况如何?{br}你虽离开浦育院已久,但我始终没有忘记为你祈祷。{br}愿上帝保佑你走向真正光明的道路。我相信这也是当年你父亲将你托付给我时的殷切愿景。{br}你既已成人,无论你的父母出于何种理由选择与你分离,你都应当拥有知晓真相的权利,所以我将公寓地址附在了信后,除此之外,我亦知之甚少。{br}若有闲暇,欢迎你回浦育院看看。{br}院长童玉君{br}民国二十一年十月十五日{br}公寓地址 芦昌路26弄3号,,,,,"Xiao Ping:{br}How are you faring now?{br}Though you left Puyu Orphanage long ago, I have never forgotten to pray for you.{br}May God bless you to walk the path of true enlightenment. I believe this was also your father's earnest wish when he entrusted you to my care.{br}Now that you are grown, regardless of whatever reasons your parents had for separating from you, you deserve the right to know the truth. I have attached the apartment address to this letter, though I know little beyond this.{br}If you have time, you are welcome to visit Puyu Orphanage.{br}Director Tong Yujun{br}October 15th, Year 21 of the Republic{br}Apartment Address: No. 3, Lane 26, Luchang Road" prop_船票,船票,,,[#texture=c02/船票.png],,Boat Ticket diff --git a/asset/dialogue/item_description.dialogue b/asset/dialogue/item_description.dialogue index 06445740..95f0ad85 100644 --- a/asset/dialogue/item_description.dialogue +++ b/asset/dialogue/item_description.dialogue @@ -41,6 +41,7 @@ 按 E 可与场景互动 [ID:ui_center_notify_press_e_to_interact] 按 Q 可退出 [ID:ui_center_notify_press_q_to_exit] 按 E 使用道具 [ID:ui_center_notify_use_prop] +缺少道具 [ID:ui_center_notify_lack_of_prop] 按 N 查看线索笔记 [ID:ui_center_notify_check_note] 按 B 查看重要物品 [ID:ui_center_notify_check_bag] 右键点击可检阅道具 [ID:ui_center_notify_right_click_prop] diff --git a/manager/event_manager/event_binder.gd b/manager/event_manager/event_binder.gd index b3ab2bb8..091af96b 100644 --- a/manager/event_manager/event_binder.gd +++ b/manager/event_manager/event_binder.gd @@ -45,7 +45,7 @@ class_name EventBinder extends Node if is_node_ready() and Engine.is_editor_hint(): _auto_memo() @export_tool_button("AutoDetectMode") var trigger_auto_detect_mode := _auto_detect_mode -@export_enum("none", "interacted", "triggered", "played") var trigger_mode := "none": +@export_enum("none", "interacted", "triggered", "picked", "played") var trigger_mode := "none": set(val): if trigger_mode != val: trigger_mode = val @@ -83,15 +83,11 @@ func _ready() -> void: EventManager.stage_updated.connect(_on_global_stage_updated) if not trigger_event.is_empty(): # connect trigger_mode signal - if trigger_mode == "interacted": - parent.interacted.connect(_on_happened) - elif trigger_mode == "triggered": - parent.triggered.connect(_on_happened) - elif trigger_mode == "played": - parent.played.connect(_on_happened) + if trigger_mode != "none": + parent.connect(trigger_mode, _on_happened) -func _on_happened() -> void: +func _on_happened(_arg = null) -> void: if trigger_set_stage_if_greater: var updated = EventManager.set_stage_if_greater(trigger_event, trigger_stage) if not updated: @@ -156,6 +152,8 @@ func _auto_detect_mode(): trigger_mode = "interacted" elif parent.has_signal("triggered"): trigger_mode = "triggered" + elif parent.has_signal("picked"): + trigger_mode = "picked" elif parent.has_signal("played"): trigger_mode = "played" else: diff --git a/manager/event_manager/event_manager.gd b/manager/event_manager/event_manager.gd index 13aaee96..01dcdab7 100644 --- a/manager/event_manager/event_manager.gd +++ b/manager/event_manager/event_manager.gd @@ -52,10 +52,13 @@ func set_stage_if_greater(event_name: StringName, stage := 1) -> bool: # stage 最大 99999 -func next_staged(event_name: StringName, stage_max := 99999) -> void: +func next_stage(event_name: StringName, stage_max := 99999) -> int: var current_stage = get_stage(event_name) if current_stage < stage_max: - set_stage(event_name, current_stage + 1) + var stage = current_stage + 1 + set_stage(event_name, stage) + return stage + return stage_max ##### 其他事件 ##### @@ -89,7 +92,7 @@ func get_event_stage_map_array(event_name: StringName) -> PackedStringArray: var e_name = line.character if line_text.begins_with("#"): continue - #c03_invite_xchan_supper: 0:未开始 1:已偷听,需邀请 2:已完成邀请 + #xxxx: 0:未开始 1:已偷听,需邀请 2:已完成邀请 var parts = line_text.split(" ") var stages = PackedStringArray() for id in range(0, len(parts)): diff --git a/manager/scene/global_functor.gd b/manager/scene/global_functor.gd index e2ed6695..7b468390 100644 --- a/manager/scene/global_functor.gd +++ b/manager/scene/global_functor.gd @@ -59,7 +59,9 @@ func _on_c02_fire_count_down_timeout(): SceneManager.pop_debug_dialog_info("音效", "【重开】霸凌救小蝉倒计时") c02_fire_count_down_timer.stop() AudioManager.stop_bgm_music("霸凌救小蝉倒计时") - DialogueManager.show_dialogue_balloon(dialogue_c02, "c02_未完成拯救小蝉的游戏", [GlobalConfig.DIALOG_IGNORE_INPUT]) + DialogueManager.show_dialogue_balloon( + dialogue_c02, "c02_未完成拯救小蝉的游戏", [GlobalConfig.DIALOG_IGNORE_INPUT] + ) await Util.wait(1.0) SceneManager.show_black_hand(true, 0.5) await Util.wait(3) @@ -78,3 +80,22 @@ func c02_fire_count_down_stop(): c02_fire_count_down_timer.stop() # 停止音效 AudioManager.stop_bgm_music("霸凌救小蝉倒计时") + + +# 获得三张纸钱,在理发店癞子纸人身上获得两张,药车李氏纸人一张 +func c03_get_paper_coin(_node = null) -> bool: + var stage = EventManager.next_stage("c03_paper_coin") + if stage == 1: + SceneManager.enable_prop_item("prop_纸铜钱1") + return true + elif stage == 2: + SceneManager.disable_prop_item("prop_纸铜钱1") + SceneManager.enable_prop_item("prop_2个纸铜钱") + return true + elif stage == 3: + SceneManager.disable_prop_item("prop_2个纸铜钱") + SceneManager.enable_prop_item("prop_3个纸铜钱") + return true + else: + printerr("c03_get_paper_coin: stage should not be greater than 3, but got %d" % stage) + return false diff --git a/scene/entity/ux/hover_light_click_area.gd b/scene/entity/ux/hover_light_click_area.gd index c9872369..07c02416 100644 --- a/scene/entity/ux/hover_light_click_area.gd +++ b/scene/entity/ux/hover_light_click_area.gd @@ -83,8 +83,8 @@ func _input(event: InputEvent) -> void: return if event is InputEventMouseButton: if event.button_index == MOUSE_BUTTON_LEFT and event.pressed: - # get_viewport().set_input_as_handled() if is_focused(): + get_viewport().set_input_as_handled() interacted.emit() diff --git a/scene/ground/scene/c02/s06_二楼.gd b/scene/ground/scene/c02/s06_二楼.gd index b42495b8..b41603f3 100644 --- a/scene/ground/scene/c02/s06_二楼.gd +++ b/scene/ground/scene/c02/s06_二楼.gd @@ -59,11 +59,13 @@ func _on_ground_ready() -> void: if ArchiveManager.get_global_value(&"c02_the_blind_room_unlocked") and EventManager.get_chapter_stage() < 3: the_blind_bedroom_portal.status = "opened" - if EventManager.get_chapter_stage() >= 3: - # 第二章,不通往瞎子新卧室,而是先去理发店 + #c03_invite_xchan_supper: 0:初始化 1:已偷听_需邀请 2:完成邀请 + if EventManager.get_stage("c03_invite_xchan_supper") >= 1: + # 第二章,通往瞎子新卧室 & 理发店 $"../DeployLayer/portal_2".enabled = true - the_blind_bedroom_portal.enabled = false - the_blind_bedroom_portal.target_scene = "c02_s06" + the_blind_bedroom_portal.enabled = true + the_blind_bedroom_portal.status = "opened" + the_blind_bedroom_portal.target_scene = "c03_s02" the_blind_bedroom_portal.target_portal = "1" diff --git a/scene/ground/scene/c02/s06_二楼.tscn b/scene/ground/scene/c02/s06_二楼.tscn index c05c8850..2ddde5af 100644 --- a/scene/ground/scene/c02/s06_二楼.tscn +++ b/scene/ground/scene/c02/s06_二楼.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=65 format=3 uid="uid://cootarwb44vvh"] +[gd_scene load_steps=68 format=3 uid="uid://cootarwb44vvh"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_qkymk"] [ext_resource type="Script" uid="uid://cbt0ubygchxvv" path="res://scene/ground/scene/c02/s06_二楼.gd" id="2_4dg6u"] @@ -20,9 +20,12 @@ [ext_resource type="PackedScene" uid="uid://jr1yd46wm5je" path="res://scene/entity/note.tscn" id="10_h3h1a"] [ext_resource type="SpriteFrames" uid="uid://c8dl7c68f1yb0" path="res://asset/art/gif/c02_二楼/c02_二楼_frames.tres" id="10_och2w"] [ext_resource type="PackedScene" uid="uid://b50n0hvs4yh75" path="res://addons/property-inspector/pro_animation_sprite2d/pro_animated_sprite.tscn" id="10_p6da7"] +[ext_resource type="Script" uid="uid://cu4h3b6w2duwe" path="res://scene/ground/script/c02/s06_event_2d疯子跑开.gd" id="10_qoe83"] +[ext_resource type="Texture2D" uid="uid://bxmc7pas3b6wa" path="res://asset/art/scene/c03/引导纸人/指引纸人4.png" id="10_sqio2"] [ext_resource type="Texture2D" uid="uid://cylsq5cvhlp18" path="res://asset/art/tool/point_light.png" id="11_2rktm"] [ext_resource type="PackedScene" uid="uid://dqkxiqbq83cmq" path="res://scene/entity/closeup.tscn" id="11_owxx3"] [ext_resource type="PackedScene" uid="uid://cjx7o685ox8c1" path="res://scene/little_game/弹珠游戏/弹珠游戏.tscn" id="12_intre"] +[ext_resource type="SpriteFrames" uid="uid://cee76qwjhw268" path="res://asset/art/gif/c03_二楼/c03_二楼_frames.tres" id="12_sqio2"] [ext_resource type="SpriteFrames" uid="uid://c218xrr85jdc7" path="res://asset/art/gif/c03_小小小蝶上楼道/c03_小小小蝶上楼道_frames.tres" id="13_6iuix"] [ext_resource type="Script" uid="uid://wapo47a1oddf" path="res://scene/entity/audio/sfx2d.gd" id="14_7x2h6"] [ext_resource type="PackedScene" uid="uid://bnf3lkcbpx1ar" path="res://scene/entity/ambush.tscn" id="14_k01ve"] @@ -887,6 +890,7 @@ fill_to = Vector2(1, 1) [node name="S06" type="Node2D"] metadata/_edit_horizontal_guides_ = [-12.0] +metadata/_edit_vertical_guides_ = [24.0] [node name="Ground" parent="." instance=ExtResource("1_qkymk")] scene_name = "c02_s06" @@ -967,7 +971,56 @@ portal_name = "4" target_scene = "c03_s01" target_portal = "right" -[node name="楼梯蜡烛" type="Node2D" parent="Ground/DeployLayer" index="6"] +[node name="左侧纸人" type="Sprite2D" parent="Ground/DeployLayer" index="6"] +visible = false +position = Vector2(36, 35) +texture = ExtResource("10_sqio2") + +[node name="Event2D疯子跑开" type="Node2D" parent="Ground/DeployLayer" index="7"] +script = ExtResource("10_qoe83") +event_name = &"c03_f2_madman_runaway" +event_mode = "hide" +event_stages = Array[int]([1]) +pre_event_name = &"c03_invite_xchan_supper" +pre_event_mode = "hide" +pre_event_stages = Array[int]([0]) +event_memo = "当前置事件[c03_invite_xchan_supper!=0:初始化] +并且当事件[c03_f2_madman_runaway!=1]时显示该节点" +metadata/_custom_type_script = "uid://bkkiyk5jkdw4d" + +[node name="小蜡烛PointLight2D" type="PointLight2D" parent="Ground/DeployLayer/Event2D疯子跑开"] +position = Vector2(69, 45) +color = Color(0.999971, 0.912551, 0.842208, 1) +blend_mode = 2 +texture = ExtResource("11_2rktm") +texture_scale = 0.6 + +[node name="小蜡烛" type="AnimatedSprite2D" parent="Ground/DeployLayer/Event2D疯子跑开/小蜡烛PointLight2D"] +self_modulate = Color(0.611765, 0.611765, 0.611765, 1) +position = Vector2(0, 12.8172) +sprite_frames = SubResource("SpriteFrames_lipxo") +autoplay = "default" + +[node name="Pro疯子慌张跑开" parent="Ground/DeployLayer/Event2D疯子跑开" instance=ExtResource("10_p6da7")] +position = Vector2(102, 22) +sprite_frames = ExtResource("12_sqio2") +animation = &"疯子_偷听呼吸" +autoplay = "疯子_偷听呼吸" +action_configs = Array[Dictionary]([{ +"animation_intro": "疯子_慌张转身", +&"animation_next": "疯子_慌张跑开" +}]) +move_configs = Array[Dictionary]([{ +"animation": "疯子_慌张跑开", +"movement_x": 500.0, +"velocity": Vector2(-100, 0) +}]) +debug_mov_animation = "疯子_慌张跑开" + +[node name="Ambush疯子慌张跑开" parent="Ground/DeployLayer/Event2D疯子跑开" instance=ExtResource("14_k01ve")] +position = Vector2(254, 36) + +[node name="楼梯蜡烛" type="Node2D" parent="Ground/DeployLayer" index="8"] [node name="小蜡烛PointLight2D" type="PointLight2D" parent="Ground/DeployLayer/楼梯蜡烛"] position = Vector2(777.8, -48.2) @@ -1025,7 +1078,7 @@ position = Vector2(0, 12.8172) sprite_frames = SubResource("SpriteFrames_lipxo") autoplay = "default" -[node name="Pro小小蝶上楼" parent="Ground/DeployLayer" index="7" instance=ExtResource("10_p6da7")] +[node name="Pro小小蝶上楼" parent="Ground/DeployLayer" index="9" instance=ExtResource("10_p6da7")] position = Vector2(953, 30) sprite_frames = ExtResource("13_6iuix") animation = &"小小小蝶动画(跑)" @@ -1049,7 +1102,7 @@ bus = &"game_sfx" script = ExtResource("14_7x2h6") metadata/_custom_type_script = "uid://wapo47a1oddf" -[node name="Note楼梯杂物堆" parent="Ground/DeployLayer" index="8" instance=ExtResource("10_h3h1a")] +[node name="Note楼梯杂物堆" parent="Ground/DeployLayer" index="10" instance=ExtResource("10_h3h1a")] position = Vector2(801, -77) texture = ExtResource("7_v3hjg") sign_mark_offset = Vector2(0, 1.47) @@ -1062,7 +1115,7 @@ sign_mark_offset = Vector2(0, 1.47) [node name="CollisionShape2D" parent="Ground/DeployLayer/Note楼梯杂物堆/Area2D" index="0"] shape = SubResource("RectangleShape2D_2rktm") -[node name="煤油灯" parent="Ground/DeployLayer" index="9" instance=ExtResource("5_3p5ta")] +[node name="煤油灯" parent="Ground/DeployLayer" index="11" instance=ExtResource("5_3p5ta")] position = Vector2(616, -14) ground_light_texture = ExtResource("8_7x2h6") ground_height_offset = 15.0 @@ -1074,7 +1127,7 @@ shape = SubResource("RectangleShape2D_lh55k") position = Vector2(0, 15) texture = ExtResource("8_7x2h6") -[node name="煤油灯2" type="Sprite2D" parent="Ground/DeployLayer" index="10"] +[node name="煤油灯2" type="Sprite2D" parent="Ground/DeployLayer" index="12"] position = Vector2(321, 1) texture = ExtResource("16_osg51") @@ -1099,7 +1152,7 @@ blend_mode = 2 range_item_cull_mask = 4 texture = ExtResource("21_2rktm") -[node name="Interactable老鼠洞" parent="Ground/DeployLayer" index="11" instance=ExtResource("7_0d746")] +[node name="Interactable老鼠洞" parent="Ground/DeployLayer" index="13" instance=ExtResource("7_0d746")] position = Vector2(618, 50) enabled = false collision_width_and_x = Vector2(60, 0) @@ -1115,19 +1168,19 @@ shape = SubResource("RectangleShape2D_7kxvk") radius = 20.0 walk_to_edge = true -[node name="小老鼠拖鞋子" type="AnimatedSprite2D" parent="Ground/DeployLayer" index="12"] +[node name="小老鼠拖鞋子" type="AnimatedSprite2D" parent="Ground/DeployLayer" index="14"] visible = false position = Vector2(608, -15) sprite_frames = ExtResource("8_nh8we") animation = &"老鼠托小鞋子" speed_scale = -1.0 -[node name="自动跟随的老鼠" parent="Ground/DeployLayer" index="13" instance=ExtResource("9_58d45")] +[node name="自动跟随的老鼠" parent="Ground/DeployLayer" index="15" instance=ExtResource("9_58d45")] position = Vector2(4, 73) action_area = Vector2(920, 40) distance_to_player_range = Vector2(20, 150) -[node name="疯子撞墙" parent="Ground/DeployLayer" index="14" instance=ExtResource("10_p6da7")] +[node name="疯子撞墙" parent="Ground/DeployLayer" index="16" instance=ExtResource("10_p6da7")] visible = false position = Vector2(221, 4) sprite_frames = ExtResource("10_och2w") @@ -1152,7 +1205,7 @@ loop = true loop_round_time = 0.8 metadata/_custom_type_script = "uid://wapo47a1oddf" -[node name="Ambush三男孩" parent="Ground/DeployLayer" index="15" instance=ExtResource("14_k01ve")] +[node name="Ambush三男孩" parent="Ground/DeployLayer" index="17" instance=ExtResource("14_k01ve")] visible = false position = Vector2(167, 38) enabled = false @@ -1169,23 +1222,23 @@ autoplay = "f3" frame = 6 frame_progress = 0.121203 -[node name="Closeup弹珠游戏" parent="Ground/DeployLayer" index="16" instance=ExtResource("11_owxx3")] +[node name="Closeup弹珠游戏" parent="Ground/DeployLayer" index="18" instance=ExtResource("11_owxx3")] position = Vector2(322, -269) packed_scene = ExtResource("12_intre") quit_closeup_on_cancel = false -[node name="Closeup水盆" parent="Ground/DeployLayer" index="17" instance=ExtResource("11_owxx3")] +[node name="Closeup水盆" parent="Ground/DeployLayer" index="19" instance=ExtResource("11_owxx3")] position = Vector2(289, 16) packed_scene = ExtResource("16_p6da7") first_interact_os_key = "c02_二楼水盆" -[node name="Closeup谢幕演出" parent="Ground/DeployLayer" index="18" instance=ExtResource("11_owxx3")] +[node name="Closeup谢幕演出" parent="Ground/DeployLayer" index="20" instance=ExtResource("11_owxx3")] position = Vector2(518, -272) packed_scene = ExtResource("25_m28ab") quit_closeup_on_cancel = false action_key = 3 -[node name="c02_final" type="Node2D" parent="Ground/DeployLayer" index="19"] +[node name="c02_final" type="Node2D" parent="Ground/DeployLayer" index="21"] visible = false [node name="胖子" parent="Ground/DeployLayer/c02_final" instance=ExtResource("10_p6da7")] @@ -1287,13 +1340,13 @@ color = Color(0.895506, 0.638359, 0.208885, 1) energy = 0.0 texture = SubResource("GradientTexture2D_0k27j") -[node name="Ambush小蝉偷看" parent="Ground/DeployLayer" index="20" instance=ExtResource("14_k01ve")] +[node name="Ambush小蝉偷看" parent="Ground/DeployLayer" index="22" instance=ExtResource("14_k01ve")] position = Vector2(553, -5) texture = ExtResource("37_osg51") collision_width_and_x = Vector2(150, 0) hook_method = "glimpse_hide_out" -[node name="Event_小猫纸条" type="Node2D" parent="Ground/DeployLayer" index="21"] +[node name="Event_小猫纸条" type="Node2D" parent="Ground/DeployLayer" index="23"] position = Vector2(164, 42) script = ExtResource("35_h3h1a") pre_event_name = &"c02_ball_game_stage" @@ -1314,11 +1367,11 @@ content_centered = true texture_cover = ExtResource("37_rjlld") content_key = "c02_小猫纸条" -[node name="Ambush解锁二楼地图" parent="Ground/DeployLayer" index="22" instance=ExtResource("14_k01ve")] +[node name="Ambush解锁二楼地图" parent="Ground/DeployLayer" index="24" instance=ExtResource("14_k01ve")] position = Vector2(748, 47) hook_method = "unlock_2floor_map" -[node name="Event2D_xchan_run_away" type="Node2D" parent="Ground/DeployLayer" index="23"] +[node name="Event2D_xchan_run_away" type="Node2D" parent="Ground/DeployLayer" index="25"] position = Vector2(9, -4) script = ExtResource("39_t5e0j") event_name = &"c02_2f_xchan_run_away" diff --git a/scene/ground/scene/c03/s02_瞎子新卧室.tscn b/scene/ground/scene/c03/s02_瞎子新卧室.tscn index 690ba9d8..8bb86a3c 100644 --- a/scene/ground/scene/c03/s02_瞎子新卧室.tscn +++ b/scene/ground/scene/c03/s02_瞎子新卧室.tscn @@ -200,25 +200,13 @@ position = Vector2(-2, 17) sprite_frames = ExtResource("24_omt0s") animation = &"叼纸小猫坐着呼吸" -[node name="Pickable李癞钥匙" parent="Ground" instance=ExtResource("13_v3seo")] -unique_name_in_owner = true -visible = false -position = Vector2(511, 71) -prop_key = "prop_1015钥匙" - -[node name="Sprite2D" type="Sprite2D" parent="Ground/Pickable李癞钥匙"] -position = Vector2(-2, 6) -rotation = -0.875318 -scale = Vector2(0.1, 0.1) -texture = ExtResource("24_ac6iq") - -[node name="MainPlayer" parent="Ground" index="6"] +[node name="MainPlayer" parent="Ground" index="5"] position = Vector2(63, 95) catty_light_energy = 0.5 player_movement_rect = Rect2(17, -158, 492, 316) facing_direction = Vector2(1, 0) -[node name="CameraFocusMarker" parent="Ground" index="7"] +[node name="CameraFocusMarker" parent="Ground" index="6"] limit_left = 0 limit_top = -158 limit_right = 564 @@ -235,9 +223,21 @@ scale = Vector2(1.1, 1.1) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(17, 150, 509, 150) -[node name="DirectionalLight2D" parent="Ground" index="9"] +[node name="DirectionalLight2D" parent="Ground" index="8"] visible = false energy = 0.8 blend_mode = 1 +[node name="Pickable李癞钥匙" parent="Ground" instance=ExtResource("13_v3seo")] +unique_name_in_owner = true +visible = false +position = Vector2(511, 71) +prop_key = "prop_1015钥匙" + +[node name="Sprite2D" type="Sprite2D" parent="Ground/Pickable李癞钥匙"] +position = Vector2(-2, 6) +rotation = -0.875318 +scale = Vector2(0.1, 0.1) +texture = ExtResource("24_ac6iq") + [editable path="Ground"] diff --git a/scene/ground/scene/c03/s03_瞎子理发店.gd b/scene/ground/scene/c03/s03_瞎子理发店.gd index 73dffbcf..bc4a83bf 100644 --- a/scene/ground/scene/c03/s03_瞎子理发店.gd +++ b/scene/ground/scene/c03/s03_瞎子理发店.gd @@ -14,24 +14,33 @@ func _ready() -> void: #region node_reference -var Closeup刮海报_鬼母子: Closeup2D +var closeup癞子纸人: Closeup2D +var closeup刮海报_鬼母子: Closeup2D var closeup镜子特写: Closeup2D #endregion # 读取设置变量名 func _setup_node_reference() -> void: - Closeup刮海报_鬼母子 = $"../DeployLayer/Closeup刮海报_鬼母子" + closeup癞子纸人 = $"../DeployLayer/Closeup癞子纸人" + closeup刮海报_鬼母子 = $"../DeployLayer/Closeup刮海报_鬼母子" closeup镜子特写 = $"../DeployLayer/Closeup镜子特写" func _on_ground_ready() -> void: - Closeup刮海报_鬼母子.exit.connect(_check_if_flyer_shaven) + closeup刮海报_鬼母子.exit.connect(_check_if_flyer_shaven) _check_if_flyer_shaven() + closeup癞子纸人.exit.connect(_on_laizi_exit) -func _check_if_flyer_shaven(_arg = false): - if ArchiveManager.get_global_value("刮海报_理发店"): - Closeup刮海报_鬼母子.texture = null +func _check_if_flyer_shaven(_arg = false) -> void: + if ArchiveManager.get_global_value("c03_barber_shave_flyer"): + closeup刮海报_鬼母子.texture = null if _arg: SceneManager.pop_os_with_str("c03_s03_获得剪刀纸舌头") + + +func _on_laizi_exit(_arg = false) -> void: + if _arg: + # TODO + SceneManager.pop_debug_dialog_info("美术&音效", "剪辫子演出") diff --git a/scene/ground/scene/c03/s03_瞎子理发店.tscn b/scene/ground/scene/c03/s03_瞎子理发店.tscn index 159d2e2e..f30b33e3 100644 --- a/scene/ground/scene/c03/s03_瞎子理发店.tscn +++ b/scene/ground/scene/c03/s03_瞎子理发店.tscn @@ -64,11 +64,11 @@ packed_scene = ExtResource("8_xtr6o") [node name="Closeup癞子纸人" parent="Ground/DeployLayer" index="4" instance=ExtResource("5_d40x1")] unique_name_in_owner = true -position = Vector2(236, 11) +position = Vector2(343, 29) packed_scene = ExtResource("9_4imwu") [node name="癞子纸人" type="Sprite2D" parent="Ground/DeployLayer" index="5"] -position = Vector2(343, 48) +position = Vector2(343, 49) texture = ExtResource("9_bdtls") [node name="癞子纸人头套" type="Sprite2D" parent="Ground/DeployLayer/癞子纸人"] diff --git a/scene/ground/scene/c03/s04_李癞房间.tscn b/scene/ground/scene/c03/s04_李癞房间.tscn index cd2a756e..0280af29 100644 --- a/scene/ground/scene/c03/s04_李癞房间.tscn +++ b/scene/ground/scene/c03/s04_李癞房间.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=12 format=3 uid="uid://c7c88hg2cl1j7"] +[gd_scene load_steps=13 format=3 uid="uid://c7c88hg2cl1j7"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_byh4s"] [ext_resource type="Script" uid="uid://byw2swgt783oa" path="res://scene/ground/scene/c03/s04_李癞房间.gd" id="2_vjibx"] @@ -10,6 +10,7 @@ [ext_resource type="PackedScene" uid="uid://n75766ui6udi" path="res://scene/ground/script/c03/s04_closeup整理麻将游戏.tscn" id="7_jmyby"] [ext_resource type="PackedScene" uid="uid://cua3uqy4btxqn" path="res://scene/ground/script/c03/s04_closeup麻将出千游戏.tscn" id="8_jmyby"] [ext_resource type="PackedScene" uid="uid://dsa6frlw6e6gg" path="res://scene/entity/pickable.tscn" id="9_m8bf2"] +[ext_resource type="PackedScene" uid="uid://t61o0vpm0e11" path="res://scene/ground/script/c03/s04_closeup李氏纸人.tscn" id="10_o2w5q"] [sub_resource type="AnimationLibrary" id="AnimationLibrary_k01ve"] @@ -66,6 +67,13 @@ enabled = false position = Vector2(537, 55) prop_key = "prop_胖子的钥匙" +[node name="Closeup李氏纸人" parent="Ground/DeployLayer" index="6" instance=ExtResource("6_dbkw8")] +unique_name_in_owner = true +position = Vector2(373, 47) +packed_scene = ExtResource("10_o2w5q") +quit_closeup_on_cancel = false +enabled = false + [node name="MainPlayer" parent="Ground" index="5"] position = Vector2(63, 100) catty_light_energy = 0.5 diff --git a/scene/ground/script/c02/s06_event_2d疯子跑开.gd b/scene/ground/script/c02/s06_event_2d疯子跑开.gd new file mode 100644 index 00000000..eab82871 --- /dev/null +++ b/scene/ground/script/c02/s06_event_2d疯子跑开.gd @@ -0,0 +1,51 @@ +@tool +extends Event2D + +# var prev_stage := 0 +# var stage := 0 + + +func _ready() -> void: + super._ready() + if Engine.is_editor_hint(): + return + + +func _on_global_stage_updated(e: StringName, s: int): + super._on_global_stage_updated(e, s) + + +func _on_ground_ready(_ground: Ground2D): + var ambush = $"Ambush疯子慌张跑开" + # 如果已经跑开过,直接显示纸人 + if ambush.played: + $"../左侧纸人".visible = true + else: + ambush.triggered.connect(_on_ambush_triggered) + + +func _on_ambush_triggered() -> void: + SceneManager.lock_player() + var pro_sprite = $"Pro疯子慌张跑开" + pro_sprite.play("疯子_慌张转身") + pro_sprite.position_updated.connect(_on_pro_sprite_position_updated) + await Util.wait(4.0) + EventManager.set_stage(event_name, 1) + SceneManager.unlock_player() + # $"../左侧纸人".visible = true + + +var paperman_x = 24 + + +func _on_pro_sprite_position_updated(g_position: Vector2) -> void: + if g_position.x <= paperman_x: + $"../左侧纸人".visible = true + + +func _on_pre_stage_updated(): + pass + + +func _on_stage_updated(): + pass diff --git a/scene/ground/script/c02/s06_event_2d疯子跑开.gd.uid b/scene/ground/script/c02/s06_event_2d疯子跑开.gd.uid new file mode 100644 index 00000000..d9918bb3 --- /dev/null +++ b/scene/ground/script/c02/s06_event_2d疯子跑开.gd.uid @@ -0,0 +1 @@ +uid://cu4h3b6w2duwe diff --git a/scene/ground/script/c03/s03_closeup癞子纸人.gd b/scene/ground/script/c03/s03_closeup癞子纸人.gd index 8a529b03..dadfc0f3 100644 --- a/scene/ground/script/c03/s03_closeup癞子纸人.gd +++ b/scene/ground/script/c03/s03_closeup癞子纸人.gd @@ -2,16 +2,70 @@ extends CanvasLayer @onready var bg = $BG as TextureRect +signal exit(success: bool) + func _ready() -> void: layer = GlobalConfig.CANVAS_LAYER_LITTLE_GAME - if SceneManager.has_prop("prop_剪刀"): - SceneManager.pop_center_notification("ui_center_notify_use_prop") + # 两张纸钱点击事件 + %"Draggable纸钱1".picked.connect(_on_paper_coin_picked, CONNECT_ONE_SHOT) + %"Draggable纸钱2".picked.connect(_on_paper_coin_picked, CONNECT_ONE_SHOT) + %"HoverBraid".interacted.connect(_on_braid_interacted, CONNECT_ONE_SHOT) + + _check_if_notify_to_use_prop() + # 如果用过剪刀,则直接展示后脑勺 + # 0:初始化 1:已使用剪刀 2:已剪下 + if EventManager.get_stage("c03_laizi_braid") > 0: + $"头".hide() + $"头受伤".hide() + $"后脑勺".show() + +func _on_paper_coin_picked(_node = null) -> void: + if GlobalFunctor.c03_get_paper_coin(): + await SceneManager.get_inspector().quit_and_hidden + _check_if_notify_to_use_prop() + +func _on_braid_interacted() -> void: + SceneManager.enable_prop_item("prop_剪下的辫子") + await SceneManager.get_inspector().quit_and_hidden + # 退出,播放剪辫子演出 + exit.emit(true) + + +func _check_if_notify_to_use_prop() -> void: + if EventManager.get_stage("c03_papercoin1") > 0 and EventManager.get_stage("c03_papercoin2") > 0: + if EventManager.get_stage("c03_laizi_braid") > 0: + return + elif SceneManager.has_prop("prop_剪刀"): + SceneManager.pop_center_notification("ui_center_notify_use_prop") + else: + SceneManager.pop_center_notification("ui_center_notify_lack_of_prop") + func _unhandled_input(event: InputEvent) -> void: if event.is_action_pressed("interact"): get_viewport().set_input_as_handled() - if SceneManager.get_current_prop() == "prop_剪刀": - pass - else: - SceneManager.get_prop_hud().on_toggle_invalid_prop() \ No newline at end of file + _try_interact() + +var using_scissors = false + +# 尝试使用剪刀进行互动 +func _try_interact() -> void: + # 纸钱还没拿完 + if EventManager.get_stage("c03_papercoin1") == 0 or EventManager.get_stage("c03_papercoin2") == 0: + return + if SceneManager.get_current_prop() != "prop_剪刀": + SceneManager.get_prop_hud().on_toggle_invalid_prop() + return + if using_scissors: + return + using_scissors = true + # $"头".hide() + # TODO + SceneManager.pop_debug_dialog_info("音效", "使用剪刀(惊悚)") + $"头".hide() + await Util.wait(1.5) + $"头受伤".hide() + $"后脑勺".show() + SceneManager.disable_prop_item("prop_剪刀") + EventManager.set_stage("c03_laizi_braid", 1) diff --git a/scene/ground/script/c03/s03_closeup癞子纸人.tscn b/scene/ground/script/c03/s03_closeup癞子纸人.tscn index 98377557..8ab5fc89 100644 --- a/scene/ground/script/c03/s03_closeup癞子纸人.tscn +++ b/scene/ground/script/c03/s03_closeup癞子纸人.tscn @@ -1,8 +1,18 @@ -[gd_scene load_steps=4 format=3 uid="uid://d320nw5yrmvjo"] +[gd_scene load_steps=14 format=3 uid="uid://d320nw5yrmvjo"] [ext_resource type="Script" uid="uid://de2smnt2my047" path="res://scene/ground/script/c03/s03_closeup癞子纸人.gd" id="1_6n6qt"] [ext_resource type="Texture2D" uid="uid://cbql1i4hblmt1" path="res://asset/art/ui/遮罩/inspect特写通用遮罩.png" id="2_uenj0"] -[ext_resource type="Texture2D" uid="uid://bv5vcrdqwtlm3" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子纸人.png" id="2_xao0c"] +[ext_resource type="Texture2D" uid="uid://e88x3ihvhetd" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/背景.png" id="2_xao0c"] +[ext_resource type="Texture2D" uid="uid://cxlwpf82sqc8p" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1辫子没剪开.png" id="3_abwb2"] +[ext_resource type="Texture2D" uid="uid://b7s25rgph0111" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/辫子散了.png" id="3_jijuh"] +[ext_resource type="Texture2D" uid="uid://c12xhretrdxs6" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/1大头.png" id="4_8yx5x"] +[ext_resource type="Texture2D" uid="uid://doqxrw48g45iy" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/伤口_头.png" id="4_c581m"] +[ext_resource type="PackedScene" uid="uid://bkk1rxx36ghrl" path="res://scene/entity/ux/hover_light_click_area.tscn" id="4_nc54a"] +[ext_resource type="PackedScene" uid="uid://bg7oictr1wgex" path="res://scene/little_game/general/draggable.tscn" id="4_uenj0"] +[ext_resource type="Texture2D" uid="uid://cqrc7v5lg2cey" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/l_辫子.png" id="5_jijuh"] +[ext_resource type="Texture2D" uid="uid://fspvmlydy3hu" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png" id="5_kcw8x"] +[ext_resource type="Script" uid="uid://0wjaho6qkg6s" path="res://manager/event_manager/event_binder.gd" id="6_uenj0"] +[ext_resource type="Texture2D" uid="uid://vyuf0wekr1lq" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱1.png" id="7_kcw8x"] [node name="Closeup癞子纸人" type="CanvasLayer"] script = ExtResource("1_6n6qt") @@ -15,8 +25,122 @@ grow_horizontal = 2 grow_vertical = 2 mouse_filter = 0 texture = ExtResource("2_xao0c") +expand_mode = 1 +stretch_mode = 3 + +[node name="后脑勺_剪辫" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("3_jijuh") +expand_mode = 1 +stretch_mode = 3 + +[node name="后脑勺" type="TextureRect" parent="."] +visible = false +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("3_abwb2") +expand_mode = 1 +stretch_mode = 3 + +[node name="HoverBraid" parent="后脑勺" instance=ExtResource("4_nc54a")] +unique_name_in_owner = true +position = Vector2(280, 181) + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="后脑勺/HoverBraid"] +polygon = PackedVector2Array(22, -110.9, -10, -113.1, -10, -112, -15.6, -112, -21.6, -108, -24.7, -108, -36.7, -98, -38.2, -98, -44.2, -87, -45.9, -87, -46.9, -70, -48.4, -70, -46, -56.6, -46, -51.6, -38, -33.7, -38, -30.3, -21, -9, -20, -7, -20, -3.39999, -12.4, 7.5, -14, 17.8, -14, 25.1, -10, 90.1, -10, 92.8, -13, 129.9, -13, 132.8, 3, 133, 3.4, 132, 5.1, 132, 4, 110.9, 4, 104.1, 8.9, 30, 10.3, 30, 8, 13.7, 8, 10.4, 15, -1.5, 15, -3.10001, 19.7, -7, 21.1, -7, 35.1, -28, 36.4, -28, 45.4, -52, 47, -52, 47, -84.5, 43, -92.5, 43, -94.9, 35, -101.9, 35, -103.3, 22, -109.3) + +[node name="PointLight2D" type="PointLight2D" parent="后脑勺/HoverBraid"] +range_layer_max = 10 +texture = ExtResource("5_jijuh") + +[node name="EventBinder" type="Node" parent="后脑勺/HoverBraid"] +script = ExtResource("6_uenj0") +memo = "[hoverbraid] interacted 时: c03_laizi_braid=2:已剪下(greater)" +trigger_event = &"c03_laizi_braid" +trigger_mode = "interacted" +trigger_stage = 2 +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + +[node name="EventBinder" type="Node" parent="后脑勺"] +script = ExtResource("6_uenj0") +memo = "c03_laizi_braid=[1:已使用剪刀] 时,显示: [后脑勺] +" +updater_event = &"c03_laizi_braid" +updater_mode = "shower" +updater_ease_duration = 0.0 +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + +[node name="头受伤" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("4_c581m") +expand_mode = 1 +stretch_mode = 3 + +[node name="头" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("4_8yx5x") +expand_mode = 1 +stretch_mode = 3 + +[node name="Draggable纸钱2" parent="头" instance=ExtResource("4_uenj0")] +unique_name_in_owner = true +position = Vector2(237, 140) +act_as_button = true +texture = ExtResource("5_kcw8x") + +[node name="EventBinder" type="Node" parent="头/Draggable纸钱2"] +script = ExtResource("6_uenj0") +memo = "c03_papercoin2=[0] 时,显示: [纸钱2] +[纸钱2] picked 时: c03_papercoin2=1(greater)" +updater_event = &"c03_papercoin2" +updater_mode = "shower" +updater_ease_duration = 0.0 +updater_stages = Array[int]([0]) +trigger_event = &"c03_papercoin2" +trigger_mode = "picked" +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="头/Draggable纸钱2"] +polygon = PackedVector2Array(13, -30, -9.5, -30, -19.5, -25, -22.1, -25, -30, -12.2, -30, 14.1, -25, 21.6, -25, 24.3, -12, 30, 13.7, 30, 21.6, 25, 24.2, 25, 30, 14.5, 30, -11, 26, -17.6, 26, -20, 13, -29) + +[node name="Draggable纸钱1" parent="头" instance=ExtResource("4_uenj0")] +unique_name_in_owner = true +position = Vector2(319, 139) +act_as_button = true +texture = ExtResource("7_kcw8x") + +[node name="EventBinder" type="Node" parent="头/Draggable纸钱1"] +script = ExtResource("6_uenj0") +memo = "c03_papercoin1=[0] 时,显示: [纸钱1] +[纸钱1] picked 时: c03_papercoin1=1(greater)" +updater_event = &"c03_papercoin1" +updater_mode = "shower" +updater_ease_duration = 0.0 +updater_stages = Array[int]([0]) +trigger_event = &"c03_papercoin1" +trigger_mode = "picked" +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="头/Draggable纸钱1"] +polygon = PackedVector2Array(13, -30, -9.5, -30, -19.5, -25, -22.1, -25, -30, -12.2, -30, 14.1, -25, 21.6, -25, 24.3, -12, 30, 13.7, 30, 21.6, 25, 24.2, 25, 30, 14.5, 30, -11, 26, -17.6, 26, -20, 13, -29) [node name="遮罩" type="TextureRect" parent="."] +visible = false anchors_preset = 15 anchor_right = 1.0 anchor_bottom = 1.0 diff --git a/scene/ground/script/c03/s03_刮海报_理发店.tscn b/scene/ground/script/c03/s03_刮海报_理发店.tscn index 39b8e386..a95c211c 100644 --- a/scene/ground/script/c03/s03_刮海报_理发店.tscn +++ b/scene/ground/script/c03/s03_刮海报_理发店.tscn @@ -50,7 +50,7 @@ data = { [sub_resource type="ImageTexture" id="ImageTexture_puk8y"] image = SubResource("Image_go12c") -[node name="刮海报_理发店" type="CanvasLayer"] +[node name="c03_barber_shave_flyer" type="CanvasLayer"] layer = 5 script = ExtResource("1_pdoaa") exit_on_shaven_fulfilled = false @@ -132,36 +132,8 @@ centered = false [node name="Props" type="Node2D" parent="鬼母子游戏/倒塌"] visible = false -[node name="剪刀" parent="鬼母子游戏/倒塌/Props" instance=ExtResource("15_3uuyc")] -position = Vector2(364, 248) - -[node name="Sprite2D" type="Sprite2D" parent="鬼母子游戏/倒塌/Props/剪刀"] -position = Vector2(-55, -19) -texture = ExtResource("16_go12c") -centered = false - -[node name="PointLight2D" type="PointLight2D" parent="鬼母子游戏/倒塌/Props/剪刀"] -position = Vector2(-1, 1) -range_layer_max = 10 -texture = ExtResource("16_ikyli") - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="鬼母子游戏/倒塌/Props/剪刀"] -visible = false -polygon = PackedVector2Array(4, -25, -10, -25, -14, -13.4, -14, -8.4, -37.5, 1, -41.6, 1, -50.6, 7, -53, 7, -56, 11, -57.2, 11, -58.3, 13.2, -55, 17.6, -55, 20.3, -38.7, 18, -34.7, 18, -8, 8.4, -5.7, 8, 7.3, 18, 35.6, 18, 44.6, 12, 47.1, 12, 54.1, 1, 56.5, 1, 54, -10.4, 54, -12.8, 43, -23.8, 43, -25, 29.4, -25, 27, -21.8, 1.4, -18, 4, -23.6) - -[node name="EventBinder" type="Node" parent="鬼母子游戏/倒塌/Props/剪刀"] -script = ExtResource("17_dhl8m") -memo = "c03_hariti_scissor=[0] 时,显示: [剪刀] -[剪刀] interacted 时: c03_hariti_scissor=1(greater)" -updater_event = &"c03_hariti_scissor" -updater_mode = "shower" -updater_ease_duration = 0.0 -updater_stages = Array[int]([0]) -trigger_event = &"c03_hariti_scissor" -trigger_mode = "interacted" -metadata/_custom_type_script = "uid://0wjaho6qkg6s" - [node name="纸舌头" parent="鬼母子游戏/倒塌/Props" instance=ExtResource("15_3uuyc")] +unique_name_in_owner = true position = Vector2(255, 248) [node name="Sprite2D" type="Sprite2D" parent="鬼母子游戏/倒塌/Props/纸舌头"] @@ -191,6 +163,36 @@ trigger_event = &"c03_hariti_tongue" trigger_mode = "interacted" metadata/_custom_type_script = "uid://0wjaho6qkg6s" +[node name="剪刀" parent="鬼母子游戏/倒塌/Props" instance=ExtResource("15_3uuyc")] +unique_name_in_owner = true +position = Vector2(364, 248) + +[node name="Sprite2D" type="Sprite2D" parent="鬼母子游戏/倒塌/Props/剪刀"] +position = Vector2(-55, -19) +texture = ExtResource("16_go12c") +centered = false + +[node name="PointLight2D" type="PointLight2D" parent="鬼母子游戏/倒塌/Props/剪刀"] +position = Vector2(-1, 1) +range_layer_max = 10 +texture = ExtResource("16_ikyli") + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="鬼母子游戏/倒塌/Props/剪刀"] +visible = false +polygon = PackedVector2Array(4, -25, -10, -25, -14, -13.4, -14, -8.4, -37.5, 1, -41.6, 1, -50.6, 7, -53, 7, -56, 11, -57.2, 11, -58.3, 13.2, -55, 17.6, -55, 20.3, -38.7, 18, -34.7, 18, -8, 8.4, -5.7, 8, 7.3, 18, 35.6, 18, 44.6, 12, 47.1, 12, 54.1, 1, 56.5, 1, 54, -10.4, 54, -12.8, 43, -23.8, 43, -25, 29.4, -25, 27, -21.8, 1.4, -18, 4, -23.6) + +[node name="EventBinder" type="Node" parent="鬼母子游戏/倒塌/Props/剪刀"] +script = ExtResource("17_dhl8m") +memo = "c03_hariti_scissor=[0] 时,显示: [剪刀] +[剪刀] interacted 时: c03_hariti_scissor=1(greater)" +updater_event = &"c03_hariti_scissor" +updater_mode = "shower" +updater_ease_duration = 0.0 +updater_stages = Array[int]([0]) +trigger_event = &"c03_hariti_scissor" +trigger_mode = "interacted" +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + [node name="遮罩" type="TextureRect" parent="."] anchors_preset = 15 anchor_right = 1.0 diff --git a/scene/ground/script/c03/s04_closeup李氏纸人.gd b/scene/ground/script/c03/s04_closeup李氏纸人.gd new file mode 100644 index 00000000..f475d570 --- /dev/null +++ b/scene/ground/script/c03/s04_closeup李氏纸人.gd @@ -0,0 +1,9 @@ +extends CanvasLayer + +@warning_ignore("unused_signal") +signal exit(arg) + + +func _ready() -> void: + layer = GlobalConfig.CANVAS_LAYER_LITTLE_GAME + %"Draggable纸钱3".picked.connect(GlobalFunctor.c03_get_paper_coin, CONNECT_ONE_SHOT) diff --git a/scene/ground/script/c03/s04_closeup李氏纸人.gd.uid b/scene/ground/script/c03/s04_closeup李氏纸人.gd.uid new file mode 100644 index 00000000..7ca354f0 --- /dev/null +++ b/scene/ground/script/c03/s04_closeup李氏纸人.gd.uid @@ -0,0 +1 @@ +uid://dvjh42hafpmg3 diff --git a/scene/ground/script/c03/s04_closeup李氏纸人.tscn b/scene/ground/script/c03/s04_closeup李氏纸人.tscn new file mode 100644 index 00000000..245c3115 --- /dev/null +++ b/scene/ground/script/c03/s04_closeup李氏纸人.tscn @@ -0,0 +1,83 @@ +[gd_scene load_steps=9 format=3 uid="uid://t61o0vpm0e11"] + +[ext_resource type="Script" uid="uid://dvjh42hafpmg3" path="res://scene/ground/script/c03/s04_closeup李氏纸人.gd" id="1_nmxob"] +[ext_resource type="Texture2D" uid="uid://cbql1i4hblmt1" path="res://asset/art/ui/遮罩/inspect特写通用遮罩.png" id="2_3rwht"] +[ext_resource type="PackedScene" uid="uid://bg7oictr1wgex" path="res://scene/little_game/general/draggable.tscn" id="2_ov1mc"] +[ext_resource type="Texture2D" uid="uid://fspvmlydy3hu" path="res://asset/art/scene/c03/s03_瞎子理发店/癞子特写/纸钱2.png" id="3_on24v"] +[ext_resource type="PackedScene" uid="uid://dmysq4sxx8iqh" path="res://scene/entity/ux/content_inspector.tscn" id="3_ov1mc"] +[ext_resource type="Script" uid="uid://0wjaho6qkg6s" path="res://manager/event_manager/event_binder.gd" id="4_qqxug"] +[ext_resource type="Texture2D" uid="uid://f186lvt5y2ql" path="res://asset/art/ui/遮罩/inspect背景遮罩.png" id="5_qqxug"] +[ext_resource type="Script" uid="uid://dpocj5al0rvai" path="res://ui/text_helper.gd" id="6_ncmgt"] + +[node name="Closeup李氏纸人" type="CanvasLayer"] +script = ExtResource("1_nmxob") + +[node name="BG" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 0 + +[node name="Draggable纸钱3" parent="." instance=ExtResource("2_ov1mc")] +unique_name_in_owner = true +position = Vector2(237, 140) +act_as_button = true +texture = ExtResource("3_on24v") + +[node name="EventBinder" type="Node" parent="Draggable纸钱3"] +script = ExtResource("4_qqxug") +memo = "c03_papercoin3=[0] 时,显示: [纸钱3] +[纸钱3] picked 时: c03_papercoin3=1(greater)" +updater_event = &"c03_papercoin3" +updater_mode = "shower" +updater_ease_duration = 0.0 +updater_stages = Array[int]([0]) +trigger_event = &"c03_papercoin3" +trigger_mode = "picked" +metadata/_custom_type_script = "uid://0wjaho6qkg6s" + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Draggable纸钱3"] +polygon = PackedVector2Array(13, -30, -9.5, -30, -19.5, -25, -22.1, -25, -30, -12.2, -30, 14.1, -25, 21.6, -25, 24.3, -12, 30, 13.7, 30, 21.6, 25, 24.2, 25, 30, 14.5, 30, -11, 26, -17.6, 26, -20, 13, -29) + +[node name="遮罩" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +texture = ExtResource("2_3rwht") + +[node name="ContentInspector" parent="." instance=ExtResource("3_ov1mc")] +visible = false +mouse_filter = 2 + +[node name="遮罩" type="TextureRect" parent="ContentInspector"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +texture = ExtResource("5_qqxug") + +[node name="Label" type="Label" parent="ContentInspector/遮罩"] +custom_minimum_size = Vector2(180, 0) +layout_mode = 1 +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = -60.0 +offset_top = -15.5 +offset_right = 60.0 +offset_bottom = 15.5 +grow_horizontal = 2 +grow_vertical = 2 +vertical_alignment = 1 +autowrap_mode = 3 +script = ExtResource("6_ncmgt") diff --git a/scene/ground/script/c03/鬼母子游戏.gd b/scene/ground/script/c03/鬼母子游戏.gd index 9ec5f385..6a17d045 100644 --- a/scene/ground/script/c03/鬼母子游戏.gd +++ b/scene/ground/script/c03/鬼母子游戏.gd @@ -26,11 +26,11 @@ func _ready() -> void: $"倒塌/Props/纸舌头".interacted.connect(SceneManager.enable_prop_item.bind("prop_纸舌头")) $"../刮刮乐".visible = true - var shaven = ArchiveManager.get_global_value("刮海报_理发店") + var shaven = ArchiveManager.get_global_value("c03_barber_shave_flyer") states = ArchiveManager.get_global_value("c03_s03_hariti_states", []) _setup_state() if _check_success(): - get_node("../刮刮乐").queue_free() + # get_node("../刮刮乐").queue_free() $"倒塌".visible = true $"倒塌".frame = 3 $"倒塌/Props".visible = true diff --git a/scene/little_game/general/draggable.gd b/scene/little_game/general/draggable.gd index 5adc63cf..796dd616 100644 --- a/scene/little_game/general/draggable.gd +++ b/scene/little_game/general/draggable.gd @@ -105,8 +105,10 @@ func _input(event: InputEvent) -> void: if event.button_index == MOUSE_BUTTON_LEFT and event.pressed: # Trigger the pick action if touching and not holding: + get_viewport().set_input_as_handled() _try_pick() elif holding: + get_viewport().set_input_as_handled() _drop() elif holding and event is InputEventMouseMotion: _update_pos_to_mouse() diff --git a/scene/ux/prop_inspector.gd b/scene/ux/prop_inspector.gd index 69b3ee6e..91f3a989 100644 --- a/scene/ux/prop_inspector.gd +++ b/scene/ux/prop_inspector.gd @@ -12,6 +12,8 @@ enum { # must be connected to signal quit_and_hidden + +@onready var mouse_mask = %MouseMask as Control @onready var notes_bg = %NotesBG as TextureRect @onready var prop_bg = %PropBG as TextureRect @onready var origin_texture = %OriginPropTexture as TextureRect @@ -122,8 +124,10 @@ var locking = false: if val != locking: locking = val if val: + mouse_mask.mouse_filter = Control.MOUSE_FILTER_STOP SceneManager.lock_player() else: + mouse_mask.mouse_filter = Control.MOUSE_FILTER_IGNORE SceneManager.unlock_player() _lock_mutex.unlock() diff --git a/scene/ux/prop_inspector.tscn b/scene/ux/prop_inspector.tscn index d10fb871..73a611b5 100644 --- a/scene/ux/prop_inspector.tscn +++ b/scene/ux/prop_inspector.tscn @@ -10,6 +10,17 @@ process_mode = 3 layer = 21 script = ExtResource("1_2wpwe") +[node name="MouseMask" type="Control" parent="."] +unique_name_in_owner = true +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +size_flags_horizontal = 4 +mouse_filter = 2 + [node name="PropBG" type="TextureRect" parent="."] unique_name_in_owner = true visible = false