mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 19:28:01 +00:00
Implement Okk and Orcish Conscripts.
This commit is contained in:
2
.gitattributes
vendored
2
.gitattributes
vendored
@@ -10434,6 +10434,7 @@ forge-gui/res/cardsfolder/o/ojutais_summons.txt -text
|
||||
forge-gui/res/cardsfolder/o/okiba_gang_shinobi.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/okina_nightwatch.txt -text
|
||||
forge-gui/res/cardsfolder/o/okina_temple_to_the_grandfathers.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/okk.txt -text
|
||||
forge-gui/res/cardsfolder/o/old_ghastbark.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/old_man_of_the_sea.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/olivia_voldaren.txt -text
|
||||
@@ -10527,6 +10528,7 @@ forge-gui/res/cardsfolder/o/orcish_bloodpainter.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/orcish_cannonade.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/orcish_cannoneers.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/orcish_captain.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/orcish_conscripts.txt -text
|
||||
forge-gui/res/cardsfolder/o/orcish_farmer.txt -text
|
||||
forge-gui/res/cardsfolder/o/orcish_healer.txt svneol=native#text/plain
|
||||
forge-gui/res/cardsfolder/o/orcish_librarian.txt -text
|
||||
|
||||
@@ -594,12 +594,40 @@ public class PhaseHandler implements java.io.Serializable {
|
||||
}
|
||||
}
|
||||
|
||||
// We may need to do multiple iterations removing blockers, since removing one may invalidate
|
||||
// others. The loop below is structured so that if no blockers were removed, no extra passes
|
||||
// are needed.
|
||||
boolean reachedSteadyState;
|
||||
do {
|
||||
reachedSteadyState = true;
|
||||
List<Card> remainingBlockers = CardLists.filterControlledBy(combat.getAllBlockers(), p);
|
||||
for (Card c : remainingBlockers) {
|
||||
if (remainingBlockers.size() < 2 && c.hasKeyword("CARDNAME can't attack or block alone.")) {
|
||||
int minBlockers = Integer.MIN_VALUE;
|
||||
if (c.hasKeyword("CARDNAME can't attack or block alone.")) {
|
||||
minBlockers = 2;
|
||||
} else if (c.hasKeyword("CARDNAME can't block unless at least two other creatures block.")) {
|
||||
minBlockers = 3;
|
||||
}
|
||||
if (remainingBlockers.size() < minBlockers) {
|
||||
combat.undoBlockingAssignment(c);
|
||||
reachedSteadyState = false;
|
||||
} else if (c.hasKeyword("CARDNAME can't block unless a creature with greater power also blocks.")) {
|
||||
boolean found = false;
|
||||
int power = c.getNetPower();
|
||||
// Note: This is O(n^2), but there shouldn't generally be many creatures with the above keyword.
|
||||
for (Card c2 : remainingBlockers) {
|
||||
if (c2.getNetPower() > power) {
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!found) {
|
||||
combat.undoBlockingAssignment(c);
|
||||
reachedSteadyState = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
} while (!reachedSteadyState);
|
||||
|
||||
// Player is done declaring blockers - redraw UI at this point
|
||||
|
||||
|
||||
@@ -3,4 +3,5 @@ ManaCost:3 R
|
||||
Types:Creature Cyclops
|
||||
PT:3/4
|
||||
K:If a creature you control attacks, CARDNAME also attacks if able.
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/ekundu_cyclops.jpg
|
||||
Oracle:If a creature you control attacks, Ekundu Cyclops also attacks if able.
|
||||
|
||||
8
forge-gui/res/cardsfolder/o/okk.txt
Normal file
8
forge-gui/res/cardsfolder/o/okk.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
Name:Okk
|
||||
ManaCost:1 R
|
||||
Types:Creature Goblin
|
||||
PT:4/4
|
||||
K:CARDNAME can't attack unless a creature with greater power also attacks.
|
||||
K:CARDNAME can't block unless a creature with greater power also blocks.
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/okk.jpg
|
||||
Oracle:Okk can't attack unless a creature with greater power also attacks.\nOkk can't block unless a creature with greater power also blocks.
|
||||
8
forge-gui/res/cardsfolder/o/orcish_conscripts.txt
Normal file
8
forge-gui/res/cardsfolder/o/orcish_conscripts.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
Name:Orcish Conscripts
|
||||
ManaCost:R
|
||||
Types:Creature Orc
|
||||
PT:2/2
|
||||
K:CARDNAME can't attack unless at least two other creatures attack.
|
||||
K:CARDNAME can't block unless at least two other creatures block.
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/orcish_conscripts.jpg
|
||||
Oracle:Orcish Conscripts can't attack unless at least two other creatures attack.\nOkk can't block unless at least two other creatures block.
|
||||
Reference in New Issue
Block a user