A C# bot for YGOPro, compatible with the YGOSharp and SRVPro server.
Compile WindBot.sln
using Visual Studio or Mono.
Put cards.cdb
next to the compiled WindBot.exe
.
Run YGOPro, create a host.
Run WindBot and observe.
Name
The nickname for the bot.
Deck
The deck to be used by the bot. Available decks are listed below. Keep empty to use random deck.
DeckFile
The deck file (.ydk) to be used by the bot. Will be set by Deck
automatically, but you can override it.
Note: Most cards not in the original deck are unknown to the bot, and won't be summoned or activated in the duel.
Dialog
The dialog texts to be used by the bot. See Dialogs folder for list.
Host
The IP of the host to be connected to.
Port
The port of the host to be connected to.
HostInfo
The host info (password) to be used.
Version
The version of YGOPro.
Hand
If you are testing deck, you may want to make sure the bot go first or second. Hand=1
will make the bot always show Scissors, 2 for Rock, 3 for Paper.
Chat
False to turn the chat of bot off.
Debug
Print verbose log of card movement info. False at default. (May be updated in future)
ServerMode
and ServerPort
WindBot can run as a "server", provide a http interface to create bot.
Easy:
Burn
Frog
Horus
MokeyMokey
MokeyMokeyKing
OldSchool
Normal:
Altergeist
Blue-Eyes
BlueEyesMaxDragon
Brave
ChainBurn
DarkMagician
Dragun
Dragunity
GrenMajuThunderBoarder
Level VIII
LightswornShaddoldinosour
Orcust
Phantasm
Qliphort
Rainbow
Rank V
Salamangreat
SkyStriker
ST1732
ThunderDragon
Toadally Awesome
Trickstar
Yosenju
Zexal Weapons
Zoodiac
Blackwing
CyberDragon
Evilswarm
Gravekeeper
Graydle
Lightsworn
Nekroz
A Java program which generate executor code from deck, made by Levyaton. https://github.com/Levyaton/WindbotTemplateGenerator
WindBot can run as a "server", provide a http interface to create bot.
eg. http://127.0.0.1:2399/?name=%E2%91%A8&deck=Blue-Eyes&host=127.0.0.1&port=7911&dialog=cirno.zh-CN
In this situation, it will be multi-threaded. This can be useful for servers, since it don't use large amount memory.
The parameters are same as commandlines, but low cased.
AI.SelectCard
, the second one won't select correctly.ClientCard.Sequence
, ClientCard.ProcCompleted
, ClientCard.IsSpecialSummoned
ClientCard.EquipCards
, ClientCard.OwnTargets
, handle equip cardsClientCard.IsCode
, handle card aliasClientCard.GetLinkedZones
, ClientCard.HasSetcode
ClientField.UnderAttack
, ClientField.GetLinkedZones
, ClientField.GetFieldSpellCard
Duel.SummoningCards
, Duel.LastSummonedCards
Util.GetTotalAttackingMonsterAttack
, Util.GetBotAvailZonesFromExtraDeck
GetMatchingCards
, GetFirstMatchingCard
, IsExistingMatchingCard
ExecutorType.GoToBattlePhase
, ExecutorType.GoToMainPhase2
, ExecutorType.GoToEndPhase
DefaultScapegoat
, DefaultMaxxC
, DefaultAshBlossomAndJoyousSpring
, DefaultGhostOgreAndSnowRabbit
, DefaultGhostBelleAndHauntedMansion
, DefaultEffectVeiler
, DefaultCalledByTheGrave
, DefaultInfiniteImpermanence
AIFunctions
to AIUtil
(Usage: AI.Utils.
-> Util.
)AIFunctions.CompareCardAttack
to CardContainer.CompareCardAttack
Util.SelectPreferredCards
and Util.CheckSelectCount
to return the resultClientField.HasInMonstersZone
to support check face-up cardAI.SelectCard
#59int location
to CardLocation location
OnPreBattleBetween
to recognize more cardsCardSelector.Select
OnSelectEffectYn
didn't have ActivateDescription
ClientCard.Attacked
Zones
enum and AI.SelectPlace
ClientCard.IsTuner
, ClientCard.LinkMarker
, ClientCard.HasLinkMarker
ShouldNotBeTarget
and ShouldBeDisabledBeforeItUseEffectMonster
enumAI.Utils.GetBestBotMonster
, AI.Utils.GetWorstBotMonster
and AI.Utils.ChainContainPlayer
Executor.OnCardSorting
and Executor.OnDraw
ClientField.GetColumnCount
and ClientField.HasInHandOrInSpellZone
etc.OnBattle
, add Executor.OnSelectAttacker
and Executor.OnSelectAttackTarget
Executor.OnSelectPosition
, Executor.OnSelectBattleReplay
Bot.BattlingMonster
Duel.LifePoints[0]
to Bot.LifePoints
LastChainPlayer
and CurrentChain
to Duel
classChainContainsCard
and GetLastChainCard
etc. to AI.Utils
classAI.SelectMaterials
, OnSelectFusionMaterial
, OnSelectPendulumSummon
, AI.Utils.SelectPreferredCards
etc.AI.Utils.GetBestEnemySpell
to not return normal spell currently activatingOnUpdateData
DefaultExecutor
AI.Utils
, ClientCard
, ClientField
functionsOnNewTurn
, AI.SelectYesNo
, AI.SelectThirdCard
, Duel.ChainTargets
, Duel.LastSummonPlayer
Bot
for Duel.Fields[0]
, Enemy
for Duel.Fields[1]
CardId
is now class instead of enum so (int)
is no longer neededFloodgate
, OneForXyz
, FusionSpell
, MonsterHasPreventActivationEffectInBattle
OnPreBattleBetween
to calculate the ATK of cards like Number S39: Utopia the LightningYGOSharp.OCGWrapper
More decks
Documents for creating AI
AI.SelectPlace
for linked zones or not linked zones
AI.SelectTribute
Get equip of card.
Better new master rule support
Update the known card enums
More default common cards executor