fx: sprite playing behaviour

This commit is contained in:
djaidjai committed 2026-03-01 15:43:13 +01:00
1 parent 9dd1d45698
commit 241dfb3073
7 files changed
+8 -6

No files matched your search

+1 -2
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
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.