import type { GameEvents } from "../../game/events.js"; import { type WorldItemRecord, type WorldItemSpawnInput, type WorldItemStore } from "../../game/worldItem.js"; import type { Drop } from "../../game/lootTable.js"; import type { EntityStore } from "../../scene/entityStore.js"; import type { WorldItemPickupResult } from "../gameContext.js"; /** @internal What the ground-item surface needs from the live context: entity spawn/despawn, the event bus, loot granting, and change notification. */ export interface WorldItemContextDeps { entities: EntityStore; events: GameEvents; despawnEntity: (instanceId: string) => boolean; grantToPlayer: (userId: string, drops: Drop[], source?: string) => void; signalNotify: () => void; } /** @internal The `ctx.scene.worldItem` wiring: the reactive store plus the spawn/pickup verbs that emit `worldItem.*` events and route pickups through loot. */ export interface WorldItemContext { worldItems: WorldItemStore; spawnWorldItem(input: WorldItemSpawnInput): WorldItemRecord; pickupWorldItem(instanceId: string, userId: string): WorldItemPickupResult; } /** @internal */ export declare function createWorldItemContext(d: WorldItemContextDeps): WorldItemContext;