From bce6d2495b137ae3fe6b3787986dd6787a551f87 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Fri, 30 May 2025 16:01:53 +0200 Subject: test-client: restore old interact target behaviour. new behav is opt-in --- test-client/main.ts | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'test-client') diff --git a/test-client/main.ts b/test-client/main.ts index 946b933e..f52e7f40 100644 --- a/test-client/main.ts +++ b/test-client/main.ts @@ -377,6 +377,13 @@ export function get_interact_target(): V2 | undefined { if (interacting) return interacting const me = players.get(my_id) if (!me) return + + if (location.hash.search("newinteract") == -1) + return { + x: Math.floor(me.position.x + Math.sin(me.rot)), + y: Math.floor(me.position.y + Math.cos(me.rot)) + } + const rx = me.position.x + Math.sin(me.rot) * 0.7 const ry = me.position.y + Math.cos(me.rot) * 0.7 const bx = Math.floor(rx) -- cgit v1.2.3-70-g09d2