mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-06-12 14:47:13 +08:00
fix(Characters): 修复Bear冲刺时未检查boss有效性的问题
修复Bear.gd中sprint函数未检查currentFocusedBoss是否有效的问题,避免潜在崩溃 调整TickTool.gd中until方法的frame调用方式 修改Wave.gd测试环境下的初始波次配置
This commit is contained in:
@@ -122,8 +122,8 @@ func attack(type):
|
||||
return false
|
||||
return true
|
||||
func sprint():
|
||||
var dir = sign((currentFocusedBoss.position - position).x)
|
||||
velocity = Vector2(dir, 0)
|
||||
if is_instance_valid(currentFocusedBoss):
|
||||
velocity = Vector2(sign((currentFocusedBoss.position - position).x), 0)
|
||||
func sprintAi():
|
||||
velocity.x *= 1.2
|
||||
return abs(velocity.x) >= 1000000
|
||||
|
||||
Reference in New Issue
Block a user