This commit is contained in:
wass08
2026-01-27 09:25:40 +09:00
parent fd4c097d5b
commit e3e3602d91
19 changed files with 612 additions and 19 deletions
+3 -1
View File
@@ -1,6 +1,6 @@
import type { ThreeEvent } from '@react-three/fiber'
import mitt from 'mitt'
import type { BuildingNode, ItemNode, SlabNode, WallNode, ZoneNode } from '../schema'
import type { BuildingNode, CeilingNode, ItemNode, SlabNode, WallNode, ZoneNode } from '../schema'
import type { AnyNode } from '../schema/types'
// Base event interfaces
@@ -23,6 +23,7 @@ export type ItemEvent = NodeEvent<ItemNode>
export type BuildingEvent = NodeEvent<BuildingNode>
export type ZoneEvent = NodeEvent<ZoneNode>
export type SlabEvent = NodeEvent<SlabNode>
export type CeilingEvent = NodeEvent<CeilingNode>
// Event suffixes - exported for use in hooks
export const eventSuffixes = [
@@ -60,6 +61,7 @@ type EditorEvents = GridEvents &
NodeEvents<'item', ItemEvent> &
NodeEvents<'building', BuildingEvent> &
NodeEvents<'zone', ZoneEvent> &
NodeEvents<'ceiling', CeilingEvent> &
CameraControlEvents
export const emitter = mitt<EditorEvents>()