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
xiaoye
windbot
Commits
ba5985d6
Commit
ba5985d6
authored
May 22, 2024
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add TeammateSurrender
parent
a3590dc2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
1 deletion
+9
-1
Game/GameBehavior.cs
Game/GameBehavior.cs
+7
-0
YGOSharp.Network/Enums/StocMessage.cs
YGOSharp.Network/Enums/StocMessage.cs
+2
-1
No files found.
Game/GameBehavior.cs
View file @
ba5985d6
...
...
@@ -85,6 +85,7 @@ namespace WindBot.Game
_packets
.
Add
(
StocMessage
.
Chat
,
OnChat
);
_packets
.
Add
(
StocMessage
.
ChangeSide
,
OnChangeSide
);
_packets
.
Add
(
StocMessage
.
ErrorMsg
,
OnErrorMsg
);
_packets
.
Add
(
StocMessage
.
TeammateSurrender
,
OnTeammateSurrender
);
_messages
.
Add
(
GameMessage
.
Retry
,
OnRetry
);
_messages
.
Add
(
GameMessage
.
Start
,
OnStart
);
...
...
@@ -325,6 +326,12 @@ namespace WindBot.Game
//Connection.Close();
}
private
void
OnTeammateSurrender
(
BinaryReader
packet
)
{
Thread
.
Sleep
(
500
);
Game
.
Surrender
();
}
private
void
OnRetry
(
BinaryReader
packet
)
{
_ai
.
OnRetry
();
...
...
YGOSharp.Network/Enums/StocMessage.cs
View file @
ba5985d6
...
...
@@ -21,6 +21,7 @@
Chat
=
0x19
,
HsPlayerEnter
=
0x20
,
HsPlayerChange
=
0x21
,
HsWatchChange
=
0x22
HsWatchChange
=
0x22
,
TeammateSurrender
=
0x23
}
}
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