mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-27 22:41:56 +08:00
73adc34aef
- 为LGBTFlag添加500点最大生命值 - 调整NuclearBomb的旋转逻辑和AcidBulletBase的移动行为 - 重写WhiteSoul子弹逻辑,增加随机大小和速度 - 修改Oxygener武器,允许使用能量替代篮球消耗 - 更新多个场景文件,优化属性和描述
35 lines
1.1 KiB
GDScript
35 lines
1.1 KiB
GDScript
@tool
|
|
extends Weapon
|
|
|
|
func update(to: int, origin: Dictionary, _entity: EntityBase):
|
|
origin["atk"] += 1 * to * soulLevel
|
|
origin["fireatk"] += 0.5 * to * soulLevel
|
|
origin["max-n"] += 2 * (soulLevel - 1)
|
|
origin["count"] *= soulLevel
|
|
return origin
|
|
func checkAttack(entity: EntityBase) -> bool:
|
|
return entity.hasItem({ItemStore.ItemType.BASKETBALL: 1.0 / readStore("count")}) || entity.isEnergyEnough(5)
|
|
func attack(entity: EntityBase):
|
|
if !entity.useItem({ItemStore.ItemType.BASKETBALL: 1.0 / readStore("count")}):
|
|
entity.useEnergy(5)
|
|
for bullet in BulletBase.generate(
|
|
ComponentManager.getBullet("OxygenFire"),
|
|
entity,
|
|
entity.findWeaponAnchor("normal"),
|
|
entity.position.angle_to_point(get_global_mouse_position()),
|
|
):
|
|
if bullet is OxygenFire:
|
|
bullet.baseDamage = readStore("fireatk")
|
|
if MathTool.rate(0.1):
|
|
for i in randi_range(readStore("min-n"), readStore("max-n")):
|
|
for n in BulletBase.generate(
|
|
ComponentManager.getBullet("AcidN"),
|
|
entity,
|
|
bullet.position,
|
|
0,
|
|
):
|
|
if n is AcidN:
|
|
n.baseDamage = readStore("atk")
|
|
n.storm = bullet
|
|
return true
|