diff --git a/src/components/utilities/zoneEditor/CreateZone.vue b/src/components/utilities/zoneEditor/CreateZone.vue index 36ba100..1dd044a 100644 --- a/src/components/utilities/zoneEditor/CreateZone.vue +++ b/src/components/utilities/zoneEditor/CreateZone.vue @@ -38,7 +38,7 @@ import Modal from '@/components/utilities/Modal.vue' import { useSocketStore } from '@/stores/socket' import { useZoneEditorStore } from '@/stores/zoneEditor' -const emit = defineEmits(['submit']) +const emit = defineEmits(['submitForm']) const socket = useSocketStore() const zoneEditorStore = useZoneEditorStore() @@ -46,10 +46,9 @@ const name = ref('') const width = ref(0) const height = ref(0) -const submit = () => { +function submit() { socket.connection.emit('gm:zone_editor:zone:create', { name: name.value, width: width.value, height: height.value }, () => {}) - zoneEditorStore.toggleCreateZoneModal() - emit('submit') + emit('submitForm') } diff --git a/src/components/utilities/zoneEditor/ZoneList.vue b/src/components/utilities/zoneEditor/ZoneList.vue index bb0d310..265055a 100644 --- a/src/components/utilities/zoneEditor/ZoneList.vue +++ b/src/components/utilities/zoneEditor/ZoneList.vue @@ -1,5 +1,5 @@