1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-31 00:11:54 +08:00

feat(角色): 添加Gobo角色及相关资源

添加Gobo角色,包括武器、召唤物和治疗导弹功能
- 新增Gobo角色模型和动画资源
- 实现Gobo武器系统,可召唤Gobo单位
- 添加治疗导弹功能,Gobo受伤时会发射治疗友军
- 优化实体基础类,添加生命值初始化方法
- 修改子弹伤害判定逻辑,支持友军伤害设置
This commit is contained in:
2026-01-28 20:20:55 +08:00
parent df661d38e5
commit 4990a3e300
22 changed files with 410 additions and 9 deletions
+13
View File
@@ -0,0 +1,13 @@
@tool
extends Weapon
func update(to: int, origin: Dictionary, _entity: EntityBase):
origin["health"] += 5 * to * soulLevel
origin["percent"] += 0.02 * to * soulLevel
return origin
func attack(entity: EntityBase):
var gobo = entity.summon(ComponentManager.getSummon("Gobo"))
if gobo is GoboSummon:
gobo.percent = readStore("percent")
gobo.initHealth(readStore("health"))
return true
+1
View File
@@ -0,0 +1 @@
uid://cbg3xkg1giv35
+2 -3
View File
@@ -7,7 +7,6 @@ func update(to: int, origin: Dictionary, _entity: EntityBase):
return origin
func attack(entity: EntityBase):
var summon = entity.summon(ComponentManager.getSummon("Shield"))
if !summon: return true
summon.fields[FieldStore.Entity.MAX_HEALTH] = readStore("atk")
summon.health = summon.fields[FieldStore.Entity.MAX_HEALTH]
if summon:
summon.initHealth(readStore("atk"))
return true