@drincs/nqtr
Version:
A complete system introducing the concepts of location, time and event, producing the framework of a not-quite-point-and-click adventure game.
60 lines (57 loc) • 2.65 kB
text/typescript
import { CharacterInterface } from '@drincs/pixi-vn';
import { C as CommitmentInterface } from '../RoomInterface-DURfkQ7u.mjs';
import '@drincs/nqtr';
import '../interface/ActivityInterface.mjs';
import '../types/ExecutionType.mjs';
import '../interface/navigation/NavigationAbstractClass.mjs';
declare class RoutineManager {
get fixedRoutine(): CommitmentInterface[];
/**
* Set a commitment as fixed, it will be always available. They cannot be deleted or edit during the game session.
*/
set fixedRoutine(commitments: CommitmentInterface[]);
/**
* Get the temporary commitments by its id.
* @returns The temporary commitments.
*/
get temporaryRoutine(): CommitmentInterface[];
get allRoutine(): CommitmentInterface[];
/**
* This feature adds the commitments during the game session.
* @param commitment The commitment or commitments to add.
*/
add(commitment: CommitmentInterface[] | CommitmentInterface): void;
/**
* Get the commitments added during the game session.
* @param id The id of the commitment.
* @returns The commitment or undefined if not found.
*/
find(id: string): CommitmentInterface | undefined;
/**
* Remove the commitments added during the game session.
* @param commitment The commitment or commitments to remove.
*/
remove(commitment: CommitmentInterface[] | CommitmentInterface): void;
/**
* Clear all the expired commitments.
*/
clearExpiredRoutine(): void;
/**
* Get the current commitments. The hidden commitments are not included.
* In case there is a character who has two or more commitments at the same time, will be selected the commitment with the highest priority.
* Higher priority commitments are calculated using the following steps:
* 1. The commitments that have Commitments BaseModel.priority set to a higher value will be selected first.
* 2. If there are commitments with the same priority, the commitments that are not fixed will be selected first.
* 3. If there are commitments with the same priority and the same fixed status, priority will be given to the commitment with a lower index.
* @returns The current commitments.
*/
get currentRoutine(): CommitmentInterface[];
get currentRoomRoutine(): CommitmentInterface[];
/**
* Get the character commitment.
* @param character The character.
* @returns The commitment or undefined if not found.
*/
getCommitmentByCharacter(character: CharacterInterface): CommitmentInterface | undefined;
}
export { RoutineManager as default };