Replaced all event names with numbers for less bandwidth usage
This commit is contained in:
@ -18,6 +18,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { SocketEvent } from '@/application/enums';
|
||||
import config from '@/application/config'
|
||||
import 'phaser'
|
||||
import type { Map as MapT } from '@/application/types'
|
||||
@ -97,7 +98,7 @@ function save() {
|
||||
placedMapObjects: currentMap.placedMapObjects.map(({ id, mapObject, isRotated, positionX, positionY }) => ({ id, mapObject, isRotated, positionX, positionY })) ?? []
|
||||
}
|
||||
|
||||
gameStore.connection?.emit('gm:map:update', data, (response: MapT) => {
|
||||
gameStore.connection?.emit(SocketEvent.GM_MAP_UPDATE, data, (response: MapT) => {
|
||||
mapStorage.update(response.id, response)
|
||||
})
|
||||
}
|
||||
|
Reference in New Issue
Block a user