[MOC] Implement Path of the Schemer

This commit is contained in:
theelk801 2023-04-23 16:48:52 -04:00
parent a53c63e19c
commit 22946bb35e
3 changed files with 102 additions and 5 deletions

View file

@ -2,6 +2,7 @@ package mage.abilities.effects.common;
import mage.abilities.Ability;
import mage.abilities.effects.OneShotEffect;
import mage.choices.TwoChoiceVote;
import mage.constants.AbilityWord;
import mage.constants.Outcome;
import mage.game.Game;
@ -13,7 +14,7 @@ public class WillOfThePlaneswalkersEffect extends OneShotEffect {
public WillOfThePlaneswalkersEffect() {
super(Outcome.Benefit);
staticText = AbilityWord.WILL_OF_THE_COUNCIL.formatWord() + "Starting with you, each player votes " +
staticText = AbilityWord.WILL_OF_THE_PLANESWALKERS.formatWord() + "Starting with you, each player votes " +
"for planeswalk or chaos. If planeswalk gets more votes, planeswalk. " +
"If chaos gets more votes or the vote is tied, chaos ensues";
concatBy("<br>");
@ -30,7 +31,16 @@ public class WillOfThePlaneswalkersEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
TwoChoiceVote vote = new TwoChoiceVote("Planeswalk", "Chaos", Outcome.Benefit);
vote.doVotes(source, game);
int planeswalkCount = vote.getVoteCount(true);
int chaosCount = vote.getVoteCount(false);
// TODO: Implement when planes have been refactored
if (planeswalkCount > chaosCount) {
// planeswalk to next plane
} else {
// chaos ensues
}
return true;
}
}