#363 : Moved socket logic into socketManager and removed it from Pinia store

This commit is contained in:
2025-02-17 01:17:02 +01:00
parent 0c61fe77de
commit a6d6d894a9
30 changed files with 196 additions and 114 deletions

View File

@ -20,6 +20,7 @@
<script setup lang="ts">
import config from '@/application/config'
import { SocketEvent } from '@/application/enums'
import { socketManager } from '@/managers/SocketManager'
import 'phaser'
import type { Map as MapT } from '@/application/types'
import Map from '@/components/gameMaster/mapEditor/Map.vue'
@ -92,7 +93,7 @@ function save() {
mapId: currentMap.id
}
gameStore.connection?.emit(SocketEvent.GM_MAP_UPDATE, data, (response: MapT) => {
socketManager.emit(SocketEvent.GM_MAP_UPDATE, data, (response: MapT) => {
mapStorage.update(response.id, response)
})
}