Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
W
windbot
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
nanahira
windbot
Commits
8763f440
Commit
8763f440
authored
Apr 10, 2018
by
handsomekiwi
Committed by
mercury233
Apr 10, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update ChainBurn deck (#38)
parent
48052612
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
142 additions
and
60 deletions
+142
-60
Decks/AI_ChainBurn.ydk
Decks/AI_ChainBurn.ydk
+3
-3
Game/AI/Decks/ChainBurnExecutor.cs
Game/AI/Decks/ChainBurnExecutor.cs
+139
-57
No files found.
Decks/AI_ChainBurn.ydk
View file @
8763f440
...
@@ -37,7 +37,6 @@
...
@@ -37,7 +37,6 @@
36361633
36361633
36361633
36361633
36361633
36361633
36468556
37576645
37576645
37576645
37576645
37576645
37576645
...
@@ -52,7 +51,6 @@
...
@@ -52,7 +51,6 @@
75249652
75249652
83555666
83555666
98444741
98444741
98444741
#extra
#extra
41999284
41999284
41999284
41999284
...
@@ -66,3 +64,5 @@
...
@@ -66,3 +64,5 @@
100227025
100227025
100227025
100227025
100227025
100227025
36468556
98444741
\ No newline at end of file
Game/AI/Decks/ChainBurnExecutor.cs
View file @
8763f440
...
@@ -70,7 +70,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -70,7 +70,6 @@ namespace WindBot.Game.AI.Decks
//activate trap
//activate trap
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
BalanceOfJudgment
,
BalanceOfJudgmenteff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
BalanceOfJudgment
,
BalanceOfJudgmenteff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
AccuulatedFortune
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
AccuulatedFortune
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
ChainStrike
,
ChainStrikeeff
);
//battle
//battle
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
ThreateningRoar
,
ThreateningRoareff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
ThreateningRoar
,
ThreateningRoareff
);
...
@@ -86,7 +85,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -86,7 +85,7 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
SecretBlast
,
SecretBlasteff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
SecretBlast
,
SecretBlasteff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
SectetBarrel
,
SectetBarreleff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
SectetBarrel
,
SectetBarreleff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
RecklessGreed
,
RecklessGreedeff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
RecklessGreed
,
RecklessGreedeff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
ChainStrike
,
ChainStrikeeff
);
//sp
//sp
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Linkuriboh
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Linkuriboh
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Linkuriboh
,
Linkuriboheff
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Linkuriboh
,
Linkuriboheff
);
...
@@ -217,17 +216,25 @@ namespace WindBot.Game.AI.Decks
...
@@ -217,17 +216,25 @@ namespace WindBot.Game.AI.Decks
id
==
CardId
.
RingOfDestruction
id
==
CardId
.
RingOfDestruction
);
);
}
}
bool
pot_used
=
false
;
bool
no_sp
=
false
;
bool
one_turn_kill
=
false
;
bool
one_turn_kill
=
false
;
bool
one_turn_kill_1
=
false
;
int
expected_blood
=
0
;
int
expected_blood
=
0
;
bool
prevent_used
=
false
;
bool
prevent_used
=
false
;
int
preventcount
=
0
;
int
preventcount
=
0
;
bool
battleprevent
=
false
;
bool
battleprevent
=
false
;
bool
OjamaTrioused
=
false
;
bool
OjamaTrioused
=
false
;
bool
HasAccuulatedFortune
=
false
;
bool
OjamaTrioused_draw
=
false
;
bool
drawfirst
=
false
;
int
Waboku_count
=
0
;
int
Roar_count
=
0
;
int
strike_count
=
0
;
int
greed_count
=
0
;
int
blast_count
=
0
;
int
blast_count
=
0
;
int
barrel_count
=
0
;
int
barrel_count
=
0
;
int
just_count
=
0
;
int
just_count
=
0
;
int
Ojama_count
=
0
;
int
HasAccuulatedFortune
=
0
;
public
override
bool
OnSelectHand
()
public
override
bool
OnSelectHand
()
{
{
return
true
;
return
true
;
...
@@ -237,23 +244,20 @@ namespace WindBot.Game.AI.Decks
...
@@ -237,23 +244,20 @@ namespace WindBot.Game.AI.Decks
{
{
pot_used
=
false
;
no_sp
=
false
;
prevent_used
=
false
;
prevent_used
=
false
;
battleprevent
=
false
;
battleprevent
=
false
;
OjamaTrioused
=
false
;
}
}
public
override
void
OnNewPhase
()
public
override
void
OnNewPhase
()
{
{
preventcount
=
0
;
preventcount
=
0
;
battleprevent
=
false
;
battleprevent
=
false
;
HasAccuulatedFortune
=
false
;
OjamaTrioused
=
false
;
IList
<
ClientCard
>
trap
=
Bot
.
SpellZone
;
IList
<
ClientCard
>
trap
=
Bot
.
SpellZone
;
IList
<
ClientCard
>
monster
=
Bot
.
MonsterZone
;
IList
<
ClientCard
>
monster
=
Bot
.
MonsterZone
;
foreach
(
ClientCard
card
in
trap
)
{
if
(
card
.
Id
==
CardId
.
AccuulatedFortune
)
HasAccuulatedFortune
=
true
;
}
foreach
(
ClientCard
card
in
trap
)
foreach
(
ClientCard
card
in
trap
)
{
{
if
(
Has_prevent_list
(
card
.
Id
))
if
(
Has_prevent_list
(
card
.
Id
))
...
@@ -272,33 +276,95 @@ namespace WindBot.Game.AI.Decks
...
@@ -272,33 +276,95 @@ namespace WindBot.Game.AI.Decks
}
}
}
}
expected_blood
=
0
;
expected_blood
=
0
;
one_turn_kill
=
false
;
one_turn_kill
=
false
;
one_turn_kill_1
=
false
;
OjamaTrioused_draw
=
false
;
drawfirst
=
false
;
HasAccuulatedFortune
=
0
;
strike_count
=
0
;
greed_count
=
0
;
blast_count
=
0
;
blast_count
=
0
;
barrel_count
=
0
;
barrel_count
=
0
;
just_count
=
0
;
just_count
=
0
;
Waboku_count
=
0
;
Roar_count
=
0
;
Ojama_count
=
0
;
IList
<
ClientCard
>
check
=
Bot
.
SpellZone
;
IList
<
ClientCard
>
check
=
Bot
.
SpellZone
;
foreach
(
ClientCard
card
in
check
)
foreach
(
ClientCard
card
in
check
)
{
if
(
card
.
Id
==
CardId
.
AccuulatedFortune
)
HasAccuulatedFortune
++;
}
foreach
(
ClientCard
card
in
check
)
{
{
if
(
card
.
Id
==
CardId
.
SecretBlast
)
if
(
card
.
Id
==
CardId
.
SecretBlast
)
blast_count
++;
blast_count
++;
break
;
}
}
foreach
(
ClientCard
card
in
check
)
foreach
(
ClientCard
card
in
check
)
{
{
if
(
card
.
Id
==
CardId
.
SectetBarrel
)
if
(
card
.
Id
==
CardId
.
SectetBarrel
)
barrel_count
++;
barrel_count
++;
break
;
}
}
foreach
(
ClientCard
card
in
check
)
foreach
(
ClientCard
card
in
check
)
{
{
if
(
card
.
Id
==
CardId
.
JustDesserts
)
if
(
card
.
Id
==
CardId
.
JustDesserts
)
just_count
++;
just_count
++;
break
;
}
}
foreach
(
ClientCard
card
in
check
)
{
if
(
card
.
Id
==
CardId
.
ChainStrike
)
strike_count
++;
}
foreach
(
ClientCard
card
in
Bot
.
GetSpells
())
{
if
(
card
.
Id
==
CardId
.
RecklessGreed
)
greed_count
++;
}
foreach
(
ClientCard
card
in
check
)
{
if
(
card
.
Id
==
CardId
.
Waboku
)
Waboku_count
++;
}
foreach
(
ClientCard
card
in
check
)
{
if
(
card
.
Id
==
CardId
.
ThreateningRoar
)
Roar_count
++;
}
if
(
Bot
.
HasInSpellZone
(
CardId
.
OjamaTrio
)
&&
Enemy
.
GetMonsterCount
()
<=
2
&&
Enemy
.
GetMonsterCount
()
>=
1
)
{
if
(
HasAccuulatedFortune
>
0
)
OjamaTrioused_draw
=
true
;
}
expected_blood
=
(
Enemy
.
GetMonsterCount
()
*
500
*
just_count
+
Enemy
.
GetFieldHandCount
()
*
200
*
barrel_count
+
Enemy
.
GetFieldCount
()
*
300
*
blast_count
);
expected_blood
=
(
Enemy
.
GetMonsterCount
()
*
500
*
just_count
+
Enemy
.
GetFieldHandCount
()
*
200
*
barrel_count
+
Enemy
.
GetFieldCount
()
*
300
*
blast_count
);
if
(
Enemy
.
LifePoints
<=
expected_blood
)
if
(
Enemy
.
LifePoints
<=
expected_blood
)
one_turn_kill
=
true
;
one_turn_kill
=
true
;
if
(
greed_count
>=
2
)
greed_count
=
1
;
if
(
blast_count
>=
2
)
blast_count
=
1
;
if
(
just_count
>=
2
)
just_count
=
1
;
if
(
barrel_count
>=
2
)
barrel_count
=
1
;
if
(
Waboku_count
>=
2
)
Waboku_count
=
1
;
if
(
Roar_count
>=
2
)
Roar_count
=
1
;
if
(
strike_count
>=
2
)
strike_count
=
1
;
int
currentchain
=
0
;
if
(
OjamaTrioused_draw
)
currentchain
=
Duel
.
CurrentChain
.
Count
+
blast_count
+
just_count
+
barrel_count
+
Waboku_count
+
Waboku_count
+
Roar_count
+
greed_count
+
strike_count
+
Ojama_count
;
else
currentchain
=
Duel
.
CurrentChain
.
Count
+
blast_count
+
just_count
+
barrel_count
+
Waboku_count
+
Waboku_count
+
greed_count
+
Roar_count
+
strike_count
;
if
(
currentchain
>=
3
)
drawfirst
=
true
;
currentchain
=
Duel
.
CurrentChain
.
Count
+
blast_count
+
just_count
+
barrel_count
;
expected_blood
=
(
Enemy
.
GetMonsterCount
()
*
500
*
just_count
+
Enemy
.
GetFieldHandCount
()
*
200
*
barrel_count
+
Enemy
.
GetFieldCount
()
*
300
*
blast_count
+(
currentchain
+
1
)*
400
);
if
(
Enemy
.
LifePoints
<=
expected_blood
)
one_turn_kill_1
=
true
;
}
}
...
@@ -326,7 +392,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -326,7 +392,7 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
AbouluteKingBackJacksummon
()
private
bool
AbouluteKingBackJacksummon
()
{
{
return
!
pot_used
;
return
!
no_sp
;
}
}
private
bool
AbouluteKingBackJackeff
()
private
bool
AbouluteKingBackJackeff
()
{
{
...
@@ -342,7 +408,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -342,7 +408,7 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
PotOfDualityeff
()
private
bool
PotOfDualityeff
()
{
{
pot_used
=
true
;
no_sp
=
true
;
AI
.
SelectCard
(
prevent_list
());
AI
.
SelectCard
(
prevent_list
());
return
true
;
return
true
;
}
}
...
@@ -360,7 +426,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -360,7 +426,7 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
ThreateningRoareff
()
private
bool
ThreateningRoareff
()
{
{
if
(
drawfirst
)
return
true
;
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
if
(
prevent_used
||
Duel
.
Phase
!=
DuelPhase
.
Main1
)
return
false
;
if
(
prevent_used
||
Duel
.
Phase
!=
DuelPhase
.
Main1
)
return
false
;
prevent_used
=
true
;
prevent_used
=
true
;
...
@@ -368,12 +434,15 @@ namespace WindBot.Game.AI.Decks
...
@@ -368,12 +434,15 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
SandaionTheTimloardeff
()
private
bool
SandaionTheTimloardeff
()
{
{
prevent_used
=
true
;
prevent_used
=
true
;
return
true
;
return
true
;
}
}
private
bool
Wabokueff
()
private
bool
Wabokueff
()
{
{
if
(
drawfirst
)
return
true
;
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
if
(
drawfirst
)
return
true
;
if
(
prevent_used
||
Duel
.
Player
==
0
||
Duel
.
Phase
!=
DuelPhase
.
BattleStart
)
return
false
;
if
(
prevent_used
||
Duel
.
Player
==
0
||
Duel
.
Phase
!=
DuelPhase
.
BattleStart
)
return
false
;
prevent_used
=
true
;
prevent_used
=
true
;
return
DefaultUniqueTrap
();
return
DefaultUniqueTrap
();
...
@@ -410,21 +479,18 @@ namespace WindBot.Game.AI.Decks
...
@@ -410,21 +479,18 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
RecklessGreedeff
()
private
bool
RecklessGreedeff
()
{
{
int
count
=
0
;
if
(
drawfirst
)
return
DefaultUniqueTrap
();
foreach
(
ClientCard
card
in
Bot
.
GetSpells
())
if
(
must_chain
()
&&
greed_count
>
1
)
return
true
;
{
if
(
greed_count
>
1
)
return
true
;
if
(
card
.
Id
==
CardId
.
RecklessGreed
)
count
++;
break
;
}
if
(
count
>
1
)
return
true
;
if
(
Bot
.
LifePoints
<=
2000
)
return
true
;
if
(
Bot
.
LifePoints
<=
2000
)
return
true
;
if
(
Bot
.
GetHandCount
()
<
1
&&
Duel
.
Player
==
0
&&
Duel
.
Phase
!=
DuelPhase
.
Standby
)
return
true
;
if
(
Bot
.
GetHandCount
()
<
1
&&
Duel
.
Player
==
0
&&
Duel
.
Phase
!=
DuelPhase
.
Standby
)
return
true
;
return
false
;
return
false
;
}
}
private
bool
SectetBarreleff
()
private
bool
SectetBarreleff
()
{
{
if
(
one_turn_kill
)
return
true
;
if
(
drawfirst
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill_1
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill
)
return
DefaultUniqueTrap
();
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
int
count
=
Enemy
.
GetFieldHandCount
();
int
count
=
Enemy
.
GetFieldHandCount
();
if
(
Enemy
.
LifePoints
<
count
*
200
)
return
true
;
if
(
Enemy
.
LifePoints
<
count
*
200
)
return
true
;
...
@@ -433,7 +499,9 @@ namespace WindBot.Game.AI.Decks
...
@@ -433,7 +499,9 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
SecretBlasteff
()
private
bool
SecretBlasteff
()
{
{
if
(
one_turn_kill
)
return
true
;
if
(
drawfirst
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill_1
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill
)
return
DefaultUniqueTrap
();
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
int
count
=
Enemy
.
GetFieldCount
();
int
count
=
Enemy
.
GetFieldCount
();
if
(
Enemy
.
LifePoints
<
count
*
300
)
return
true
;
if
(
Enemy
.
LifePoints
<
count
*
300
)
return
true
;
...
@@ -443,16 +511,19 @@ namespace WindBot.Game.AI.Decks
...
@@ -443,16 +511,19 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
OjamaTrioset
()
private
bool
OjamaTrioset
()
{
{
if
(
Bot
.
HasInSpellZone
(
CardId
.
OjamaTrio
))
return
false
;
if
(
Bot
.
HasInSpellZone
(
CardId
.
OjamaTrio
))
return
false
;
return
true
;
return
true
;
}
}
private
bool
OjamaTrioeff
()
private
bool
OjamaTrioeff
()
{
{
return
OjamaTrioused
;
return
OjamaTrioused
||
OjamaTrioused_draw
;
}
}
private
bool
JustDessertseff
()
private
bool
JustDessertseff
()
{
{
if
(
one_turn_kill
)
return
true
;
if
(
drawfirst
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill_1
)
return
DefaultUniqueTrap
();
if
(
one_turn_kill
)
return
DefaultUniqueTrap
();
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
int
count
=
Enemy
.
GetMonsterCount
();
int
count
=
Enemy
.
GetMonsterCount
();
if
(
Enemy
.
LifePoints
<=
count
*
500
)
return
true
;
if
(
Enemy
.
LifePoints
<=
count
*
500
)
return
true
;
...
@@ -466,8 +537,10 @@ namespace WindBot.Game.AI.Decks
...
@@ -466,8 +537,10 @@ namespace WindBot.Game.AI.Decks
}
}
private
bool
ChainStrikeeff
()
private
bool
ChainStrikeeff
()
{
{
if
(
drawfirst
)
return
true
;
if
(
must_chain
())
return
true
;
if
(
must_chain
())
return
true
;
int
chain
=
Duel
.
CurrentChain
.
Count
;
int
chain
=
Duel
.
CurrentChain
.
Count
;
if
(
strike_count
>=
2
&&
chain
>=
2
)
return
true
;
if
(
Enemy
.
LifePoints
<=
(
chain
+
1
)
*
400
)
return
true
;
if
(
Enemy
.
LifePoints
<=
(
chain
+
1
)
*
400
)
return
true
;
if
(
Duel
.
CurrentChain
.
Count
>=
3
)
return
true
;
if
(
Duel
.
CurrentChain
.
Count
>=
3
)
return
true
;
return
false
;
return
false
;
...
@@ -483,7 +556,10 @@ namespace WindBot.Game.AI.Decks
...
@@ -483,7 +556,10 @@ namespace WindBot.Game.AI.Decks
private
bool
CardOfDemiseeff
()
private
bool
CardOfDemiseeff
()
{
{
if
(
Bot
.
GetHandCount
()
==
1
&&
Bot
.
GetSpellCountWithoutField
()
<=
3
)
if
(
Bot
.
GetHandCount
()
==
1
&&
Bot
.
GetSpellCountWithoutField
()
<=
3
)
{
no_sp
=
true
;
return
true
;
return
true
;
}
return
false
;
return
false
;
}
}
private
bool
Mathematicianeff
()
private
bool
Mathematicianeff
()
...
@@ -522,6 +598,12 @@ namespace WindBot.Game.AI.Decks
...
@@ -522,6 +598,12 @@ namespace WindBot.Game.AI.Decks
if
(
lastchaincard
.
Id
==
CardId
.
Linkuriboh
)
return
false
;
if
(
lastchaincard
.
Id
==
CardId
.
Linkuriboh
)
return
false
;
return
true
;
return
true
;
}
}
public
override
bool
OnPreBattleBetween
(
ClientCard
attacker
,
ClientCard
defender
)
{
if
(
attacker
.
Id
==
CardId
.
Linkuriboh
&&
defender
.
IsFacedown
())
return
false
;
return
base
.
OnPreBattleBetween
(
attacker
,
defender
);
}
/*private bool SwordsOfRevealingLight()
/*private bool SwordsOfRevealingLight()
{
{
int count = Bot.SpellZone.GetCardCount(CardId.SwordsOfRevealingLight);
int count = Bot.SpellZone.GetCardCount(CardId.SwordsOfRevealingLight);
...
...
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