Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
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
ygopro
Commits
bb0a11b8
Commit
bb0a11b8
authored
May 23, 2020
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
poc of infinite time cheat
parent
be988d54
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
gframe/duelclient.cpp
gframe/duelclient.cpp
+8
-1
No files found.
gframe/duelclient.cpp
View file @
bb0a11b8
...
...
@@ -590,6 +590,7 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
mainGame->dInfo.time_left[1] = 0;
mainGame->dInfo.time_player = 2;
mainGame->dInfo.isReplaySwapped = false;
mainGame->dInfo.isReconnected = false;
mainGame->is_building = false;
mainGame->wCardImg->setVisible(true);
mainGame->wInfos->setVisible(true);
...
...
@@ -666,6 +667,7 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
mainGame->gMutex.lock();
mainGame->dInfo.isStarted = false;
mainGame->dInfo.isFinished = true;
mainGame->dInfo.isReconnected = false;
mainGame->is_building = false;
mainGame->wDeckEdit->setVisible(false);
mainGame->btnCreateHost->setEnabled(true);
...
...
@@ -733,8 +735,11 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
case STOC_TIME_LIMIT: {
STOC_TimeLimit* pkt = (STOC_TimeLimit*)pdata;
int lplayer = mainGame->LocalPlayer(pkt->player);
if(lplayer == 0)
if(lplayer == 0 && mainGame->dInfo.isReconnected)
{
mainGame->dInfo.isReconnected = false;
DuelClient::SendPacketToServer(CTOS_TIME_CONFIRM);
}
mainGame->dInfo.time_player = lplayer;
mainGame->dInfo.time_left[lplayer] = pkt->left_time;
break;
...
...
@@ -3766,6 +3771,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
mainGame->gMutex.lock();
mainGame->dField.Clear();
mainGame->dInfo.duel_rule = BufferIO::ReadInt8(pbuf);
mainGame->dInfo.isReconnected = true;
int val = 0;
for(int i = 0; i < 2; ++i) {
int p = mainGame->LocalPlayer(i);
...
...
@@ -3936,6 +3942,7 @@ void DuelClient::SendResponse() {
mainGame->singleSignal.Set();
} else {
mainGame->dInfo.time_player = 2;
SendPacketToServer(CTOS_TIME_CONFIRM);
SendBufferToServer(CTOS_RESPONSE, response_buf, response_len);
}
}
...
...
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