mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-30 16:01:53 +08:00
refactor(武器系统): 重构武器能量消耗机制
移除全局武器升级能量消耗倍数,改为各武器独立设置升级能量消耗 调整矢量核心武器的属性计算和初始能量值 为所有武器类型添加升级时的能量消耗增量
This commit is contained in:
@@ -5,6 +5,7 @@ class_name BigLaserWeapon
|
||||
func update(to: int, origin: Dictionary, _entity: EntityBase):
|
||||
origin["atk"] += 5 * to * soulLevel
|
||||
origin["time"] /= 1 + 0.05 * to * soulLevel
|
||||
needEnergy += 5
|
||||
return origin
|
||||
func attack(entity: EntityBase):
|
||||
var weaponPos = entity.findWeaponAnchor("normal")
|
||||
|
||||
@@ -8,6 +8,7 @@ func update(to: int, origin: Dictionary, _entity: EntityBase):
|
||||
origin["power"] += 0.05 * to * soulLevel
|
||||
origin["trace"] += 0.25 * to * soulLevel
|
||||
origin["angle"] /= 1 + 0.05 * to * soulLevel
|
||||
needEnergy += 1
|
||||
return origin
|
||||
func attack(entity: EntityBase):
|
||||
var weaponPos = entity.findWeaponAnchor("normal")
|
||||
|
||||
@@ -5,6 +5,7 @@ func update(to: int, origin: Dictionary, _entity: EntityBase):
|
||||
origin["atk"] += 1 * to * soulLevel
|
||||
origin["rate"] += 0.04 * to * soulLevel
|
||||
origin["count"] += 1 * to * soulLevel
|
||||
needEnergy += 0.5
|
||||
return origin
|
||||
func attack(entity: EntityBase):
|
||||
var weaponPos = entity.findWeaponAnchor("normal")
|
||||
|
||||
@@ -5,7 +5,9 @@ class_name VectorStarWeapon
|
||||
func update(to: int, origin: Dictionary, _entity: EntityBase):
|
||||
origin["atk"] += 5 * to * soulLevel
|
||||
origin["forwardtime"] /= 1 + 0.05 * to * soulLevel
|
||||
origin["maxcount"] += 1 * to * soulLevel
|
||||
origin["mincount"] += 0.5 * to * soulLevel
|
||||
origin["maxcount"] += 1.5 * to * soulLevel
|
||||
needEnergy += 2
|
||||
return origin
|
||||
func attack(entity: EntityBase):
|
||||
var weaponPos = entity.findWeaponAnchor("normal")
|
||||
|
||||
@@ -79,7 +79,6 @@ func apply(entity: EntityBase):
|
||||
entity.inventory[ItemStore.ItemType.BEACHBALL] -= costBeachball
|
||||
updateStore(level, entity)
|
||||
costBeachball = floor(GameRule.weaponUpdateCost * costBeachball)
|
||||
needEnergy = GameRule.weaponUpdateEnergy * needEnergy
|
||||
rebuildInfo()
|
||||
return allHave
|
||||
func updateStore(to: int, entity: EntityBase):
|
||||
|
||||
@@ -21,4 +21,3 @@ static var critRateInfluenceByLuckValue: float = MathTool.percent(2.5) # 幸运
|
||||
static var penerateRateInfluenceByLuckValue: float = MathTool.percent(3) # 幸运值对穿透率的影响
|
||||
static var detainTime: float = 1000 # 血量如果在这个时间内没有改变才会开始播放降低动画
|
||||
static var weaponUpdateCost: float = 1.5 # 武器升级后消耗的棒球数量倍数
|
||||
static var weaponUpdateEnergy: float = 1.01 # 武器升级后消耗的能量倍数
|
||||
|
||||
Reference in New Issue
Block a user