1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-06-03 09:51:53 +08:00

feat(武器): 调整火山武器的属性和生成逻辑

修改火山武器的攻击力、旋转速度、生命值和子弹数量等基础属性
优化子弹生成逻辑,新增ignoreOffset参数控制偏移
更新武器配置和描述文本以匹配新数值
This commit is contained in:
2025-11-15 20:18:04 +08:00
parent 803511523c
commit d898620c7a
3 changed files with 14 additions and 12 deletions
+3 -2
View File
@@ -151,7 +151,8 @@ static func generate(
spawnRotation: float,
asChildSplit: bool = false,
asChildRefract: bool = false,
addToWorld: bool = true
addToWorld: bool = true,
ignoreOffset: bool = false
):
var extraCount = launchBy.fields.get(FieldStore.Entity.EXTRA_BULLET_COUNT)
var count = 1 + MathTool.shrimpRate(extraCount)
@@ -162,7 +163,7 @@ static func generate(
instance.isChildRefract = asChildRefract
instance.launcher = launchBy
instance.position = spawnPosition
instance.rotation = spawnRotation + deg_to_rad(randf_range(-launchBy.fields.get(FieldStore.Entity.OFFSET_SHOOT), launchBy.fields.get(FieldStore.Entity.OFFSET_SHOOT)))
instance.rotation = spawnRotation + deg_to_rad(launchBy.fields.get(FieldStore.Entity.OFFSET_SHOOT) * randf_range(-1, 1) * int(!ignoreOffset))
if addToWorld:
WorldManager.rootNode.call_deferred("add_child", instance)
instance.add_to_group("bullets")