Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
W
Windbot-408
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
神之吹息
Windbot-408
Commits
1f9ceee2
Commit
1f9ceee2
authored
Feb 07, 2023
by
苍蓝
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
传说更新
parent
b7592a90
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
176 additions
and
133 deletions
+176
-133
Game/AI/Decks/LuckyExecutor.cs
Game/AI/Decks/LuckyExecutor.cs
+9
-2
Game/AI/Decks/MokeyMokeyExecutor.cs
Game/AI/Decks/MokeyMokeyExecutor.cs
+1
-12
Game/AI/Decks/MokeyMokeyKingExecutor.cs
Game/AI/Decks/MokeyMokeyKingExecutor.cs
+1
-13
Game/AI/Decks/SaikyoBattleFlagExecutor.cs
Game/AI/Decks/SaikyoBattleFlagExecutor.cs
+45
-90
Game/AI/Decks/TheLegendExecutor.cs
Game/AI/Decks/TheLegendExecutor.cs
+2
-15
Game/AI/DefaultExecutor.cs
Game/AI/DefaultExecutor.cs
+118
-1
No files found.
Game/AI/Decks/LuckyExecutor.cs
View file @
1f9ceee2
...
@@ -21,6 +21,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -21,6 +21,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
SummonOrSet
,
ImFeelingLazy
);
AddExecutor
(
ExecutorType
.
SummonOrSet
,
ImFeelingLazy
);
AddExecutor
(
ExecutorType
.
Repos
,
DefaultMonsterRepos
);
AddExecutor
(
ExecutorType
.
Repos
,
DefaultMonsterRepos
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
海龙骑士
,
海龙骑士
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
大风暴
,
大风暴
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
大风暴
,
大风暴
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
魔法筒
,
魔法筒
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
魔法筒
,
魔法筒
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
炸甲
,
炸甲
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
炸甲
,
炸甲
Effect
);
...
@@ -29,6 +30,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -29,6 +30,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
圣防
,
圣防
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
圣防
,
圣防
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
暗黑释放
,
圣防
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
暗黑释放
,
圣防
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
手枪龙
,
手枪龙
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
手枪龙
,
手枪龙
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
最强战旗
,
最强战旗
Eff
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
MysticalSpaceTyphoon
,
DefaultMysticalSpaceTyphoon
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
MysticalSpaceTyphoon
,
DefaultMysticalSpaceTyphoon
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
CosmicCyclone
,
DefaultCosmicCyclone
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
CosmicCyclone
,
DefaultCosmicCyclone
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
GalaxyCyclone
,
DefaultGalaxyCyclone
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
GalaxyCyclone
,
DefaultGalaxyCyclone
);
...
@@ -87,12 +89,17 @@ namespace WindBot.Game.AI.Decks
...
@@ -87,12 +89,17 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
LeftLegofTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
LeftLegofTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
RightArmofTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
RightArmofTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
ExodiaTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
ExodiaTheForbiddenOne
,
JustDontIt
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
2
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
最强战旗
,
最强战旗
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
钢机神
,
钢机神
1
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
钢机神
,
钢机神
Effect
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
伟大魔兽
,
伟大魔兽
Sum
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
伟大魔兽
,
伟大魔兽
Sum
);
AddExecutor
(
ExecutorType
.
MonsterSet
,
_CardId
.
千年盾
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
MonsterSet
,
_CardId
.
千年盾
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死供
,
死供
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死供
,
死供
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
耳语妖精
,
耳语妖精
Effect
);
AddExecutor
(
ExecutorType
.
Repos
,
圣防
Repos
);
AddExecutor
(
ExecutorType
.
Repos
,
圣防
Repos
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
2
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
SpellSet
,
DefaultSpellSet
);
AddExecutor
(
ExecutorType
.
SpellSet
,
DefaultSpellSet
);
}
}
...
...
Game/AI/Decks/MokeyMokeyExecutor.cs
View file @
1f9ceee2
...
@@ -85,7 +85,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -85,7 +85,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
火星心少女
,
火星心少女
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
火星心少女
,
火星心少女
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
连击龙
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
连击龙
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
七星道魔术师
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
七星道魔术师
);
//
AddExecutor(ExecutorType.Activate, CardId.斗牛士, 斗牛士Effect);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
斗牛士
,
斗牛士
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
DefaultDontChainMyself
);
AddExecutor
(
ExecutorType
.
Activate
,
DefaultDontChainMyself
);
AddExecutor
(
ExecutorType
.
Repos
,
CardId
.
青眼白龙
,
圣防
Repos
);
AddExecutor
(
ExecutorType
.
Repos
,
CardId
.
青眼白龙
,
圣防
Repos
);
...
@@ -169,17 +169,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -169,17 +169,6 @@ namespace WindBot.Game.AI.Decks
return
false
;
return
false
;
return
true
;
return
true
;
}
}
private
bool
耳语妖精
Effect
()
{
IList
<
ClientCard
>
targets
=
new
List
<
ClientCard
>();
foreach
(
ClientCard
card
in
Enemy
.
GetGraveyardMonsters
())
{
if
(
card
.
Level
<=
4
)
targets
.
Add
(
card
);
}
return
true
;
}
private
bool
火星心少女
Effect
()
private
bool
火星心少女
Effect
()
{
{
...
...
Game/AI/Decks/MokeyMokeyKingExecutor.cs
View file @
1f9ceee2
...
@@ -90,7 +90,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -90,7 +90,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
火星心少女
,
火星心少女
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
火星心少女
,
火星心少女
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
连击龙
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
连击龙
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
七星道魔术师
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
七星道魔术师
);
//
AddExecutor(ExecutorType.Activate, CardId.斗牛士, 斗牛士Effect);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
斗牛士
,
斗牛士
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
2
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
死苏
2
,
死苏
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
DefaultDontChainMyself
);
AddExecutor
(
ExecutorType
.
Activate
,
DefaultDontChainMyself
);
...
@@ -173,18 +173,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -173,18 +173,6 @@ namespace WindBot.Game.AI.Decks
return
true
;
return
true
;
}
}
private
bool
耳语妖精
Effect
()
{
IList
<
ClientCard
>
targets
=
new
List
<
ClientCard
>();
foreach
(
ClientCard
card
in
Enemy
.
GetGraveyardMonsters
())
{
if
(
card
.
Level
<=
4
)
targets
.
Add
(
card
);
}
return
true
;
}
private
bool
七星道法师
Effect
()
private
bool
七星道法师
Effect
()
{
{
AI
.
SelectCard
(
Enemy
.
GetMonsters
().
GetHighestAttackMonster
());
AI
.
SelectCard
(
Enemy
.
GetMonsters
().
GetHighestAttackMonster
());
...
...
Game/AI/Decks/SaikyoBattleFlagExecutor.cs
View file @
1f9ceee2
...
@@ -62,6 +62,17 @@ namespace WindBot.Game.AI.Decks
...
@@ -62,6 +62,17 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
恶德
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
恶德
,
DefaultDoubleSummon
);
AddExecutor
(
ExecutorType
.
Repos
,
CardId
.
成金恐龙王
,
瞄准鹰成金恐龙王
summon
);
AddExecutor
(
ExecutorType
.
Repos
,
CardId
.
突击坦克
,
瞄准鹰坦克
summon
);
AddExecutor
(
ExecutorType
.
Repos
,
CardId
.
双角兽
,
瞄准鹰双角兽
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
双角兽
,
瞄准鹰双角兽
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
成金恐龙王
,
瞄准鹰成金恐龙王
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
突击坦克
,
瞄准鹰坦克
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon2
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon3
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
手枪龙
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
_CardId
.
手枪龙
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultMonsterSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultMonsterSummon
);
...
@@ -70,19 +81,14 @@ namespace WindBot.Game.AI.Decks
...
@@ -70,19 +81,14 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
双角兽
,
双角兽
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
双角兽
,
双角兽
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
捕鸟蛛
,
捕鸟蛛
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
捕鸟蛛
,
捕鸟蛛
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
成金恐龙王
,
成金恐龙王
Summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
成金恐龙王
,
成金恐龙王
Summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon2
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
瞄准鹰
,
瞄准鹰
summon3
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
双角兽
,
瞄准鹰双角兽
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
成金恐龙王
,
瞄准鹰成金恐龙王
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
突击坦克
,
瞄准鹰坦克
summon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultOverSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
最强战旗
,
DefaultOverSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultOverSummon
);
AddExecutor
(
ExecutorType
.
Summon
,
CardId
.
钢机神
,
DefaultOverSummon
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
死苏
,
死苏
effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
死苏
,
死苏
effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
最强战旗
,
最强战旗
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
最强战旗
,
最强战旗
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
对死者的供奉
,
死供
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
对死者的供奉
,
死供
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
钢机神
,
钢机神
1
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
钢机神
,
钢机神
1
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
钢机神
,
钢机神
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
钢机神
,
钢机神
3
Effect
);
AddExecutor
(
ExecutorType
.
MonsterSet
,
CardId
.
成金恐龙王
);
AddExecutor
(
ExecutorType
.
MonsterSet
,
CardId
.
成金恐龙王
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
工匠无人机
,
无人机
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
工匠无人机
,
无人机
Effect
);
...
@@ -180,12 +186,25 @@ namespace WindBot.Game.AI.Decks
...
@@ -180,12 +186,25 @@ namespace WindBot.Game.AI.Decks
DoubleTribute
=
false
;
DoubleTribute
=
false
;
}
}
private
bool
DefaultDoubleSummon
()
private
bool
DefaultDoubleSummon
()
{
{
if
(!
DoubleTribute
)
return
false
;
int
tribute_count
=
0
;
IList
<
ClientCard
>
m_list
=
new
List
<
ClientCard
>();
List
<
ClientCard
>
_sort_list
=
new
List
<
ClientCard
>(
Bot
.
GetMonsters
());
if
(!
DoubleTribute
)
return
false
;
else
else
AI
.
SelectMaterials
(
CardId
.
双角兽
);
{
DoubleTribute
=
false
;
foreach
(
ClientCard
monster
in
_sort_list
)
return
true
;
{
if
(
monster
.
IsCode
(
CardId
.
双角兽
))
{
tribute_count
+=
2
;
m_list
.
Add
(
monster
);
}
if
(
tribute_count
==
2
)
break
;
}
AI
.
SelectMaterials
(
m_list
);
DoubleTribute
=
false
;
return
true
;
}
}
}
private
bool
DefaultOverSummon
()
private
bool
DefaultOverSummon
()
{
{
...
@@ -227,43 +246,16 @@ namespace WindBot.Game.AI.Decks
...
@@ -227,43 +246,16 @@ namespace WindBot.Game.AI.Decks
AI
.
SelectCard
(
Bot
.
MonsterZone
.
GetLowestAttackMonster
());
AI
.
SelectCard
(
Bot
.
MonsterZone
.
GetLowestAttackMonster
());
return
true
;
return
true
;
}
}
private
bool
钢机神
Effect
()
private
bool
钢机神
3
Effect
()
{
{
if
(
Duel
.
Turn
==
1
)
if
(
Duel
.
Turn
==
1
)
{
{
return
false
;
return
false
;
}
}
else
else
//if (Enemy.HasAttackingMonster() || Enemy.GetMonsterCount() < 1)
AI
.
SelectCard
(
_CardId
.
手枪龙
,
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
,
CardId
.
捕鸟蛛
,
CardId
.
突击坦克
,
CardId
.
工匠无人机
,
CardId
.
社员
,
CardId
.
双角兽
,
CardId
.
旗兽
,
CardId
.
瞄准鹰
);
AI
.
SelectCard
(
_CardId
.
手枪龙
,
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
,
CardId
.
旗兽
,
CardId
.
捕鸟蛛
,
CardId
.
突击坦克
,
CardId
.
工匠无人机
,
CardId
.
社员
,
CardId
.
双角兽
,
CardId
.
瞄准鹰
);
//else AI.SelectCard(Bot.Graveyard.GetHighestLevelMonster());
return
true
;
return
true
;
}
}
private
bool
钢机神
1
Effect
()
{
if
(
Enemy
.
HasDefendingMonster
()
&&
Enemy
.
GetMonsterCount
()
>=
1
)
// AI.SelectCard(Bot.Graveyard.GetMonsters());
{
List
<
ClientCard
>
cards
=
new
List
<
ClientCard
>(
Bot
.
Graveyard
.
GetMatchingCards
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
Machine
)
>
0
));
cards
.
Sort
(
CardContainer
.
CompareCardLevel
);
ClientCard
selectedCard
=
null
;
for
(
int
i
=
cards
.
Count
-
1
;
i
>=
0
;
--
i
)
{
ClientCard
card
=
cards
[
i
];
if
((
selectedCard
==
null
||
card
.
Attack
>
selectedCard
.
Attack
))
{
selectedCard
=
card
;
break
;
}
}
if
(
selectedCard
!=
null
)
{
AI
.
SelectCard
(
selectedCard
);
return
true
;
}
}
return
true
;
}
private
bool
恶德
Effect
()
private
bool
恶德
Effect
()
{
{
foreach
(
ClientCard
m
in
Bot
.
Hand
)
foreach
(
ClientCard
m
in
Bot
.
Hand
)
...
@@ -349,13 +341,13 @@ namespace WindBot.Game.AI.Decks
...
@@ -349,13 +341,13 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
捕鸟蛛
summon
()
private
bool
捕鸟蛛
summon
()
{
{
if
(
Bot
.
HasInGraveyard
(
new
[]
{
CardId
.
旗兽
,
CardId
.
社员
}))
if
(
Bot
.
HasInGraveyard
(
new
[]
{
CardId
.
旗兽
,
CardId
.
社员
})
&&
Enemy
.
GetSpellCount
()
>=
2
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
private
bool
双角兽
summon
()
private
bool
双角兽
summon
()
{
{
if
(
Bot
.
Graveyard
.
GetMatchingCardsCount
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
Machine
)
>
0
)
>=
3
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
}))
if
(
Bot
.
Graveyard
.
GetMatchingCardsCount
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
Machine
)
>
0
)
>=
3
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
&&
!
Bot
.
HasInMonstersZone
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
})
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
...
@@ -371,19 +363,19 @@ namespace WindBot.Game.AI.Decks
...
@@ -371,19 +363,19 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
瞄准鹰双角兽
summon
()
private
bool
瞄准鹰双角兽
summon
()
{
{
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
}))
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
&&
Enemy
.
MonsterZone
.
GetMatchingCardsCount
(
card
=>
card
.
Level
>=
7
)
>
0
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
private
bool
瞄准鹰坦克
summon
()
private
bool
瞄准鹰坦克
summon
()
{
{
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
)
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
_CardId
.
手枪龙
,
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
&&
Enemy
.
MonsterZone
.
GetMatchingCardsCount
(
card
=>
card
.
Level
>=
7
)
>
0
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
private
bool
瞄准鹰成金恐龙王
summon
()
private
bool
瞄准鹰成金恐龙王
summon
()
{
{
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
)
if
(
Bot
.
HasInMonstersZone
(
CardId
.
瞄准鹰
)
&&
Bot
.
HasInHand
(
new
[]
{
_CardId
.
手枪龙
,
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
})
&&
Enemy
.
MonsterZone
.
GetMatchingCardsCount
(
card
=>
card
.
Level
>=
7
)
>
0
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
...
@@ -391,7 +383,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -391,7 +383,7 @@ namespace WindBot.Game.AI.Decks
{
{
foreach
(
ClientCard
m
in
Bot
.
GetMonsters
())
foreach
(
ClientCard
m
in
Bot
.
GetMonsters
())
if
(
m
.
HasAttribute
(
CardAttribute
.
Light
)
&&
m
.
Level
<=
4
&&
m
.
IsFaceup
())
if
(
m
.
HasAttribute
(
CardAttribute
.
Light
)
&&
m
.
Level
<=
4
&&
m
.
IsFaceup
())
if
(
Bot
.
HasInHand
(
new
[]
{
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
}))
if
(
Bot
.
HasInHand
(
new
[]
{
_CardId
.
手枪龙
,
CardId
.
最强战旗
,
CardId
.
钢机神
,
CardId
.
恶德
}))
if
(
Enemy
.
MonsterZone
.
GetMatchingCardsCount
(
card
=>
card
.
Level
>=
7
)
>
0
)
if
(
Enemy
.
MonsterZone
.
GetMatchingCardsCount
(
card
=>
card
.
Level
>=
7
)
>
0
)
return
true
;
return
true
;
return
false
;
return
false
;
...
@@ -428,24 +420,24 @@ namespace WindBot.Game.AI.Decks
...
@@ -428,24 +420,24 @@ namespace WindBot.Game.AI.Decks
{
{
if
(
Bot
.
HasInHand
(
CardId
.
恶德
))
if
(
Bot
.
HasInHand
(
CardId
.
恶德
))
{
{
AI
.
SelectCard
(
CardId
.
恶德
);
AI
.
SelectCard
(
CardId
.
恶德
);
AI
.
SelectYesNo
(
true
);
return
true
;
return
true
;
}
}
else
if
(
Bot
.
HasInHand
(
CardId
.
钢机神
))
else
if
(
Bot
.
HasInHand
(
CardId
.
钢机神
))
{
{
AI
.
SelectCard
(
CardId
.
钢机神
);
AI
.
SelectCard
(
CardId
.
钢机神
);
AI
.
SelectYesNo
(
true
);
return
true
;
return
true
;
}
}
else
if
(
Bot
.
HasInHand
(
CardId
.
最强战旗
))
else
if
(
Bot
.
HasInHand
(
CardId
.
最强战旗
))
{
{
AI
.
SelectCard
(
CardId
.
最强战旗
);
AI
.
SelectCard
(
CardId
.
最强战旗
);
AI
.
SelectYesNo
(
true
);
return
true
;
return
true
;
}
}
else
if
(
Bot
.
HasInHand
(
_CardId
.
手枪龙
))
else
if
(
Bot
.
HasInHand
(
_CardId
.
手枪龙
))
{
{
AI
.
SelectCard
(
_CardId
.
手枪龙
);
AI
.
SelectCard
(
_CardId
.
手枪龙
);
AI
.
SelectYesNo
(
true
);
return
true
;
return
true
;
}
}
else
else
{
{
return
false
;
return
false
;
...
@@ -475,44 +467,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -475,44 +467,7 @@ namespace WindBot.Game.AI.Decks
return
true
;
return
true
;
return
false
;
return
false
;
}
}
private
bool
最强战旗
Effect
()
{
if
(
Util
.
IsOneEnemyBetterThanValue
(
1900
,
false
))
{
foreach
(
ClientCard
m
in
Bot
.
Hand
)
AI
.
SelectCard
(
m
)
;
foreach
(
ClientCard
mon
in
Enemy
.
GetMonsters
())
if
(
mon
.
Level
>=
9
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
8
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
7
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
5
)
AI
.
SelectNextCard
(
mon
);
return
true
;
}
return
false
;
}
private
bool
最强战旗
Eff
()
{
if
(
Util
.
IsOneEnemyBetterThanValue
(
2500
,
false
))
{
foreach
(
ClientCard
m
in
Bot
.
Hand
)
AI
.
SelectCard
(
m
);
foreach
(
ClientCard
mon
in
Enemy
.
GetMonsters
())
if
(
mon
.
Level
>=
9
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
8
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
7
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
5
)
AI
.
SelectNextCard
(
mon
);
return
true
;
}
return
false
;
}
private
bool
DefaultField2
()
private
bool
DefaultField2
()
{
{
if
(
Bot
.
GetHandCount
()
>=
2
)
if
(
Bot
.
GetHandCount
()
>=
2
)
...
...
Game/AI/Decks/TheLegendExecutor.cs
View file @
1f9ceee2
...
@@ -48,7 +48,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -48,7 +48,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
黑洞
,
黑洞
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
黑洞
,
黑洞
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
疾风弹
,
疾风弹
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
_CardId
.
疾风弹
,
疾风弹
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
小手枪龙
,
小手枪龙
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
小手枪龙
,
小手枪龙
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
海龙骑士
,
海龙骑士
Effect
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
海龙骑士
,
new
海龙骑士
Effect
);
//AddExecutor(ExecutorType.Activate, CardId.小手枪龙, DefaultMysticalSpaceTyphoon);
//AddExecutor(ExecutorType.Activate, CardId.小手枪龙, DefaultMysticalSpaceTyphoon);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
强欲之壶
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
强欲之壶
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
成金哥布林
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
成金哥布林
);
...
@@ -247,7 +247,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -247,7 +247,7 @@ namespace WindBot.Game.AI.Decks
}
}
return
false
;
return
false
;
}
}
private
bool
海龙骑士
Effect
()
private
bool
new
海龙骑士
Effect
()
{
{
List
<
ClientCard
>
spells
=
Enemy
.
GetSpells
();
List
<
ClientCard
>
spells
=
Enemy
.
GetSpells
();
ClientCard
selected
=
spells
.
FirstOrDefault
(
card
=>
card
.
IsFacedown
());
ClientCard
selected
=
spells
.
FirstOrDefault
(
card
=>
card
.
IsFacedown
());
...
@@ -321,19 +321,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -321,19 +321,6 @@ namespace WindBot.Game.AI.Decks
}
}
return
true
;
return
true
;
}
}
private
bool
斗牛士
Effect
()
{
//if (Util.IsOneEnemyBetterThanValue(1900, false))
{
foreach
(
ClientCard
o
in
Bot
.
Graveyard
)
AI
.
SelectCard
(
o
);
if
(
Enemy
.
GetMonsters
().
GetHighestAttackMonster
()
==
null
)
AI
.
SelectNextCard
(
Enemy
.
MonsterZone
.
GetHighestAttackMonster
());
return
true
;
}
// return false;
}
}
}
}
}
...
...
Game/AI/DefaultExecutor.cs
View file @
1f9ceee2
...
@@ -26,7 +26,8 @@ namespace WindBot.Game.AI
...
@@ -26,7 +26,8 @@ namespace WindBot.Game.AI
public
const
int
落穴
=
120150019
;
public
const
int
落穴
=
120150019
;
public
const
int
疾风弹
=
120203028
;
public
const
int
疾风弹
=
120203028
;
public
const
int
HMD
=
120130041
;
public
const
int
HMD
=
120130041
;
public
const
int
海龙骑士
=
120199032
;
public
const
int
耳语妖精
=
120120018
;
public
const
int
人造人
=
120155000
;
public
const
int
人造人
=
120155000
;
public
const
int
狼人
=
120214004
;
public
const
int
狼人
=
120214004
;
public
const
int
幻影之龙
=
120223102
;
public
const
int
幻影之龙
=
120223102
;
...
@@ -41,6 +42,8 @@ namespace WindBot.Game.AI
...
@@ -41,6 +42,8 @@ namespace WindBot.Game.AI
public
const
int
圣精灵
=
120194003
;
public
const
int
圣精灵
=
120194003
;
public
const
int
结界像
=
120226013
;
public
const
int
结界像
=
120226013
;
public
const
int
终焰魔神
=
120231008
;
public
const
int
终焰魔神
=
120231008
;
public
const
int
最强战旗
=
120181001
;
public
const
int
钢机神
=
120155015
;
public
const
int
JizukirutheStarDestroyingKaiju
=
63941210
;
public
const
int
JizukirutheStarDestroyingKaiju
=
63941210
;
public
const
int
ThunderKingtheLightningstrikeKaiju
=
48770333
;
public
const
int
ThunderKingtheLightningstrikeKaiju
=
48770333
;
public
const
int
DogorantheMadFlameKaiju
=
93332803
;
public
const
int
DogorantheMadFlameKaiju
=
93332803
;
...
@@ -351,6 +354,120 @@ namespace WindBot.Game.AI
...
@@ -351,6 +354,120 @@ namespace WindBot.Game.AI
return
true
;
return
true
;
}
}
protected
bool
斗牛士
Effect
()
{
{
foreach
(
ClientCard
o
in
Bot
.
Graveyard
)
AI
.
SelectCard
(
o
);
if
(
Enemy
.
GetMonsters
().
GetHighestAttackMonster
()
==
null
)
AI
.
SelectNextCard
(
Enemy
.
MonsterZone
.
GetHighestAttackMonster
());
return
true
;
}
}
protected
bool
海龙骑士
Effect
()
{
List
<
ClientCard
>
spells
=
Enemy
.
GetSpells
();
ClientCard
selected
=
spells
.
FirstOrDefault
(
card
=>
card
.
IsFacedown
());
foreach
(
ClientCard
m
in
Bot
.
GetGraveyardMonsters
())
AI
.
SelectCard
(
m
);
AI
.
SelectNextCard
(
selected
);
return
true
;
}
protected
bool
耳语妖精
Effect
()
{
IList
<
ClientCard
>
targets
=
new
List
<
ClientCard
>();
foreach
(
ClientCard
card
in
Enemy
.
GetGraveyardMonsters
())
{
if
(
card
.
Level
<=
4
)
targets
.
Add
(
card
);
if
(
card
.
Level
<=
6
)
targets
.
Add
(
card
);
else
targets
.
Add
(
card
);
}
AI
.
SelectCard
(
targets
);
return
true
;
}
protected
bool
钢机神
1
Effect
()
{
if
(
Enemy
.
HasDefendingMonster
()
&&
Enemy
.
GetMonsterCount
()
>=
1
&&
!
Util
.
IsOneEnemyBetterThanValue
(
2500
,
false
))
{
List
<
ClientCard
>
cards
=
new
List
<
ClientCard
>(
Bot
.
Graveyard
.
GetMatchingCards
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
Machine
)
>
0
));
cards
.
Sort
(
CardContainer
.
CompareCardLevel
);
ClientCard
selectedCard
=
null
;
for
(
int
i
=
cards
.
Count
-
1
;
i
>=
0
;
--
i
)
{
ClientCard
card
=
cards
[
i
];
if
((
selectedCard
==
null
||
card
.
Attack
>
selectedCard
.
Attack
))
{
selectedCard
=
card
;
break
;
}
}
if
(
selectedCard
!=
null
)
{
AI
.
SelectCard
(
selectedCard
);
return
true
;
}
}
return
false
;
}
protected
bool
钢机神
Effect
()
{
if
(
Duel
.
Turn
==
1
)
{
return
false
;
}
IList
<
ClientCard
>
targets
=
new
List
<
ClientCard
>();
foreach
(
ClientCard
m
in
Bot
.
GetGraveyardMonsters
())
{
if
(
m
.
Race
==
(
int
)
CardRace
.
Machine
)
targets
.
Add
(
m
);
}
AI
.
SelectCard
(
targets
);
return
true
;
}
protected
bool
最强战旗
Effect
()
{
if
(
Util
.
IsOneEnemyBetterThanValue
(
1900
,
false
))
{
foreach
(
ClientCard
m
in
Bot
.
Hand
)
AI
.
SelectCard
(
m
);
foreach
(
ClientCard
mon
in
Enemy
.
GetMonsters
())
if
(
mon
.
Level
>=
9
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
8
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
7
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
5
)
AI
.
SelectNextCard
(
mon
);
return
true
;
}
return
false
;
}
protected
bool
最强战旗
Eff
()
{
if
(
Util
.
IsOneEnemyBetterThanValue
(
2500
,
false
))
{
foreach
(
ClientCard
m
in
Bot
.
Hand
)
AI
.
SelectCard
(
m
);
foreach
(
ClientCard
mon
in
Enemy
.
GetMonsters
())
if
(
mon
.
Level
>=
9
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
8
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
7
)
AI
.
SelectNextCard
(
mon
);
else
if
(
mon
.
Level
>=
5
)
AI
.
SelectNextCard
(
mon
);
return
true
;
}
return
false
;
}
protected
bool
圣防
Repos
()
protected
bool
圣防
Repos
()
{
{
if
(
Enemy
.
Graveyard
.
GetMatchingCardsCount
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
SpellCaster
)
>
0
)
>=
4
&&
Enemy
.
GetSpellCountWithoutField
()
>=
1
if
(
Enemy
.
Graveyard
.
GetMatchingCardsCount
(
card
=>
(
card
.
Race
&
(
int
)
CardRace
.
SpellCaster
)
>
0
)
>=
4
&&
Enemy
.
GetSpellCountWithoutField
()
>=
1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment