fix near enemy kick, fix huge kick on low tier

This commit is contained in:
2026-04-23 11:48:00 +03:00
parent 1b3732ea0f
commit e956c4353c
2 changed files with 7 additions and 3 deletions
+2 -2
View File
@@ -159,9 +159,9 @@ func _do_kick() -> void:
var diff := en.global_position - global_position
diff.y = 0.0
var dist := diff.length()
if dist < 0.1 or dist > kick_range:
if dist < 0.01 or dist > kick_range:
continue
if (diff / dist).dot(forward) >= half_cos:
if dist < 1.0 or (diff / dist).dot(forward) >= half_cos:
candidates.append(en)
candidate_dists.append(dist)