1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-28 06:51:54 +08:00
Files
fallingshrimp 1b3df9727a feat(武器系统): 重构武器升华动画及交互逻辑
- 将sublimateToggled信号拆分为sublimateOpened和sublimateClosed
- 添加武器卡片的hide/show动画效果
- 移除MuyangDog角色中的Volcano武器
- 重置EntityBase中钻石的初始数量为0
- 为CategoryStore添加@tool注解
2026-05-10 12:40:15 +08:00

29 lines
676 B
GDScript

@tool
extends FullscreenPanelBase
@onready var box: Control = $%box
func beforeOpen(_args: Array = []):
for weapon in UIState.player.weapons:
weapon.show()
weapon.rebuildInfo()
weapon.sublimateOpened.connect(
func():
for w in UIState.player.weapons:
if w != weapon:
w.animator.play("hide")
)
weapon.sublimateClosed.connect(
func():
for w in UIState.player.weapons:
if w != weapon:
w.animator.play("show")
)
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)