doggo-quest-logic
Version:
The game logic for the Doggo Quest text-based game sample project
30 lines (29 loc) • 1.12 kB
TypeScript
import { Sentence } from './Parsing/Sentence';
import { Word } from './Parsing/Word';
import { StoryEntry } from './StoryEntry';
import { GameRoom } from './World/GameRoom';
import { GameWorld } from './World/GameWorld';
import { Room } from './World/Room';
export declare class CommandContext {
private entries;
sentence: Sentence;
world: GameWorld;
constructor(entries: StoryEntry[], sentence: Sentence, world: GameWorld);
readonly currentRoom: Room;
readonly currentRoomObject: GameRoom | undefined;
readonly currentRoomName: string;
describeCurrentRoom(isFullDescribe: boolean): void;
changeRoom(newRoom: Room, directionName: string): void;
checkVerb(expectedVerb: string): void;
addPlayerCommand(): void;
addText(message: string): void;
addRoomName(message: string): void;
addError(message: string): void;
addSystem(message: string): void;
addDontSee(target: Word): void;
increaseScore(amount: number): void;
addLocalObjects(): void;
advanceTime(): void;
restart(): void;
addInitialEntries(): void;
}