diff --git a/log/logger/logs/v-demo-1.json b/log/logger/logs/v-demo-1.json deleted file mode 100644 index b2de266b..00000000 --- a/log/logger/logs/v-demo-1.json +++ /dev/null @@ -1,103 +0,0 @@ -{ - "items": [ - { - "event_date": "12/25/2024", - "item_id": "17350940343608", - "log_content": "完善《从策划、资产(美术、音效)到程序的工作流说明》:\n* 三层定义:上层两端(策划+资产)、下层数据、程序中台\n* 五类定义:时间线纲要,实体,场景与部署点,事件与 CG,小游戏\n* 工作流六步:定义资产规格,定义部署规格,定义音效规格,生产并组装资产,检阅与意见\n* 关于 UX 理念与分工的说明", - "tags": [ - "2@design", - "3@manage_tool" - ], - "update_date": "12/25/2024" - }, - { - "event_date": "12/24/2024", - "item_id": "17350401808351", - "log_content": "实现自动存档功能:\n* 整合存档资源在 AssembledArchive 下\n* 多存档(隔离) + 单配置(全局)\n* 可配置定时保存\n* 游戏时长记录:存档游戏时长 + 全局游戏时长\n", - "tags": [ - "2@code" - ], - "update_date": "12/24/2024" - }, - { - "event_date": "12/24/2024", - "item_id": "17350028043797", - "log_content": "* 完善消息提示功能\n * 0.5s 浮现,显示 3s,0.5s 隐藏(通过调整 alpha 通道实现)\n * 支持堆积消息\n * 如果有堆积的消息,显示 2s(而不是 3s)", - "tags": [ - "2@ui", - "2@code" - ], - "update_date": "12/24/2024" - }, - { - "event_date": "12/23/2024", - "item_id": "4123576587", - "log_content": "* 完善消息提示功能\n * 0.5s 浮现,显示 3s,0.5s 隐藏(通过调整 alpha 通道实现)\n * 支持堆积消息\n * 如果有堆积的消息,显示 2s(而不是 3s)", - "tags": [ - "2@ui", - "2@code" - ], - "update_date": "12/24/2024" - }, - { - "event_date": "12/22/2024", - "item_id": "876528753689", - "log_content": "* 完成动画导入功能:\n * 自动检测目录下文件,帧排序后,导入到: res://config/animation/player_sprite_frames.tres \n * 文件名 mapping 到动画 animation 名称\n * 取第一帧作动画\n * 镜像动画\n * 网格化检阅", - "tags": [ - "2@code", - "3@art_tool", - "2@animation" - ], - "update_date": "12/22/2024" - }, - { - "event_date": "12/20/2024", - "item_id": "2546254798879", - "log_content": "* 游戏时间戳\n * 全局游戏时长记录\n * 当前存档时间状态:章节进度,游戏时长等\n* 场景管理器:发送消息浮窗\n* 事件系统:\n * 数据格式(四要素):\n * 时间(chapter_section,时间戳,周目状态等)\n * 地点(场景id,坐标)\n * 实体(实体id,状态)\n * 实体动作(action_id)\n * 流程:发送事件流程,消费事件流程\n* 存档:\n * 保存全局配置(如游戏总时长,周目数)\n * 分存档保存当前存档状态:时间、场景、实体\n* 组装实体:\n * 规格配置:进行中\n * 素材填充:进行中", - "tags": [ - "2@code", - "2@design" - ], - "update_date": "12/22/2024" - }, - { - "event_date": "12/19/2024", - "item_id": "52643524662456", - "log_content": "* 角色移动状态机功能:静止/行走/奔跑/躺卧移动/上下爬行\n * 允许锁定移动/锁定奔跑,躺卧移动与上下爬行互斥\n* 规格化调整:\n * UI 规格化:物品HUD,对话浮窗\n * 场景规格化:层次背景,角色\n* 镜头 Marker :随玩家移动方向轻微偏移,优化视野细节", - "tags": [ - "2@design", - "2@code", - "2@animation" - ], - "update_date": "12/22/2024" - }, - { - "event_date": "12/18/2024", - "item_id": "5423765786358", - "log_content": "确定资源类型,围绕规格化的资源\n基本工作流设计\n完善 HUD 功能", - "tags": [ - "2@ui", - "2@design" - ], - "update_date": "12/22/2024" - }, - { - "event_date": "12/17/2024", - "item_id": "11242354", - "log_content": "加入基础的游戏背景、角色行走功能", - "tags": [ - "2@code" - ], - "update_date": "12/22/2024" - }, - { - "event_date": "12/16/2024", - "item_id": "17343458739570", - "log_content": "新建项目等", - "tags": [ - "2@design" - ], - "update_date": "12/22/2024" - } - ] -} diff --git a/log/logger/project_log_panel.gd b/log/logger/project_log_panel.gd deleted file mode 100644 index 1f2ba693..00000000 --- a/log/logger/project_log_panel.gd +++ /dev/null @@ -1,140 +0,0 @@ -extends CanvasLayer - -class_name ProjectLogPanel - -enum TAG_TYPE{VERSION=0,FIX=1,FEATURE=2,TOOL=3} - -const TAG_TYPE_COLOR_DICT = { - TAG_TYPE.VERSION: Color.SKY_BLUE, - TAG_TYPE.FIX: Color.RED, - TAG_TYPE.FEATURE: Color.AQUAMARINE, - TAG_TYPE.TOOL: Color.ORCHID - } - -const TAG_DICT = { - TAG_TYPE.VERSION:["demo","0.1","1.0"], - TAG_TYPE.FIX:["bugfix","uxfix"], - TAG_TYPE.FEATURE:["code","design","ui","audio","art","animation"], - TAG_TYPE.TOOL:["art_tool","log_tool","manage_tool"], -} - -#const LOG_CONFIG_KEY_prefix = "log_panel_json_" -const LOG_DATA_DIR = "res://log/logger/logs/" -var log_files = [] -var current_log_file - -const IMAGE_DIR = "" - -@onready var add_btn := %Add -@onready var save_btn := %Save -@onready var archives_btn := %Archives as MenuButton -@onready var archives_label := %ArchiveLabel as Label -@onready var log_items_container = %LogItemsContainer - -const LOG_ITEM_GROUP = "log_item" -const LOG_ITEM_GROUP_MENBER = "log_item[{0}]" - -var log_item_scene = preload("res://log/logger/project_log_panel_item.tscn") - -var data = {"items":[]} as Dictionary - -func _ready(): - add_btn.pressed.connect(_on_add) - save_btn.pressed.connect(save_logs) - archives_btn.get_popup().id_pressed.connect(_on_archive_switch) - _load_archives() - _on_archive_switch(log_files.find("v-demo-mountwuwang.json")) - # var quat = Quaternion.from_euler(Vector3(deg_to_rad(10),0,deg_to_rad(10))) - # print(quat) - # quat = quat.normalized() - # print(quat) - # quat = Quaternion(Vector3(1,0,0),deg_to_rad(10)) * Quaternion(Vector3(0,0,1),deg_to_rad(10)) - # print(quat) - # quat = quat.normalized() - # print(quat) - -func _load_archives(): - log_files = DirAccess.get_files_at(LOG_DATA_DIR) as PackedStringArray - if log_files.size() == 0: - printerr("_load_archives no file exists:",LOG_DATA_DIR) - for i in range(0,log_files.size()): - archives_btn.get_popup().add_item(log_files[i],i) - _on_archive_switch(0) - -func _load_logs(): - var path = _get_curr_path() - if !FileAccess.file_exists(path): - printerr("_load_logs no file exists:",path) - return - var json = ResourceLoader.load(path,"",ResourceLoader.CACHE_MODE_IGNORE) - #print("load data=",json.data) - print("loaded data") - data = json.data - if !data.has("items"): - data["items"] = [] - _refresh_items() - -func _get_curr_path(): - return LOG_DATA_DIR + current_log_file - -func _refresh_items(): - var items = data["items"] as Array - get_tree().call_group(LOG_ITEM_GROUP, "queue_free") - for i in range(items.size()): - var item_instance = log_item_scene.instantiate() as Control - item_instance.add_to_group(LOG_ITEM_GROUP) - item_instance.add_to_group(LOG_ITEM_GROUP_MENBER.format([])) - item_instance.update.connect(_on_log_item_update.bind(i)) - #item_instance.save.connect(_on_log_item_save.bind(i)) - item_instance.remove.connect(_on_log_item_remove.bind(i)) - log_items_container.add_child(item_instance) - if items[i] is Dictionary: - item_instance.load_item(items[i]) - elif items[i] is String: - var item_dict = JSON.parse_string(items[i]) - item_instance.load_item(item_dict) - else : - push_error("unknow type items[",i,"]=",items[i]) - -func save_logs(): - var path = _get_curr_path() - if !FileAccess.file_exists(path): - printerr("save_logs no file exists:",path) - return - #print("save logs data=", data) - print("saved logs") - var file := FileAccess.open(path, FileAccess.WRITE_READ) as FileAccess - file.store_string(JSON.stringify(data, "\t")) - file.close() - -func _on_log_item_update(item:LogItem.ItemData, index:int): - var json = item.to_json_dict() - print("_on_log_item_update item=", json) - data["items"][index] = json - -func _on_log_item_save(item:LogItem.ItemData, index:int): - var json = item.to_json_dict() - print("_on_log_item_save item=", json) - data["items"][index] = json - save_logs() - -func _on_log_item_remove(index:int): - (data["items"] as Array).remove_at(index) - save_logs() - # reset index for each item - _refresh_items() - -func _on_add(): - (data["items"] as Array).push_front({}) - save_logs() - # reset index for each item - _refresh_items() - -func _on_archive_switch(id:int): - current_log_file = log_files[id] - archives_label.text = log_files[id] - _load_logs() - -func _unhandled_input(event): - if event.is_action("save"): - save_logs() diff --git a/log/logger/project_log_panel.gd.uid b/log/logger/project_log_panel.gd.uid deleted file mode 100644 index 7d1564cb..00000000 --- a/log/logger/project_log_panel.gd.uid +++ /dev/null @@ -1 +0,0 @@ -uid://caasronuiver3 diff --git a/log/logger/project_log_panel.tscn b/log/logger/project_log_panel.tscn deleted file mode 100644 index d2ade34b..00000000 --- a/log/logger/project_log_panel.tscn +++ /dev/null @@ -1,119 +0,0 @@ -[gd_scene load_steps=4 format=3 uid="uid://b3n06jtdpqy5y"] - -[ext_resource type="Script" uid="uid://caasronuiver3" path="res://log/logger/project_log_panel.gd" id="1_2rhk7"] -[ext_resource type="PackedScene" uid="uid://bdy4u3e7rmo7f" path="res://ui/button/sound_button.tscn" id="2_71u5c"] -[ext_resource type="PackedScene" uid="uid://dhvo15vyxpkja" path="res://log/logger/project_log_panel_item.tscn" id="4_1yhgi"] - -[node name="ProjectLogPanel" type="CanvasLayer"] -script = ExtResource("1_2rhk7") - -[node name="MarginContainer" type="MarginContainer" parent="."] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -theme_override_constants/margin_left = 8 -theme_override_constants/margin_top = 8 -theme_override_constants/margin_right = 8 -theme_override_constants/margin_bottom = 8 - -[node name="VBoxContainer" type="VBoxContainer" parent="MarginContainer"] -layout_mode = 2 - -[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/VBoxContainer"] -layout_mode = 2 -theme_override_constants/margin_left = 12 -theme_override_constants/margin_top = 6 -theme_override_constants/margin_right = 12 -theme_override_constants/margin_bottom = 6 - -[node name="HBoxContainer" type="HBoxContainer" parent="MarginContainer/VBoxContainer/MarginContainer"] -layout_mode = 2 -size_flags_vertical = 4 -alignment = 2 - -[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer"] -layout_mode = 2 -size_flags_horizontal = 3 -size_flags_vertical = 4 -theme_override_constants/margin_left = 12 -theme_override_constants/margin_top = 6 -theme_override_constants/margin_right = 12 -theme_override_constants/margin_bottom = 6 - -[node name="Title" type="Label" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer/MarginContainer"] -layout_mode = 2 -size_flags_horizontal = 4 -theme_override_colors/font_color = Color(0.670588, 0.952941, 0.972549, 1) -theme_override_colors/font_shadow_color = Color(0.180392, 0.180392, 0.180392, 1) -theme_override_colors/font_outline_color = Color(0.0156863, 0.258824, 0.341176, 1) -theme_override_constants/shadow_offset_x = 2 -theme_override_constants/shadow_offset_y = 2 -theme_override_constants/outline_size = 4 -theme_override_constants/shadow_outline_size = 12 -theme_override_font_sizes/font_size = 24 -text = "Project Log" - -[node name="Add" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer" instance=ExtResource("2_71u5c")] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 8 -size_flags_vertical = 4 -text = "Add" -script = null - -[node name="Save" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer" instance=ExtResource("2_71u5c")] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 8 -size_flags_vertical = 4 -text = "Save" -script = null - -[node name="Archives" type="MenuButton" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer"] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 4 -size_flags_vertical = 4 -text = "Archives" -flat = false - -[node name="ArchiveLabel" type="Label" parent="MarginContainer/VBoxContainer/MarginContainer/HBoxContainer"] -unique_name_in_owner = true -layout_mode = 2 - -[node name="MarginContainer2" type="MarginContainer" parent="MarginContainer/VBoxContainer"] -layout_mode = 2 -size_flags_vertical = 3 -theme_override_constants/margin_left = 8 -theme_override_constants/margin_top = 8 -theme_override_constants/margin_right = 8 -theme_override_constants/margin_bottom = 8 - -[node name="ScrollContainer" type="ScrollContainer" parent="MarginContainer/VBoxContainer/MarginContainer2"] -layout_mode = 2 -size_flags_vertical = 3 - -[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/VBoxContainer/MarginContainer2/ScrollContainer"] -layout_mode = 2 -size_flags_horizontal = 3 -theme_override_constants/margin_left = 4 -theme_override_constants/margin_top = 4 -theme_override_constants/margin_right = 8 -theme_override_constants/margin_bottom = 4 - -[node name="LogItemsContainer" type="VBoxContainer" parent="MarginContainer/VBoxContainer/MarginContainer2/ScrollContainer/MarginContainer"] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 3 -size_flags_vertical = 0 -alignment = 1 - -[node name="LogItem" parent="MarginContainer/VBoxContainer/MarginContainer2/ScrollContainer/MarginContainer/LogItemsContainer" instance=ExtResource("4_1yhgi")] -visible = false -layout_mode = 2 - -[node name="LogItem2" parent="MarginContainer/VBoxContainer/MarginContainer2/ScrollContainer/MarginContainer/LogItemsContainer" instance=ExtResource("4_1yhgi")] -visible = false -layout_mode = 2 diff --git a/log/logger/project_log_panel_item.gd b/log/logger/project_log_panel_item.gd deleted file mode 100644 index f78e6e75..00000000 --- a/log/logger/project_log_panel_item.gd +++ /dev/null @@ -1,198 +0,0 @@ -extends HBoxContainer - -class_name LogItem - -#signal save(data:ItemData) -signal update(data: ItemData) -signal remove - -const TAG_BTN_GROUP_PREFIX = "tag_btn" - -@onready var log_content := %LogContent as TextEdit -@onready var event_date := %EventDate as Label -#@onready var update_date := %LogUpdateDate as Label -@onready var tags_container := %TagsContainer as GridContainer -@onready var add_tag_btn := %AddTag as MenuButton -@onready var reload_btn = %Reload -@onready var save_btn = %Save -@onready var delete_btn = %Delete - -var original_data := ItemData.new() -var data: ItemData = original_data - - -class ItemData: - var item_id := _generate_random_id() - var log_content := "": - set(new_val): - if new_val != log_content: - update_date = _get_current_time() - log_content = new_val - var tags := []: - set(new_val): - update_date = _get_current_time() - tags = new_val - var event_date := _get_current_time() - var update_date := _get_current_time() - - func _generate_random_id() -> String: - # float time - var timestamp := Time.get_unix_time_from_system() - return str(int(timestamp * 10000 + randi_range(0, 10000))) - - func _get_current_time() -> String: - # Returns the current date as a dictionary of keys: year, month, day, and weekday. - var dict = Time.get_date_dict_from_system() - return str(dict["month"]) + "/" + str(dict["day"]) + "/" + str(dict["year"]) - - func duplicate() -> ItemData: - var item := ItemData.new() - item.item_id = item_id - item.log_content = log_content - item.tags = tags.duplicate() - item.event_date = event_date - item.update_date = update_date - return item - - func to_json_dict() -> Dictionary: - # JSON.stringify(self) doesn't work - return { - "item_id": item_id, - "log_content": log_content, - "tags": tags, - "event_date": event_date, - "update_date": update_date, - } - - static func parse(data: Dictionary) -> ItemData: - var item := ItemData.new() - if data.has("item_id"): - item.item_id = data["item_id"] - if data.has("tags"): - item.tags = data["tags"] - if data.has("log_content"): - item.log_content = data["log_content"] - if data.has("event_date"): - item.event_date = data["event_date"] - if data.has("update_date"): - item.update_date = data["update_date"] - return item - - -# {id:{"btn":btn,"key":key,"name":name,"id":id}} -static var tag_btns = {} -static var tag_key_to_id_map = {} - -static var tag_shadow_color = Color.html("1b1b1b") -static var tag_shadow_outline_size = 1 - - -# id->key -var current_tags = {} - -func _ready(): - _load_tag_popup() - reload_btn.pressed.connect(_on_reload_pressed) - #save_btn.pressed.connect(_save_item) - delete_btn.pressed.connect(_remove_signal) - log_content.text_changed.connect(_on_log_content_changed) - call_deferred("_update_signal") - #load_item(original_data) - - -static func _static_init(): - var tag_id := 0 - for tag_type in ProjectLogPanel.TAG_TYPE.values(): - var tag_color = ProjectLogPanel.TAG_TYPE_COLOR_DICT[tag_type] - for tag in ProjectLogPanel.TAG_DICT[tag_type]: - var tag_btn = Button.new() as Button - tag_btn.add_theme_color_override("font_color", tag_color) - tag_btn.add_theme_color_override("font_shadow_color", tag_shadow_color) - tag_btn.add_theme_constant_override("shadow_outline_size", tag_shadow_outline_size) - tag_btn.text = tag - var tag_key = _get_tag_key(tag_type, tag) - tag_btns[tag_id] = {"btn": tag_btn, "id": tag_id, "name": tag, "key": tag_key} - tag_key_to_id_map[tag_key] = tag_id - tag_id += 1 - - -static func _get_tag_key(tag_type: ProjectLogPanel.TAG_TYPE, tag: String): - return str(tag_type) + "@" + tag - - -func _load_tag_popup(): - var popup = add_tag_btn.get_popup() as PopupMenu - for btn_dict in tag_btns.values(): - popup.add_item(btn_dict["name"], btn_dict["id"]) - popup.id_pressed.connect(_on_popup_menu_pressed) - - -func _reload_tag_btns(): - var btn_group = TAG_BTN_GROUP_PREFIX + data.item_id - get_tree().call_group(btn_group, "queue_free") - current_tags.clear() - for tag_key in data["tags"]: - if !tag_key_to_id_map.has(tag_key): - push_error("tag_key has been removed!! tag_key=", tag_key) - continue - var tag_id = tag_key_to_id_map[tag_key] - current_tags[tag_id] = tag_key - var btn = (tag_btns[tag_id]["btn"] as Button).duplicate() - btn.pressed.connect(_on_tag_btn_pressed.bind(btn, tag_id)) - btn.add_to_group(btn_group) - tags_container.add_child(btn) - - -func load_item(new_data: Dictionary): - if new_data.keys().size() != 0: - original_data = ItemData.parse(new_data) - _reload_original_data() - - -func _reload_original_data(): - data = original_data.duplicate() - #print("_load_item_data data=", data) - log_content.text = data.log_content - event_date.text = data.event_date - #update_date.text = data["update_date"] - _reload_tag_btns() - - -func _on_popup_menu_pressed(id: int): - #{"btn":btn,"key":key,"name":name,"id":id} - if !current_tags.has(id): - current_tags[id] = tag_btns[id]["key"] - data.tags = current_tags.values() - _update_signal() - #_save_item() - _reload_tag_btns() - - -func _on_log_content_changed(): - data["log_content"] = log_content.text - _update_signal() - - -func _on_tag_btn_pressed(btn: Control, id: int): - current_tags.erase(id) - btn.queue_free() - data.tags = current_tags.values() - _update_signal() - #_save_item() - - -#func _save_item(): -#save.emit(data) - - -func _update_signal(): - update.emit(data) - - -func _remove_signal(): - remove.emit() - - -func _on_reload_pressed(): - _reload_original_data() - _update_signal() diff --git a/log/logger/project_log_panel_item.gd.uid b/log/logger/project_log_panel_item.gd.uid deleted file mode 100644 index dc0d0a72..00000000 --- a/log/logger/project_log_panel_item.gd.uid +++ /dev/null @@ -1 +0,0 @@ -uid://ce45ux1l1xt5k diff --git a/log/logger/project_log_panel_item.tscn b/log/logger/project_log_panel_item.tscn deleted file mode 100644 index 505c9557..00000000 --- a/log/logger/project_log_panel_item.tscn +++ /dev/null @@ -1,86 +0,0 @@ -[gd_scene load_steps=3 format=3 uid="uid://dhvo15vyxpkja"] - -[ext_resource type="Script" uid="uid://ce45ux1l1xt5k" path="res://log/logger/project_log_panel_item.gd" id="1_gn7ev"] -[ext_resource type="PackedScene" uid="uid://bdy4u3e7rmo7f" path="res://ui/button/sound_button.tscn" id="2_wb6pu"] - -[node name="LogItem" type="HBoxContainer"] -anchors_preset = 14 -anchor_top = 0.5 -anchor_right = 1.0 -anchor_bottom = 0.5 -offset_top = -4.0 -offset_bottom = 4.0 -grow_horizontal = 2 -grow_vertical = 2 -script = ExtResource("1_gn7ev") - -[node name="MarginContainer" type="MarginContainer" parent="."] -layout_mode = 2 -size_flags_horizontal = 3 - -[node name="LogContent" type="TextEdit" parent="MarginContainer"] -unique_name_in_owner = true -layout_mode = 2 -text = "123" -wrap_mode = 1 -scroll_fit_content_height = true - -[node name="HBoxContainer" type="HBoxContainer" parent="."] -layout_mode = 2 - -[node name="TagsContainer" type="GridContainer" parent="HBoxContainer"] -unique_name_in_owner = true -layout_mode = 2 -columns = 2 - -[node name="AddTag" type="MenuButton" parent="HBoxContainer/TagsContainer"] -unique_name_in_owner = true -layout_mode = 2 -text = "Tags" - -[node name="VBoxContainer2" type="VBoxContainer" parent="."] -layout_mode = 2 - -[node name="EventDate" type="Label" parent="VBoxContainer2"] -unique_name_in_owner = true -layout_mode = 2 -theme_override_colors/font_color = Color(0.929412, 0.929412, 0.929412, 1) -theme_override_colors/font_shadow_color = Color(0.105882, 0.105882, 0.105882, 1) -theme_override_constants/shadow_offset_x = 1 -theme_override_constants/shadow_offset_y = 1 -theme_override_constants/shadow_outline_size = 4 -text = "01/01/24" - -[node name="LogUpdateDate" type="Label" parent="VBoxContainer2"] -unique_name_in_owner = true -visible = false -layout_mode = 2 -text = "01/01/24" - -[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer2"] -layout_mode = 2 - -[node name="Reload" parent="VBoxContainer2/HBoxContainer" instance=ExtResource("2_wb6pu")] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 4 -size_flags_vertical = 4 -text = "Reload" -script = null - -[node name="Save" parent="VBoxContainer2/HBoxContainer" instance=ExtResource("2_wb6pu")] -unique_name_in_owner = true -visible = false -layout_mode = 2 -size_flags_horizontal = 4 -size_flags_vertical = 4 -text = "Save" -script = null - -[node name="Delete" parent="VBoxContainer2/HBoxContainer" instance=ExtResource("2_wb6pu")] -unique_name_in_owner = true -layout_mode = 2 -size_flags_horizontal = 4 -size_flags_vertical = 4 -text = "Delete" -script = null diff --git a/push_audio.sh b/push_audio.sh new file mode 100644 index 00000000..00b692ba --- /dev/null +++ b/push_audio.sh @@ -0,0 +1,106 @@ +#!/bin/bash +# =================================================================== +# push_audio.sh +# 仅提交并推送 *.tscn 音效改动到 audio 分支,其它改动会被永久丢弃! +# =================================================================== +# ⚠️ 警告:脚本执行后,非 *.tscn 的本地修改将被 +# ⚠️ git reset --hard + git clean -fd +# ⚠️ 彻底删除且无法找回,请确认没有要保留的改动! +# ------------------------------------------------------------------- + +set -euo pipefail +IFS=$'\n\t' + +REMOTE=origin +BRANCH=audio + +## ------------------------------------------------------------- +color() { printf '\033[%sm%s\033[0m\n' "$1" "$2"; } +info() { color "1;34" "👉 $*"; } # 蓝 +warn() { color "1;33" "⚠️ $*"; } # 黄 +die() { color "1;31" "❌ $*"; exit 1; } # 红 + +## ------------------------------------------------------------- +# 0. 检测 Git、操作系统、确认危险操作 +## ------------------------------------------------------------- +command -v git >/dev/null 2>&1 || die "未安装 Git!" + +git_version=$(git --version | awk '{print $3}') +info "Git 版本:$git_version" + +warn "脚本将丢弃所有非 *.tscn 改动,5 秒内 Ctrl-C 可取消" +sleep 5 + +## ------------------------------------------------------------- +# 1. 认证检查(HTTP/S 及 SSH 两种) +## ------------------------------------------------------------- +info "检查 Git 认证状态..." +remote_url=$(git remote get-url "$REMOTE" 2>/dev/null) \ + || die "远程 $REMOTE 不存在,请先 git remote add" + +if [[ "$remote_url" =~ ^https?:// ]]; then + if ! git ls-remote "$REMOTE" &>/dev/null; then + die "HTTP(S) 鉴权失败,请先完成登录或配置 token 再执行脚本" + fi + info "HTTP(S) 鉴权通过" +else + # SSH:检测是否有可用密钥 + if ! ssh -Tq "$(echo "$remote_url" | sed 's#.*@##;s/:.*##')" 2>&1 \ + | grep -qi "successfully authenticated"; then + warn "SSH 连接测试结果不确定,若后续 push 失败请检查 SSH key" + fi +fi + +## ------------------------------------------------------------- +# 2. 切换到 audio 分支 +## ------------------------------------------------------------- +current_branch=$(git rev-parse --abbrev-ref HEAD) +if [[ "$current_branch" != "$BRANCH" ]]; then + info "切换分支 $current_branch → $BRANCH ..." + git switch "$BRANCH" 2>/dev/null || git checkout "$BRANCH" \ + || die "切换失败,请确认分支 $BRANCH 存在" +fi + +## ------------------------------------------------------------- +# 3. 仅暂存 / 提交 *.tscn 改动 +## ------------------------------------------------------------- +info "检测 *.tscn 改动..." + +# 取消任何已暂存的内容,保持工作区状态不变 +git reset --quiet + +# 标记并暂存 tscn 文件(包括新增) +git add -u -- '*.tscn' 2>/dev/null || true +git add --intent-to-add -- '*.tscn' 2>/dev/null || true +git add -- '*.tscn' 2>/dev/null || true + +if git diff --cached --quiet; then + info "没有需要提交的 tscn 改动" +else + msg="调整音效 dB – $(date '+%F %H:%M')" + git commit -m "$msg" + info "已提交:$msg" +fi + +## ------------------------------------------------------------- +# 4. 丢弃其它改动 +## ------------------------------------------------------------- +info "丢弃非 *.tscn 的本地改动..." +git reset --hard # 回到 HEAD +git clean -fdq # 删除未跟踪文件/目录 + +## ------------------------------------------------------------- +# 5. 拉取远程最新并 rebase +## ------------------------------------------------------------- +info "拉取远程最新并 rebase..." +if ! git pull --rebase "$REMOTE" "$BRANCH"; then + die "rebase 冲突,请手动解决完毕后运行:\n git rebase --continue\n再重新执行脚本" +fi + +## ------------------------------------------------------------- +# 6. 推送 +## ------------------------------------------------------------- +info "推送到 $REMOTE/$BRANCH ..." +git push "$REMOTE" "$BRANCH" || die "推送失败,请检查网络/权限" + +color "1;32" "✅ tscn 改动已成功推送,其余改动已被抛弃" \ No newline at end of file diff --git a/scene/ground/scene/c02/s06_二楼.tscn b/scene/ground/scene/c02/s06_二楼.tscn index 59ba54a8..0f36fd75 100644 --- a/scene/ground/scene/c02/s06_二楼.tscn +++ b/scene/ground/scene/c02/s06_二楼.tscn @@ -342,7 +342,9 @@ animation = &"疯子跑动" autostart = false action_configs = Array[Dictionary]([{ "animation_intro": "疯子跪下", -&"animation_next": "疯子撞墙" +&"animation_next": "疯子撞墙", +"animation_wait_time": 0.0, +"intro_loop": 1 }]) [node name="疯子撞墙Sfx2D" type="AudioStreamPlayer2D" parent="Ground/DeployLayer/疯子撞墙"] @@ -381,6 +383,7 @@ position = Vector2(289, 16) packed_scene = ExtResource("16_p6da7") [node name="c02_final" type="Node2D" parent="Ground/DeployLayer" index="12"] +visible = false [node name="瞎子" parent="Ground/DeployLayer/c02_final" instance=ExtResource("10_p6da7")] position = Vector2(277, 29) diff --git a/scene/ground/scene/c02/s12_盒子猫.tscn b/scene/ground/scene/c02/s12_盒子猫.tscn index a99a4031..eee0a239 100644 --- a/scene/ground/scene/c02/s12_盒子猫.tscn +++ b/scene/ground/scene/c02/s12_盒子猫.tscn @@ -1,10 +1,9 @@ -[gd_scene load_steps=6 format=3 uid="uid://da4cuf2i3nwpj"] +[gd_scene load_steps=5 format=3 uid="uid://da4cuf2i3nwpj"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_ngo77"] [ext_resource type="Script" uid="uid://cyd1xo106unfk" path="res://scene/ground/scene/c02/s12_animation.gd" id="2_7ah3n"] [ext_resource type="Texture2D" uid="uid://yn00uls1kvn3" path="res://asset/art/scene/c02/s12_to_s17_盒子猫/bg_初始.png" id="3_oskpk"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="6_oskpk"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="7_72mc1"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="4_vv3sh"] [node name="S12" type="Node2D"] @@ -12,7 +11,6 @@ scene_name = "c02_s12" player_y = 85 footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_7ah3n") @@ -42,24 +40,6 @@ position = Vector2(3584, -7) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 400, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("6_oskpk") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("7_72mc1") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("4_vv3sh")] [editable path="Ground"] diff --git a/scene/ground/scene/c02/s13_盒子猫二楼.tscn b/scene/ground/scene/c02/s13_盒子猫二楼.tscn index ca60c756..e5f1c1d7 100644 --- a/scene/ground/scene/c02/s13_盒子猫二楼.tscn +++ b/scene/ground/scene/c02/s13_盒子猫二楼.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=9 format=3 uid="uid://bvjutch6jex0v"] +[gd_scene load_steps=8 format=3 uid="uid://bvjutch6jex0v"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_71lma"] [ext_resource type="Script" uid="uid://28ujp27cbdh2" path="res://scene/ground/scene/c02/s13_animation.gd" id="2_w5nqu"] @@ -6,15 +6,13 @@ [ext_resource type="Texture2D" uid="uid://b3ootg88b63rb" path="res://asset/art/scene/c02/旧版/s13_院子诡异版/fg_楼梯调色后.png" id="4_4adgb"] [ext_resource type="PackedScene" uid="uid://61pis75a8fdq" path="res://scene/entity/portal.tscn" id="4_u2fv1"] [ext_resource type="PackedScene" uid="uid://jr1yd46wm5je" path="res://scene/entity/note.tscn" id="5_gge8e"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="5_miykx"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="6_u2fv1"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="7_u2fv1"] [node name="S13" type="Node2D"] [node name="Ground" parent="." instance=ExtResource("1_71lma")] scene_name = "c02_s13" footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_w5nqu") @@ -45,6 +43,8 @@ status = "opened" position = Vector2(852, 0) note_key = "notes_无法通过" +[node name="Sprite2D" type="Sprite2D" parent="Ground/DeployLayer" index="4"] + [node name="MainPlayer" parent="Ground" index="4"] character = "盒子猫" @@ -59,24 +59,6 @@ scale = Vector2(1.05, 1.05) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 870, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("5_miykx") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("6_u2fv1") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("7_u2fv1")] [editable path="Ground"] diff --git a/scene/ground/scene/c02/s14_盒子猫二楼内侧.tscn b/scene/ground/scene/c02/s14_盒子猫二楼内侧.tscn index 17109fe9..c7403444 100644 --- a/scene/ground/scene/c02/s14_盒子猫二楼内侧.tscn +++ b/scene/ground/scene/c02/s14_盒子猫二楼内侧.tscn @@ -1,18 +1,16 @@ -[gd_scene load_steps=7 format=3 uid="uid://d0p4x5st2r315"] +[gd_scene load_steps=6 format=3 uid="uid://d0p4x5st2r315"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_cr1hi"] [ext_resource type="Script" uid="uid://bjisuntcem2lv" path="res://scene/ground/scene/c02/s14_animation.gd" id="2_o47bv"] [ext_resource type="Texture2D" uid="uid://y0e47513ca22" path="res://asset/art/scene/c02/s12_to_s17_盒子猫/bg_二楼内侧楼道(粉笔画).png" id="3_cr1hi"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="4_kss0n"] [ext_resource type="PackedScene" uid="uid://61pis75a8fdq" path="res://scene/entity/portal.tscn" id="4_o47bv"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="5_3yfjs"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="5_cr1hi"] [node name="S14" type="Node2D"] [node name="Ground" parent="." instance=ExtResource("1_cr1hi")] scene_name = "c02_s14" footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_o47bv") @@ -44,24 +42,6 @@ character = "盒子猫" [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 660, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("4_kss0n") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("5_3yfjs") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("5_cr1hi")] [editable path="Ground"] diff --git a/scene/ground/scene/c02/s15_盒子猫一楼内侧.tscn b/scene/ground/scene/c02/s15_盒子猫一楼内侧.tscn index 66100fad..13894c62 100644 --- a/scene/ground/scene/c02/s15_盒子猫一楼内侧.tscn +++ b/scene/ground/scene/c02/s15_盒子猫一楼内侧.tscn @@ -1,11 +1,10 @@ -[gd_scene load_steps=7 format=3 uid="uid://b21p53g42j2nt"] +[gd_scene load_steps=6 format=3 uid="uid://b21p53g42j2nt"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_qxg0l"] [ext_resource type="Script" uid="uid://ebaq235h32fd" path="res://scene/ground/scene/c02/s15_animation.gd" id="2_etqjj"] [ext_resource type="Texture2D" uid="uid://c4eb71kdnqy3y" path="res://asset/art/scene/c02/s12_to_s17_盒子猫/bg_一楼内侧楼道(粉笔画).png" id="3_qxg0l"] [ext_resource type="PackedScene" uid="uid://jr1yd46wm5je" path="res://scene/entity/note.tscn" id="4_etqjj"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="5_n8ki2"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="6_e2r11"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="5_isic3"] [node name="S15" type="Node2D"] @@ -13,7 +12,6 @@ scene_name = "c02_s15" player_y = 60 footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_etqjj") @@ -46,24 +44,6 @@ position = Vector2(-1, -15) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 660, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("5_n8ki2") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("6_e2r11") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("5_isic3")] [editable path="Ground"] diff --git a/scene/ground/scene/c02/s16_盒子猫三楼内侧.tscn b/scene/ground/scene/c02/s16_盒子猫三楼内侧.tscn index 0bc779e6..62d8fcc0 100644 --- a/scene/ground/scene/c02/s16_盒子猫三楼内侧.tscn +++ b/scene/ground/scene/c02/s16_盒子猫三楼内侧.tscn @@ -1,11 +1,10 @@ -[gd_scene load_steps=7 format=3 uid="uid://22hc3oe8t0id"] +[gd_scene load_steps=6 format=3 uid="uid://22hc3oe8t0id"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_umyae"] [ext_resource type="Script" uid="uid://dx2w5v1erjyls" path="res://scene/ground/scene/c02/s16_animation.gd" id="2_tmnwc"] [ext_resource type="Texture2D" uid="uid://by4ymjhnma8c6" path="res://asset/art/scene/c02/s12_to_s17_盒子猫/bg_三楼内侧楼道(粉笔画).png" id="3_tmnwc"] [ext_resource type="PackedScene" uid="uid://61pis75a8fdq" path="res://scene/entity/portal.tscn" id="4_qkv3g"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="4_x2r6c"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="5_5kc5g"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="5_tmnwc"] [node name="S16" type="Node2D"] @@ -13,7 +12,6 @@ scene_name = "c02_s16" player_y = 85 footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_tmnwc") @@ -48,24 +46,6 @@ position = Vector2(3584, -7) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 655, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("4_x2r6c") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("5_5kc5g") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("5_tmnwc")] [editable path="Ground"] diff --git a/scene/ground/scene/c02/s17_盒子猫三楼.tscn b/scene/ground/scene/c02/s17_盒子猫三楼.tscn index 066b4e1c..3f2cfe70 100644 --- a/scene/ground/scene/c02/s17_盒子猫三楼.tscn +++ b/scene/ground/scene/c02/s17_盒子猫三楼.tscn @@ -1,10 +1,9 @@ -[gd_scene load_steps=6 format=3 uid="uid://cbr6gbgrl2wb1"] +[gd_scene load_steps=5 format=3 uid="uid://cbr6gbgrl2wb1"] [ext_resource type="PackedScene" uid="uid://dayyx4jerj7io" path="res://scene/ground/ground.tscn" id="1_e436a"] [ext_resource type="Script" uid="uid://bkkhxiyblu2lo" path="res://scene/ground/scene/c02/s17_animation.gd" id="2_e436a"] [ext_resource type="Texture2D" uid="uid://iyeqjguyrhog" path="res://asset/art/scene/c02/s12_to_s17_盒子猫/bg_三楼楼道(粉笔画).png" id="3_e436a"] -[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="4_uua76"] -[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="5_4yexs"] +[ext_resource type="PackedScene" uid="uid://khwxm5qbfj3k" path="res://scene/ground/script/c02/盒子猫canvas_layer.tscn" id="4_n3bxc"] [node name="S17" type="Node2D"] @@ -12,7 +11,6 @@ scene_name = "c02_s17" player_y = 85 footstep_type = "盒子猫" -main_scene = null [node name="AnimationPlayer" parent="Ground" index="0"] script = ExtResource("2_e436a") @@ -43,24 +41,6 @@ position = Vector2(3584, -7) [node name="PlayerLine2D" parent="Ground/ParallaxForeground" index="2"] points = PackedVector2Array(37, 150, 860, 150) -[node name="CanvasLayer" type="CanvasLayer" parent="Ground"] -layer = 0 - -[node name="TextureRect" type="TextureRect" parent="Ground/CanvasLayer"] -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("4_uua76") - -[node name="TextureRect2" type="TextureRect" parent="Ground/CanvasLayer"] -modulate = Color(1, 1, 1, 0.380392) -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 -texture = ExtResource("5_4yexs") +[node name="盒子猫CanvasLayer" parent="Ground" instance=ExtResource("4_n3bxc")] [editable path="Ground"] diff --git a/scene/ground/script/c02/盒子猫canvas_layer.gd b/scene/ground/script/c02/盒子猫canvas_layer.gd new file mode 100644 index 00000000..7a1695f7 --- /dev/null +++ b/scene/ground/script/c02/盒子猫canvas_layer.gd @@ -0,0 +1,4 @@ +extends CanvasLayer + +func _ready(): + visible = true \ No newline at end of file diff --git a/scene/ground/script/c02/盒子猫canvas_layer.gd.uid b/scene/ground/script/c02/盒子猫canvas_layer.gd.uid new file mode 100644 index 00000000..e6c35747 --- /dev/null +++ b/scene/ground/script/c02/盒子猫canvas_layer.gd.uid @@ -0,0 +1 @@ +uid://ngb7wh7mqo0c diff --git a/scene/ground/script/c02/盒子猫canvas_layer.tscn b/scene/ground/script/c02/盒子猫canvas_layer.tscn new file mode 100644 index 00000000..bf826aa2 --- /dev/null +++ b/scene/ground/script/c02/盒子猫canvas_layer.tscn @@ -0,0 +1,26 @@ +[gd_scene load_steps=4 format=3 uid="uid://khwxm5qbfj3k"] + +[ext_resource type="Texture2D" uid="uid://xhksp8eu3jqy" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写_镂空.png" id="1_tgkyo"] +[ext_resource type="Script" uid="uid://ngb7wh7mqo0c" path="res://scene/ground/script/c02/盒子猫canvas_layer.gd" id="1_ygosu"] +[ext_resource type="Texture2D" uid="uid://d1seskftkw08q" path="res://asset/art/scene/c02/s08_瞎子卧室/墙上纸张特写/特写示意图.png" id="2_ygosu"] + +[node name="盒子猫CanvasLayer" type="CanvasLayer"] +layer = 0 +script = ExtResource("1_ygosu") + +[node name="TextureRect" type="TextureRect" parent="."] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("1_tgkyo") + +[node name="TextureRect2" type="TextureRect" parent="."] +modulate = Color(1, 1, 1, 0.380392) +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("2_ygosu")