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/LGBTWeapon.gd
T
fallingshrimp f2287d6ee7 feat(武器): 添加LGBT武器及其脚本实现
添加LGBT武器场景和对应的GD脚本,实现武器攻击逻辑和属性更新功能。武器发射可追踪的彩虹激光并提升攻击属性。
2025-09-06 08:08:19 +08:00

12 lines
403 B
GDScript

extends Weapon
class_name LGBTWeapon
func update(to: int, origin: Dictionary, _entity: EntityBase):
origin["atk"] += 5 * to
origin["time"] /= 1.1
return origin
func attack(entity: EntityBase):
var weaponPos = entity.findWeaponAnchor("normal")
BulletBase.generate(preload("res://components/Bullets/BigLaser.tscn"), entity, weaponPos, (get_global_mouse_position() - weaponPos).angle())
return true