From ad611ef593ef9cd3575f18a695aea1ef08857184 Mon Sep 17 00:00:00 2001 From: Dennis Postma Date: Sun, 16 Feb 2025 17:19:19 +0100 Subject: [PATCH] Send new location as array instead of object --- src/composables/controls/useGameControlsComposable.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/composables/controls/useGameControlsComposable.ts b/src/composables/controls/useGameControlsComposable.ts index 8f9f6d1..4d6aef0 100644 --- a/src/composables/controls/useGameControlsComposable.ts +++ b/src/composables/controls/useGameControlsComposable.ts @@ -42,10 +42,7 @@ export function useGameControlsComposable(scene: Phaser.Scene, layer: Phaser.Til function emitMovement(x: number, y: number) { if (x === currentPosition.x && y === currentPosition.y) return - gameStore.connection?.emit(SocketEvent.MAP_CHARACTER_MOVE, { - positionX: x, - positionY: y - }) + gameStore.connection?.emit(SocketEvent.MAP_CHARACTER_MOVE, [x, y]) currentPosition = { x, y } }