aboutsummaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2025-06-19 20:35:45 +0200
committermetamuffin <metamuffin@disroot.org>2025-06-19 20:35:45 +0200
commitfe1695ef4857448f06d388a9b172aeeca364ef63 (patch)
treef0c72b0de01ba2aa7c305d743e8b616c988019f8 /client
parent05fe59c831a5f1b7f0666d617f275a86a6ce4d35 (diff)
downloadhurrycurry-fe1695ef4857448f06d388a9b172aeeca364ef63.tar
hurrycurry-fe1695ef4857448f06d388a9b172aeeca364ef63.tar.bz2
hurrycurry-fe1695ef4857448f06d388a9b172aeeca364ef63.tar.zst
Fix bug in interact target logic where only 2x2 grid was tested
Diffstat (limited to 'client')
-rw-r--r--client/player/controllable_player.gd4
1 files changed, 2 insertions, 2 deletions
diff --git a/client/player/controllable_player.gd b/client/player/controllable_player.gd
index 126e4c10..b8057348 100644
--- a/client/player/controllable_player.gd
+++ b/client/player/controllable_player.gd
@@ -253,8 +253,8 @@ func get_interact_target() -> Array: # -> [visual_target: Vector3, tile_target:
# Test all tiles in a 3x3 square around the player for interactible tiles.
# Return the one which is closest to interact_target.
- for offset_x in range(-1,1):
- for offset_y in range (-1, 1):
+ for offset_x in range(-1,2):
+ for offset_y in range (-1, 2):
var offset_cursor := interact_target_i + Vector2(offset_x, offset_y)
var tile_center := Vector2(offset_cursor) + Vector2(0.5, 0.5)