mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
*Made static effects reset hand size correctly for Vanguard.
This commit is contained in:
@@ -160,7 +160,7 @@ public class StaticEffects {
|
||||
// modify players
|
||||
for (final Player p : affectedPlayers) {
|
||||
p.setUnlimitedHandSize(false);
|
||||
p.setMaxHandSize(7);
|
||||
p.setMaxHandSize(p.getStartingHandSize());
|
||||
|
||||
if (params.containsKey("AddKeyword")) {
|
||||
addKeywords = params.get("AddKeyword").split(" & ");
|
||||
|
||||
@@ -121,7 +121,9 @@ public class GameNew {
|
||||
for( Entry<Player, PlayerStartConditions> p : playersConditions.entrySet() ) {
|
||||
final Player player = p.getKey();
|
||||
player.setStartingLife(p.getValue().getStartingLife());
|
||||
player.setMaxHandSize(p.getValue().getStartingHand());
|
||||
int hand = p.getValue().getStartingHand();
|
||||
player.setMaxHandSize(hand);
|
||||
player.setStartingHandSize(hand);
|
||||
// what if I call it for AI player?
|
||||
PlayerZone bf = player.getZone(ZoneType.Battlefield);
|
||||
Iterable<Card> onTable = p.getValue().getCardsOnBattlefield();
|
||||
|
||||
@@ -107,6 +107,9 @@ public abstract class Player extends GameEntity implements Comparable<Player> {
|
||||
|
||||
/** The max hand size. */
|
||||
private int maxHandSize = 7;
|
||||
|
||||
/** Starting hand size */
|
||||
private int startingHandSize = 7;
|
||||
|
||||
/** The unlimited hand size. */
|
||||
private boolean unlimitedHandSize = false;
|
||||
@@ -3019,5 +3022,16 @@ public abstract class Player extends GameEntity implements Comparable<Player> {
|
||||
|
||||
return other.getType() != this.getType();
|
||||
}
|
||||
|
||||
|
||||
public int getStartingHandSize()
|
||||
{
|
||||
return this.startingHandSize;
|
||||
}
|
||||
|
||||
public void setStartingHandSize(int shs)
|
||||
{
|
||||
this.startingHandSize = shs;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user