Skip to content

Where the vote is saved? #283

Answered by bra1n
MRegnard asked this question in Q&A
Apr 17, 2023 · 1 comments · 2 replies
Discussion options

You must be logged in to vote

That happens here:

/**
* Create an entry in the vote history log. Requires current player array because it might change later in the game.
* Only stores votes that were completed.
* @param state
* @param players
*/
addHistory(state, players) {
if (!state.isVoteHistoryAllowed && state.isSpectator) return;
if (!state.nomination || state.lockedVote <= players.length) return;
const isExile = players[state.nomination[1]].role.team === "traveler";
state.voteHistory.push({
timestamp: new Date(),
nominator: players[state.nomination[0]].name,
nominee: p…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@MRegnard
Comment options

@bra1n
Comment options

Answer selected by bra1n
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants