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
Tang Xinwei
windbot
Commits
d5482925
Commit
d5482925
authored
Nov 08, 2020
by
wind2009
Committed by
mercury233
Jan 09, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Crossout Designator for Witchcraft
parent
eb222c82
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
Game/AI/Decks/WitchcraftExecutor.cs
Game/AI/Decks/WitchcraftExecutor.cs
+15
-0
No files found.
Game/AI/Decks/WitchcraftExecutor.cs
View file @
d5482925
...
...
@@ -446,6 +446,21 @@ namespace WindBot.Game.AI.Decks
/// <returns>Card's id to annouce.</returns>
public
override
int
OnAnnounceCard
(
IList
<
int
>
opcodes
,
int
preAnnouced
)
{
const
int
OPCODE_OR
=
0x40000005
;
const
int
OPCODE_ISCODE
=
0x40000100
;
IList
<
int
>
codes
=
new
List
<
int
>();
foreach
(
int
opcode
in
opcodes
)
{
if
(
opcode
!=
OPCODE_OR
&&
opcode
!=
OPCODE_ISCODE
)
{
codes
.
Add
(
opcode
);
}
}
// if annouced card not in required list, return random card from list.
if
(!
codes
.
Contains
(
preAnnouced
))
{
Logger
.
DebugWriteLine
(
"No annouced card in required list, annouce randomly."
);
return
codes
[
Program
.
Rand
.
Next
(
codes
.
Count
)];
}
return
base
.
OnAnnounceCard
(
opcodes
,
preAnnouced
);
}
...
...
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