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
9d28e904
Commit
9d28e904
authored
Apr 12, 2022
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update AI.SelectMaterials, fix EaterOfMillions
parent
296c7a5e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
33 additions
and
16 deletions
+33
-16
Game/AI/Decks/GrenMajuThunderBoarderExecutor.cs
Game/AI/Decks/GrenMajuThunderBoarderExecutor.cs
+3
-3
Game/AI/Decks/PhantasmExecutor.cs
Game/AI/Decks/PhantasmExecutor.cs
+5
-4
Game/AI/Decks/TrickstarExecutor.cs
Game/AI/Decks/TrickstarExecutor.cs
+2
-2
Game/GameAI.cs
Game/GameAI.cs
+23
-7
No files found.
Game/AI/Decks/GrenMajuThunderBoarderExecutor.cs
View file @
9d28e904
...
@@ -523,7 +523,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -523,7 +523,7 @@ namespace WindBot.Game.AI.Decks
targets
.
Add
(
e_c
);
targets
.
Add
(
e_c
);
if
(
targets
.
Count
>=
5
)
if
(
targets
.
Count
>=
5
)
{
{
AI
.
Select
Card
(
targets
);
AI
.
Select
Materials
(
targets
,
HintMsg
.
Remove
);
/*AI.SelectCard(new[] {
/*AI.SelectCard(new[] {
CardId.BingirsuTheWorldChaliceWarrior,
CardId.BingirsuTheWorldChaliceWarrior,
CardId.TopologicTrisbaena,
CardId.TopologicTrisbaena,
...
@@ -547,8 +547,8 @@ namespace WindBot.Game.AI.Decks
...
@@ -547,8 +547,8 @@ namespace WindBot.Game.AI.Decks
{
{
targets
.
Add
(
s_c
);
targets
.
Add
(
s_c
);
if
(
targets
.
Count
>=
5
)
if
(
targets
.
Count
>=
5
)
{
{
AI
.
Select
Card
(
targets
);
AI
.
Select
Materials
(
targets
,
HintMsg
.
Remove
);
return
true
;
return
true
;
}
}
}
}
...
...
Game/AI/Decks/PhantasmExecutor.cs
View file @
9d28e904
...
@@ -468,13 +468,13 @@ namespace WindBot.Game.AI.Decks
...
@@ -468,13 +468,13 @@ namespace WindBot.Game.AI.Decks
IList
<
ClientCard
>
material_list
=
new
List
<
ClientCard
>();
IList
<
ClientCard
>
material_list
=
new
List
<
ClientCard
>();
if
(
Bot
.
HasInExtra
(
CardId
.
BorreloadDragon
))
if
(
Bot
.
HasInExtra
(
CardId
.
BorreloadDragon
))
{
{
AI
.
Select
Card
(
AI
.
Select
Materials
(
new
[]
{
CardId
.
TopologicBomberDragon
,
CardId
.
TopologicBomberDragon
,
CardId
.
TopologicTrisbaena
,
CardId
.
TopologicTrisbaena
,
CardId
.
KnightmareGryphon
,
CardId
.
KnightmareGryphon
,
CardId
.
SummonSorceress
,
CardId
.
SummonSorceress
,
CardId
.
BorreloadDragon
CardId
.
BorreloadDragon
);
},
HintMsg
.
Remove
);
}
}
else
else
{
{
...
@@ -482,7 +482,8 @@ namespace WindBot.Game.AI.Decks
...
@@ -482,7 +482,8 @@ namespace WindBot.Game.AI.Decks
{
{
if
(
material_list
.
Count
==
5
)
break
;
if
(
material_list
.
Count
==
5
)
break
;
material_list
.
Add
(
m
);
material_list
.
Add
(
m
);
}
}
AI
.
SelectMaterials
(
material_list
,
HintMsg
.
Remove
);
}
}
return
true
;
return
true
;
}
}
...
...
Game/AI/Decks/TrickstarExecutor.cs
View file @
9d28e904
...
@@ -709,7 +709,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -709,7 +709,7 @@ namespace WindBot.Game.AI.Decks
targets
.
Add
(
e_c
);
targets
.
Add
(
e_c
);
if
(
targets
.
Count
>=
5
)
if
(
targets
.
Count
>=
5
)
{
{
AI
.
Select
Card
(
targets
);
AI
.
Select
Materials
(
targets
,
HintMsg
.
Remove
);
return
true
;
return
true
;
}
}
}
}
...
@@ -719,7 +719,7 @@ namespace WindBot.Game.AI.Decks
...
@@ -719,7 +719,7 @@ namespace WindBot.Game.AI.Decks
targets
.
Add
(
s_c
);
targets
.
Add
(
s_c
);
if
(
targets
.
Count
>=
5
)
if
(
targets
.
Count
>=
5
)
{
{
AI
.
Select
Card
(
targets
);
AI
.
Select
Materials
(
targets
,
HintMsg
.
Remove
);
return
true
;
return
true
;
}
}
}
}
...
...
Game/GameAI.cs
View file @
9d28e904
...
@@ -98,6 +98,7 @@ namespace WindBot.Game
...
@@ -98,6 +98,7 @@ namespace WindBot.Game
m_position
.
Clear
();
m_position
.
Clear
();
m_selector_pointer
=
-
1
;
m_selector_pointer
=
-
1
;
m_materialSelector
=
null
;
m_materialSelector
=
null
;
m_materialSelectorHint
=
0
;
m_option
=
-
1
;
m_option
=
-
1
;
m_yesno
=
-
1
;
m_yesno
=
-
1
;
m_announce
=
0
;
m_announce
=
0
;
...
@@ -267,8 +268,16 @@ namespace WindBot.Game
...
@@ -267,8 +268,16 @@ namespace WindBot.Game
}
}
else
else
{
{
// Update the next selector.
if
(
m_materialSelector
!=
null
&&
hint
==
m_materialSelectorHint
)
selector
=
GetSelectedCards
();
{
//Logger.DebugWriteLine("m_materialSelector hint match");
selector
=
m_materialSelector
;
}
else
{
// Update the next selector.
selector
=
GetSelectedCards
();
}
}
}
// If we selected a card, use this card.
// If we selected a card, use this card.
...
@@ -745,6 +754,7 @@ namespace WindBot.Game
...
@@ -745,6 +754,7 @@ namespace WindBot.Game
private
CardSelector
m_materialSelector
;
private
CardSelector
m_materialSelector
;
private
int
m_materialSelectorHint
;
private
int
m_place
;
private
int
m_place
;
private
int
m_option
;
private
int
m_option
;
private
int
m_number
;
private
int
m_number
;
...
@@ -912,34 +922,40 @@ namespace WindBot.Game
...
@@ -912,34 +922,40 @@ namespace WindBot.Game
m_selector
.
Insert
(
m_selector_pointer
,
new
CardSelector
(
loc
));
m_selector
.
Insert
(
m_selector_pointer
,
new
CardSelector
(
loc
));
}
}
public
void
SelectMaterials
(
ClientCard
card
)
public
void
SelectMaterials
(
ClientCard
card
,
int
hint
=
0
)
{
{
m_materialSelector
=
new
CardSelector
(
card
);
m_materialSelector
=
new
CardSelector
(
card
);
m_materialSelectorHint
=
hint
;
}
}
public
void
SelectMaterials
(
IList
<
ClientCard
>
cards
)
public
void
SelectMaterials
(
IList
<
ClientCard
>
cards
,
int
hint
=
0
)
{
{
m_materialSelector
=
new
CardSelector
(
cards
);
m_materialSelector
=
new
CardSelector
(
cards
);
m_materialSelectorHint
=
hint
;
}
}
public
void
SelectMaterials
(
int
cardId
)
public
void
SelectMaterials
(
int
cardId
,
int
hint
=
0
)
{
{
m_materialSelector
=
new
CardSelector
(
cardId
);
m_materialSelector
=
new
CardSelector
(
cardId
);
m_materialSelectorHint
=
hint
;
}
}
public
void
SelectMaterials
(
IList
<
int
>
ids
)
public
void
SelectMaterials
(
IList
<
int
>
ids
,
int
hint
=
0
)
{
{
m_materialSelector
=
new
CardSelector
(
ids
);
m_materialSelector
=
new
CardSelector
(
ids
);
m_materialSelectorHint
=
hint
;
}
}
public
void
SelectMaterials
(
CardLocation
loc
)
public
void
SelectMaterials
(
CardLocation
loc
,
int
hint
=
0
)
{
{
m_materialSelector
=
new
CardSelector
(
loc
);
m_materialSelector
=
new
CardSelector
(
loc
);
m_materialSelectorHint
=
hint
;
}
}
public
void
CleanSelectMaterials
()
public
void
CleanSelectMaterials
()
{
{
m_materialSelector
=
null
;
m_materialSelector
=
null
;
m_materialSelectorHint
=
0
;
}
}
public
bool
HaveSelectedCards
()
public
bool
HaveSelectedCards
()
...
...
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