adjustments for debugging. Cleanup and Addtl Statuses
parent
1053140576
commit
96ad73a3eb
|
@ -15,9 +15,9 @@ class GameFlow {
|
||||||
// Handle the setup phase, e.g., initial purchases
|
// Handle the setup phase, e.g., initial purchases
|
||||||
await this.handleSetupPhase(userInput);
|
await this.handleSetupPhase(userInput);
|
||||||
break;
|
break;
|
||||||
case PHASE_ENUM.RIDERS_ATTACK:
|
case PHASE_ENUM.START_TURN:
|
||||||
// Handle a riders attack phase
|
break;
|
||||||
await this.handleRidersAttack(userInput);
|
case PHASE_ENUM.ACTION_CHOICE:
|
||||||
break;
|
break;
|
||||||
case PHASE_ENUM.TRAVEL:
|
case PHASE_ENUM.TRAVEL:
|
||||||
// Handle travel logic
|
// Handle travel logic
|
||||||
|
@ -31,9 +31,11 @@ class GameFlow {
|
||||||
// Handle hunting logic
|
// Handle hunting logic
|
||||||
await this.handleHunt();
|
await this.handleHunt();
|
||||||
break;
|
break;
|
||||||
case PHASE_ENUM.ENCOUNTER:
|
case PHASE_ENUM.EATING:
|
||||||
// Handle encounters, which might include interactions with NPCs or obstacles
|
break;
|
||||||
await this.handleEncounter();
|
case PHASE_ENUM.RIDERS_ATTACK:
|
||||||
|
// Handle a riders attack phase
|
||||||
|
await this.handleRidersAttack(userInput);
|
||||||
break;
|
break;
|
||||||
case PHASE_ENUM.EVENT:
|
case PHASE_ENUM.EVENT:
|
||||||
// Handle random events that can occur
|
// Handle random events that can occur
|
||||||
|
@ -76,9 +78,10 @@ class GameFlow {
|
||||||
supplies: this.gameState.amountSpentOnMiscellaneousSupplies.toString(),
|
supplies: this.gameState.amountSpentOnMiscellaneousSupplies.toString(),
|
||||||
};
|
};
|
||||||
|
|
||||||
const parsedMessage = `${MessageService.getRandomMessage(MessageFileName.Oregon_Template, placeholders)}`
|
console.log(JSON.stringify(placeholders, null, 4))
|
||||||
|
//const parsedMessage = `${MessageService.getRandomMessage(MessageFileName.Oregon_Template, placeholders)}`
|
||||||
|
|
||||||
await CommentPoster.postComment(`c_${this.gameState.comment.id}`, parsedMessage)
|
//await CommentPoster.postComment(`c_${this.gameState.comment.id}`, parsedMessage)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -250,8 +253,13 @@ class GameFlow {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
case 6:
|
||||||
//Advance Phase
|
//Advance Phase
|
||||||
|
this.gameState.phase = PHASE_ENUM.START_TURN
|
||||||
|
this.executeCurrentPhase()
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
responseMessage = `@J something went wrong come and fix it.\n\n ${JSON.stringify(this.gameState, null, 4)}`
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -92,12 +92,14 @@ export default GameState
|
||||||
// Enumeration for different phases of the game.
|
// Enumeration for different phases of the game.
|
||||||
export enum PHASE_ENUM {
|
export enum PHASE_ENUM {
|
||||||
SETUP = 'SETUP',
|
SETUP = 'SETUP',
|
||||||
|
START_TURN = 'START_TURN',
|
||||||
|
ACTION_CHOICE = 'ACTION_CHOICE',
|
||||||
TRAVEL = 'TRAVEL',
|
TRAVEL = 'TRAVEL',
|
||||||
FORT = 'FORT',
|
FORT = 'FORT',
|
||||||
HUNT = 'HUNT',
|
HUNT = 'HUNT',
|
||||||
ENCOUNTER = 'ENCOUNTER',
|
EATING = 'EATING',
|
||||||
|
RIDERS_ATTACK = 'RIDERS_ATTACK',
|
||||||
EVENT = 'EVENT',
|
EVENT = 'EVENT',
|
||||||
MOUNTAIN = 'MOUNTAIN',
|
MOUNTAIN = 'MOUNTAIN',
|
||||||
DEATH_CHECK = 'DEATH_CHECK',
|
DEATH_CHECK = 'DEATH_CHECK',
|
||||||
RIDERS_ATTACK = 'RIDERS_ATTACK',
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue