mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
Ain't a normal month without a Henzie fix (#5671)
This commit is contained in:
@@ -235,6 +235,7 @@ public final class GameActionUtil {
|
||||
stackCopy = CardCopyService.getLKICopy(source);
|
||||
}
|
||||
stackCopy.setLastKnownZone(game.getStackZone());
|
||||
stackCopy.setCastFrom(oldZone);
|
||||
lkicheck = true;
|
||||
|
||||
stackCopy.clearStaticChangedCardKeywords(false);
|
||||
|
||||
@@ -2050,37 +2050,16 @@ public class CardProperty {
|
||||
strZone = strZone.substring(0, strZone.indexOf("ByYou", 0));
|
||||
}
|
||||
final ZoneType realZone = ZoneType.smartValueOf(strZone);
|
||||
if (card.getCastFrom() == null || (zoneOwner != null && !card.getCastFrom().getPlayer().equals(zoneOwner))
|
||||
if (card.getCastFrom() == null || card.getCastSA() == null || (zoneOwner != null && !card.getCastFrom().getPlayer().equals(zoneOwner))
|
||||
|| (byYou && !sourceController.equals(card.getCastSA().getActivatingPlayer()))
|
||||
|| realZone != card.getCastFrom().getZoneType()) {
|
||||
return false;
|
||||
}
|
||||
} else if (property.startsWith("wasNotCastFrom")) {
|
||||
boolean byYou = property.contains("ByYou");
|
||||
String strZone = property.substring(14);
|
||||
Player zoneOwner = null;
|
||||
if (property.contains("Your")) {
|
||||
strZone = strZone.substring(4);
|
||||
zoneOwner = sourceController;
|
||||
}
|
||||
if (property.contains("Their")) {
|
||||
strZone = strZone.substring(5);
|
||||
zoneOwner = controller;
|
||||
}
|
||||
if (byYou) {
|
||||
strZone = strZone.substring(0, strZone.indexOf("ByYou", 0));
|
||||
}
|
||||
final ZoneType realZone = ZoneType.smartValueOf(strZone);
|
||||
if (card.getCastFrom() != null && (zoneOwner == null || card.getCastFrom().getPlayer().equals(zoneOwner))
|
||||
&& (!byYou || sourceController.equals(card.getCastSA().getActivatingPlayer()))
|
||||
&& realZone == card.getCastFrom().getZoneType()) {
|
||||
return false;
|
||||
}
|
||||
} else if (property.startsWith("wasCast")) {
|
||||
} else if (property.startsWith("wasCast")) {
|
||||
if (!card.wasCast()) {
|
||||
return false;
|
||||
}
|
||||
if (property.contains("ByYou") && !sourceController.equals(card.getCastSA().getActivatingPlayer())) {
|
||||
if (property.contains("ByYou") && card.getCastSA() != null && !sourceController.equals(card.getCastSA().getActivatingPlayer())) {
|
||||
return false;
|
||||
}
|
||||
} else if (property.equals("wasNotCast")) {
|
||||
|
||||
Reference in New Issue
Block a user