1
This commit is contained in:
parent
2cfe2876a9
commit
b61e760398
@ -1779,19 +1779,19 @@ void Human::SendUpdateMsg()
|
||||
void Human::SendGameOver()
|
||||
{
|
||||
if (IsEntitySubType(EST_Player)) {
|
||||
//!!!必须要在SendNotifyMsg之前注意哦
|
||||
if (!sent_battlereport_) {
|
||||
SendBattleReport();
|
||||
sent_battlereport_ = true;
|
||||
GameLog::Instance()->GameEnd((Player*)this);
|
||||
}
|
||||
{
|
||||
if (already_report_battle_) {
|
||||
cs::SMGameOver msg;
|
||||
FillSMGameOver(msg);
|
||||
SendNotifyMsg(msg);
|
||||
#ifdef DEBUG
|
||||
a8::XPrintf("SendGameOver socket_handle:%d\n", {socket_handle});
|
||||
#endif
|
||||
} else {
|
||||
if (!sending_battlereport_) {
|
||||
sending_battlereport_ = true;
|
||||
SendBattleReport();
|
||||
}
|
||||
if (!is_game_end_) {
|
||||
GameLog::Instance()->GameEnd((Player*)this);
|
||||
is_game_end_ = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -423,8 +423,8 @@ private:
|
||||
std::array<ObjectSyncFlags, FIXED_OBJECT_MAXID> fixed_object_sync_flags_ = {};
|
||||
|
||||
bool already_report_battle_ = false;
|
||||
bool sent_battlereport_ = false;
|
||||
bool sent_game_end_ = false;
|
||||
bool sending_battlereport_ = false;
|
||||
bool is_game_end_ = false;
|
||||
|
||||
long long jump_frameno_ = 0;
|
||||
float old_sync_speed = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user