1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-27 22:41:56 +08:00
Files
Dog-Lynx-And-HCN/scripts/Contents/Panels/WeaponPanel.gd
T
fallingshrimp aec1db5088 feat(武器系统): 添加武器升华功能并优化相关代码
- 在Weapon.gd中添加sublimateToggled信号
- 为武器添加默认的升华选项"强化攻击"
- 优化WeaponPanel.gd中的变量类型声明
- 修改Tree.gd中的描述文本使其更准确
2026-05-10 12:14:27 +08:00

17 lines
402 B
GDScript

@tool
extends FullscreenPanelBase
@onready var box: Control = $%box
func beforeOpen(_args: Array = []):
for weapon in UIState.player.weapons:
weapon.show()
weapon.rebuildInfo()
UIState.player.weaponStore.remove_child(weapon)
box.add_child(weapon)
func afterClose():
for weapon in box.get_children():
weapon.hide()
box.remove_child(weapon)
UIState.player.weaponStore.add_child(weapon)