Commit 7828ff96 authored by mercury233's avatar mercury233

update

parent 09d16cf4
......@@ -14,3 +14,4 @@
/gframe/ygopro.aps
ygopro
premake5.exe
premake5
......@@ -3,7 +3,7 @@ include "lzma"
project "ygopro"
kind "ConsoleApp"
defines { "YGOPRO_SERVER_MODE" }
defines { "YGOPRO_SERVER_MODE" }
files { "gframe.cpp", "config.h",
"game.cpp", "game.h",
......@@ -12,8 +12,7 @@ project "ygopro"
"replay.cpp", "replay.h",
"netserver.cpp", "netserver.h",
"single_duel.cpp", "single_duel.h",
"tag_duel.cpp", "tag_duel.h",
"**.cc", "**.c"}
"tag_duel.cpp", "tag_duel.h" }
includedirs { "../ocgcore" }
links { "ocgcore", "clzma", "sqlite3", "lua" , "event"}
......
......@@ -203,10 +203,12 @@ void SingleDuel::LeaveGame(DuelPlayer* dp) {
NetServer::StopServer();
return;
}
ready[host_pos] = false;
STOC_TypeChange sctc;
sctc.type = 0x10 | host_pos;
NetServer::SendPacketToPlayer(players[host_pos], STOC_TYPE_CHANGE, sctc);
if(!game_started) {
ready[host_pos] = false;
STOC_TypeChange sctc;
sctc.type = 0x10 | host_pos;
NetServer::SendPacketToPlayer(players[host_pos], STOC_TYPE_CHANGE, sctc);
}
}
if(dp->type == NETPLAYER_TYPE_OBSERVER) {
#else
......
......@@ -175,10 +175,12 @@ void TagDuel::LeaveGame(DuelPlayer* dp) {
NetServer::StopServer();
return;
}
ready[host_pos] = false;
STOC_TypeChange sctc;
sctc.type = 0x10 | host_pos;
NetServer::SendPacketToPlayer(players[host_pos], STOC_TYPE_CHANGE, sctc);
if(!game_started) {
ready[host_pos] = false;
STOC_TypeChange sctc;
sctc.type = 0x10 | host_pos;
NetServer::SendPacketToPlayer(players[host_pos], STOC_TYPE_CHANGE, sctc);
}
}
if(dp->type == NETPLAYER_TYPE_OBSERVER) {
#else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment