1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-28 06:51:54 +08:00
Files
Dog-Lynx-And-HCN/scripts/Contents/Weapons/Gobo.gd
T
fallingshrimp 4302055086 refactor(武器卡片): 重构武器卡片节点结构,将名称节点移至displays容器
统一将武器卡片的名称节点从container/info移动到container/info/displays容器中,提高代码组织性
同时清理了部分调试属性和冗余代码,更新了部分武器的来源信息
2026-04-04 09:03:58 +08:00

17 lines
501 B
GDScript

@tool
extends Weapon
func update(to: int, origin: Dictionary, _entity: EntityBase):
origin["health"] += 5 * to * soulLevel
origin["percent"] += 0.02 * to * soulLevel
origin["count"] *= to * soulLevel
return origin
func attack(entity: EntityBase):
var gobo = entity.summon(ComponentManager.getSummon("Gobo"))
if gobo is GoboSummon:
gobo.targetDamage = readStore("atk")
gobo.percent = readStore("percent")
gobo.count = readStore("count")
gobo.initHealth(readStore("health"))
return true