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
4a0dc098
Commit
4a0dc098
authored
Jul 09, 2024
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update SuperheavySamuraiExecutor
merge #197
parent
eb5d8f48
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
44 additions
and
22 deletions
+44
-22
Game/AI/Decks/SuperheavySamuraiExecutor.cs
Game/AI/Decks/SuperheavySamuraiExecutor.cs
+44
-22
No files found.
Game/AI/Decks/SuperheavySamuraiExecutor.cs
View file @
4a0dc098
...
@@ -80,7 +80,8 @@ namespace WindBot.Game.AI.Decks
...
@@ -80,7 +80,8 @@ namespace WindBot.Game.AI.Decks
public
SuperheavySamuraiExecutor
(
GameAI
ai
,
Duel
duel
)
public
SuperheavySamuraiExecutor
(
GameAI
ai
,
Duel
duel
)
:
base
(
ai
,
duel
)
:
base
(
ai
,
duel
)
{
{
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
PSYFramelordOmega
);
AddExecutor
(
ExecutorType
.
Repos
,
MonsterRepos
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
PSYFramelordOmega
,
PSYFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
IP
,
IPFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
IP
,
IPFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Sarutobi
,
SarutobiFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Sarutobi
,
SarutobiFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Unicorn
,
UnicornFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Unicorn
,
UnicornFunction
);
...
@@ -101,9 +102,8 @@ namespace WindBot.Game.AI.Decks
...
@@ -101,9 +102,8 @@ namespace WindBot.Game.AI.Decks
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Scales
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Scales
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Scales
,
ScalesFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Scales
,
ScalesFunction
);
//Synchron
//Synchron
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
ASStardustDragon
,
ASStardustDragonSynchronFunction2
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
PSYFramelordOmega
,
PSYFramelordOmegaSynchronFunction
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Fleur
,
FleurSynchronFunction2
);
//Pendulum
//Pendulum
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Wakaushi
,
WakaushiFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Wakaushi
,
WakaushiFunction
);
...
@@ -183,7 +183,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -183,7 +183,6 @@ namespace WindBot.Game.AI.Decks
//Synchron
//Synchron
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Masurawo
,
MasurawoSynchronFunction
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Masurawo
,
MasurawoSynchronFunction
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Sarutobi
,
DeSynchronFunction
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
Sarutobi
,
DeSynchronFunction
);
AddExecutor
(
ExecutorType
.
SpSummon
,
CardId
.
PSYFramelordOmega
);
//equip Soulhorns
//equip Soulhorns
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Soulhorns
,
SoulhornsEquipFunction
);
AddExecutor
(
ExecutorType
.
Activate
,
CardId
.
Soulhorns
,
SoulhornsEquipFunction
);
...
@@ -213,12 +212,29 @@ namespace WindBot.Game.AI.Decks
...
@@ -213,12 +212,29 @@ namespace WindBot.Game.AI.Decks
activate_Genius
=
false
;
activate_Genius
=
false
;
activate_Sarutobi
=
false
;
activate_Sarutobi
=
false
;
to_deck
=
false
;
to_deck
=
false
;
base
.
OnNewTurn
();
}
}
public
override
bool
OnSelectHand
()
public
override
bool
OnSelectHand
()
{
{
return
true
;
return
true
;
}
}
private
bool
MonsterRepos
()
{
if
(
Card
.
IsFacedown
())
return
true
;
if
(
Card
.
IsFaceup
()
&&
Card
.
IsAttack
()
&&
(
Card
.
Id
==
CardId
.
Masurawo
||
Card
.
Id
==
CardId
.
Sarutobi
))
return
true
;
return
false
;
}
public
override
CardPosition
OnSelectPosition
(
int
cardId
,
IList
<
CardPosition
>
positions
)
{
YGOSharp
.
OCGWrapper
.
NamedCard
cardData
=
YGOSharp
.
OCGWrapper
.
NamedCard
.
Get
(
cardId
);
if
(
cardData
!=
null
)
{
if
(
cardId
==
CardId
.
Masurawo
||
cardId
==
CardId
.
Sarutobi
)
return
CardPosition
.
FaceUpDefence
;
}
return
0
;
}
public
override
int
OnSelectPlace
(
int
cardId
,
int
player
,
CardLocation
location
,
int
available
)
public
override
int
OnSelectPlace
(
int
cardId
,
int
player
,
CardLocation
location
,
int
available
)
{
{
if
(
player
==
0
&&
location
==
CardLocation
.
MonsterZone
)
if
(
player
==
0
&&
location
==
CardLocation
.
MonsterZone
)
...
@@ -597,14 +613,6 @@ namespace WindBot.Game.AI.Decks
...
@@ -597,14 +613,6 @@ namespace WindBot.Game.AI.Decks
AI
.
SelectMaterials
(
materials_lists
[
0
]);
AI
.
SelectMaterials
(
materials_lists
[
0
]);
return
true
;
return
true
;
}
}
private
bool
FleurSynchronFunction2
()
{
var
materials_lists
=
Util
.
GetSynchroMaterials
(
Bot
.
MonsterZone
,
10
,
1
,
1
,
false
,
false
,
null
,
card
=>
{
return
!
FinalCards
(
card
.
Id
);
});
if
(
materials_lists
.
Count
<=
0
)
return
false
;
AI
.
SelectMaterials
(
materials_lists
[
0
]);
return
true
;
}
private
bool
DeSynchronFunction
()
private
bool
DeSynchronFunction
()
{
{
AI
.
SelectPosition
(
CardPosition
.
FaceUpDefence
);
AI
.
SelectPosition
(
CardPosition
.
FaceUpDefence
);
...
@@ -630,17 +638,26 @@ namespace WindBot.Game.AI.Decks
...
@@ -630,17 +638,26 @@ namespace WindBot.Game.AI.Decks
{
{
return
(
Bot
.
HasInExtra
(
CardId
.
Fleur
)
||
Bot
.
HasInExtra
(
CardId
.
Masurawo
));
return
(
Bot
.
HasInExtra
(
CardId
.
Fleur
)
||
Bot
.
HasInExtra
(
CardId
.
Masurawo
));
}
}
return
false
;
else
if
(
Bot
.
HasInMonstersZone
(
CardId
.
Motorbike
))
}
private
bool
ASStardustDragonSynchronFunction2
()
{
if
(!
activate_Scales
||
!
activate_PSY
)
return
false
;
if
(
Bot
.
HasInGraveyard
(
CardId
.
Motorbike
)
||
Bot
.
HasInGraveyard
(
CardId
.
PsyFramegearGamma
))
{
{
return
(
Bot
.
HasInExtra
(
CardId
.
Fleur
)
||
Bot
.
HasInExtra
(
CardId
.
Masurawo
));
AI
.
SelectMaterials
(
CardId
.
Motorbike
);
return
true
;
}
else
if
(
Bot
.
HasInMonstersZone
(
CardId
.
PsyFramegearGamma
))
{
AI
.
SelectMaterials
(
CardId
.
PsyFramegearGamma
);
return
true
;
}
}
return
false
;
return
false
;
}
}
private
bool
PSYFramelordOmegaSynchronFunction
()
{
if
(
Bot
.
HasInMonstersZone
(
CardId
.
Motorbike
))
AI
.
SelectMaterials
(
CardId
.
Motorbike
);
else
if
(
Bot
.
HasInMonstersZone
(
CardId
.
PsyFramegearGamma
))
AI
.
SelectMaterials
(
CardId
.
PsyFramegearGamma
);
return
activate_PSY
||
activate_Scales
;
}
private
bool
SavageDragonFunction
()
private
bool
SavageDragonFunction
()
{
{
if
(
Duel
.
LastChainPlayer
==
1
)
if
(
Duel
.
LastChainPlayer
==
1
)
...
@@ -1156,6 +1173,11 @@ namespace WindBot.Game.AI.Decks
...
@@ -1156,6 +1173,11 @@ namespace WindBot.Game.AI.Decks
AI
.
SelectMaterials
(
materials
);
AI
.
SelectMaterials
(
materials
);
return
true
;
return
true
;
}
}
private
bool
PSYFunction
()
{
activate_PSY
=
true
;
return
true
;
}
private
bool
IPFunction
()
private
bool
IPFunction
()
{
{
if
(
Duel
.
LastChainPlayer
==
0
)
return
false
;
if
(
Duel
.
LastChainPlayer
==
0
)
return
false
;
...
@@ -1193,4 +1215,4 @@ namespace WindBot.Game.AI.Decks
...
@@ -1193,4 +1215,4 @@ namespace WindBot.Game.AI.Decks
return
true
;
return
true
;
}
}
}
}
}
}
\ No newline at end of file
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