fx: sprite playing behaviour

This commit is contained in:
2026-03-01 15:43:06 +01:00
parent 9dd1d45698
commit 241dfb3073
7 changed files with 8 additions and 6 deletions

View File

@@ -78,7 +78,6 @@ func get_new_flow():
func calc_distance(one, two) -> float:
var candidate = one.distance_to(two)
var onedup = one
# FIXME: doesnt work-- predators lose track across game boundary
if one.x < screen_size.x/2:
if one.y < screen_size.y/2:
# top left
@@ -103,7 +102,7 @@ func calc_distance(one, two) -> float:
onedup.x += screen_size.x
candidate = min(candidate, onedup.distance_to(two))
else:
# botom right
# bottom right
onedup.y += screen_size.y
candidate = min(candidate, onedup.distance_to(two))
onedup.y -= screen_size.y