From b54403163d31dadfde33e66f088f0ea604815946 Mon Sep 17 00:00:00 2001 From: Agetian Date: Thu, 12 Apr 2018 08:41:56 +0300 Subject: [PATCH] - Don't hold land drops till main 2 if playing with the Momir avatar (Momir Basic, MoJhoSto, etc.), otherwise it messes with the AI strategy for activating the avatar. --- forge-ai/src/main/java/forge/ai/AiController.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/forge-ai/src/main/java/forge/ai/AiController.java b/forge-ai/src/main/java/forge/ai/AiController.java index 8bf7a9de31c..4a2eb3651b9 100644 --- a/forge-ai/src/main/java/forge/ai/AiController.java +++ b/forge-ai/src/main/java/forge/ai/AiController.java @@ -1180,6 +1180,13 @@ public class AiController { } private boolean isSafeToHoldLandDropForMain2(Card landToPlay) { + boolean hasMomir = !CardLists.filter(player.getCardsIn(ZoneType.Command), + CardPredicates.nameEquals("Momir Vig, Simic Visionary Avatar")).isEmpty(); + if (hasMomir) { + // Don't do this in Momir variants since it messes with the AI decision making for the avatar. + return false; + } + if (!MyRandom.percentTrue(getIntProperty(AiProps.HOLD_LAND_DROP_FOR_MAIN2_IF_UNUSED))) { // check against the chance specified in the profile return false;