Commit bb6c2076 authored by mercury233's avatar mercury233

fix infinite activation of some decks

parent 468b477f
......@@ -184,6 +184,7 @@ namespace WindBot.Game.AI.Decks
private bool JetSynchronUsed = false;
private bool ScrapWyvernUsed = false;
private bool MaskedChameleonUsed = false;
private int ShootingRiserDragonCount = 0;
private int[] HandCosts = new[]
{
......@@ -217,6 +218,7 @@ namespace WindBot.Game.AI.Decks
JetSynchronUsed = false;
ScrapWyvernUsed = false;
MaskedChameleonUsed = false;
ShootingRiserDragonCount = 0;
}
public override void OnChainEnd()
......@@ -843,12 +845,15 @@ namespace WindBot.Game.AI.Decks
}
else
{
if (Duel.LastChainPlayer == 0 || ShootingRiserDragonCount >= 10)
return false;
ShootingRiserDragonCount++;
AI.SelectCard(new[] {
CardId.BlackRoseMoonlightDragon,
CardId.ScrapDragon,
CardId.PSYFramelordOmega
});
return Duel.LastChainPlayer != 0;
return true;
}
}
......
......@@ -106,7 +106,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor(ExecutorType.Activate, CardId.Lumina, Luminaeff);
//activate
AddExecutor(ExecutorType.Activate, CardId.GlowUpBulb, GlowUpBulbeff);
AddExecutor(ExecutorType.Activate, CardId.TG_WonderMagician);
AddExecutor(ExecutorType.Activate, CardId.TG_WonderMagician, TG_WonderMagicianeff);
AddExecutor(ExecutorType.Activate, CardId.CoralDragon, CoralDragoneff);
AddExecutor(ExecutorType.Activate, CardId.RedWyvern, RedWyverneff);
AddExecutor(ExecutorType.Activate, CardId.CrystalWingSynchroDragon, CrystalWingSynchroDragoneff);
......@@ -230,6 +230,7 @@ namespace WindBot.Game.AI.Decks
}
int Ultimate_ss = 0;
int Enemy_atk = 0;
int TG_WonderMagician_count = 0;
bool Pillused = false;
bool CrystronNeedlefibereff_used = false;
bool OvertexCoatlseff_used = false;
......@@ -274,6 +275,7 @@ namespace WindBot.Game.AI.Decks
ShaddollSquamata_used = false;
ShaddollDragon_used = false;
ShaddollHedgehog_used = false;
TG_WonderMagician_count = 0;
}
private bool Luminasummon()
......@@ -572,7 +574,11 @@ namespace WindBot.Game.AI.Decks
return false;
}
private bool TG_WonderMagicianeff()
{
TG_WonderMagician_count++;
return TG_WonderMagician_count <= 10;
}
private bool AllureofDarkness()
{
IList<ClientCard> materials = Bot.Hand;
......
......@@ -181,6 +181,7 @@ namespace WindBot.Game.AI.Decks
private bool CymbalSkeletonUsed = false;
private bool BorrelswordDragonUsed = false;
private ClientCard RustyBardicheTarget = null;
private int ShootingRiserDragonCount = 0;
private int[] HandCosts = new[]
{
......@@ -214,6 +215,7 @@ namespace WindBot.Game.AI.Decks
CymbalSkeletonUsed = false;
BorrelswordDragonUsed = false;
RustyBardicheTarget = null;
ShootingRiserDragonCount = 0;
}
public override void OnChainEnd()
......@@ -609,7 +611,10 @@ namespace WindBot.Game.AI.Decks
}
else
{
return Duel.LastChainPlayer != 0;
if (Duel.LastChainPlayer == 0)
return false;
ShootingRiserDragonCount++;
return ShootingRiserDragonCount <= 10;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment