This commit is contained in:
2026-04-28 19:36:39 +08:00
parent a9febe7678
commit f0471a4f8d
206 changed files with 18456 additions and 10133 deletions

View File

@@ -46,6 +46,40 @@ export interface PlayerProgressionState {
lastGrantedSource?: PlayerProgressionGrantSource | null;
}
export type RuntimeNpcTradeMode = 'buy' | 'sell';
export interface RuntimeNpcTradeItemView {
itemId: string;
item: InventoryItem;
mode: RuntimeNpcTradeMode;
unitPrice: number;
maxQuantity: number;
canSubmit: boolean;
reason?: string | null;
}
export interface RuntimeNpcGiftItemView {
itemId: string;
item: InventoryItem;
affinityGain: number;
canSubmit: boolean;
reason?: string | null;
}
export interface RuntimeNpcInteractionView {
npcId: string;
npcName: string;
playerCurrency: number;
currencyName: string;
trade: {
buyItems: RuntimeNpcTradeItemView[];
sellItems: RuntimeNpcTradeItemView[];
};
gift: {
items: RuntimeNpcGiftItemView[];
};
}
export interface GameState {
worldType: WorldType | null;
customWorldProfile: CustomWorldProfile | null;
@@ -70,6 +104,7 @@ export interface GameState {
animationState: AnimationState;
currentEncounter: Encounter | null;
npcInteractionActive: boolean;
runtimeNpcInteraction?: RuntimeNpcInteractionView | null;
currentScenePreset: ScenePresetInfo | null;
sceneHostileNpcs: SceneHostileNpc[];
playerX: number;