Skip to content

Commit

Permalink
refactor(Witch): Change potion structure for plays and game history.
Browse files Browse the repository at this point in the history
…Closes #130
  • Loading branch information
antoinezanardi committed Feb 27, 2021
1 parent 580db5a commit 34f8e4c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
### ♻️ Refactoring

* [#129](https://github.com/antoinezanardi/werewolves-assistant-web/issues/129) - Change sheriff enabled option property name.
* [#130](https://github.com/antoinezanardi/werewolves-assistant-web/issues/130) - Change `potion` structure for plays and game history.

### 📦 Packages

Expand Down
4 changes: 2 additions & 2 deletions src/components/Game/GameContent/GameContent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ export default {
} else if (lastGameHistoryEntry.play.action === "eat" && lastGameHistoryEntrySourceName === "werewolves" &&
!!vileFatherOfWolvesPlayer && vileFatherOfWolvesPlayer.isAlive) {
this.events.push(new GameEvent({ type: `vile-father-of-wolves-infects`, targets: lastGameHistoryEntry.play.targets }));
} else if (this.game.history.length && lastGameHistoryEntry.wasVotePlayWithoutDeath) {
this.events.push(new GameEvent({ type: `no-death-after-votes`, targets: this.game.history[1].play.targets }));
} else if (this.game.history.length && lastGameHistoryEntry.wasVotePlayWithoutDeath && !lastGameHistoryEntry.revealedPlayers) {
this.events.push(new GameEvent({ type: `no-death-after-votes`, targets: this.game.history[0].play.targets }));
} else if (lastGameHistoryEntry.play.action === "choose-card") {
this.events.push(new GameEvent({ type: `thief-chooses-card`, targets: [{ player: this.game.originalThiefPlayer }] }));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,10 @@ export default {
return {
SVGs: { dead },
murderIcons: {
"all": { vote },
"all": {
vote,
reconsider: vote,
},
"werewolves": { eat: eaten },
"big-bad-wolf": { eat: bigBadWolf },
"white-werewolf": { eat: whiteWerewolf },
Expand Down
3 changes: 2 additions & 1 deletion src/plugins/vue-i18n/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -912,7 +912,8 @@
"GameSummaryHistoryDeadPlayerLine": {
"murder": {
"all": {
"vote": "a été pendu sur la place publique après le vote du village."
"vote": "a été pendu sur la place publique après le vote du village.",
"reconsider": "a finalement été pendu, le Village revenant sur sa décision d'épargner l'Idiot maintenant que l'Ancien est mort."
},
"werewolves": {
"eat": "a été dévoré par les Loups-Garous."
Expand Down

0 comments on commit 34f8e4c

Please sign in to comment.