1
This commit is contained in:
parent
bbc15afd7e
commit
81816d91be
@ -45,7 +45,6 @@ void Player::Init(int idx,
|
|||||||
f8::UdpLog::Instance()->Warning
|
f8::UdpLog::Instance()->Warning
|
||||||
("WebSocketClient on_disconnect", {});
|
("WebSocketClient on_disconnect", {});
|
||||||
};
|
};
|
||||||
#if 0
|
|
||||||
web_socket_->on_decode_userpacket =
|
web_socket_->on_decode_userpacket =
|
||||||
[this, socket_handle = GetSocketId()]
|
[this, socket_handle = GetSocketId()]
|
||||||
(char* buf, int& offset, unsigned int buflen)
|
(char* buf, int& offset, unsigned int buflen)
|
||||||
@ -57,15 +56,16 @@ void Player::Init(int idx,
|
|||||||
if (buflen - offset < sizeof(f8::PackHead) + p->packlen) {
|
if (buflen - offset < sizeof(f8::PackHead) + p->packlen) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
App::Instance()->AddSocketMsg
|
f8::App::Instance()->AddSocketMsg
|
||||||
(SF_GameServer,
|
(0,//SF_GameServer,
|
||||||
socket_handle,
|
socket_handle,
|
||||||
//p->ip_saddr,
|
//p->ip_saddr,
|
||||||
0,
|
0,
|
||||||
p->msgid,
|
p->msgid,
|
||||||
p->seqid,
|
p->seqid,
|
||||||
&buf[offset + sizeof(f8::PackHead)],
|
&buf[offset + sizeof(f8::PackHead)],
|
||||||
p->packlen);
|
p->packlen,
|
||||||
|
0);
|
||||||
offset += sizeof(f8::PackHead) + p->packlen;
|
offset += sizeof(f8::PackHead) + p->packlen;
|
||||||
} else {
|
} else {
|
||||||
warning = true;
|
warning = true;
|
||||||
@ -78,7 +78,6 @@ void Player::Init(int idx,
|
|||||||
f8::UdpLog::Instance()->Warning("收到client非法数据包", {});
|
f8::UdpLog::Instance()->Warning("收到client非法数据包", {});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
#endif
|
|
||||||
f8::CoMgr::Instance()->CreateCo
|
f8::CoMgr::Instance()->CreateCo
|
||||||
(
|
(
|
||||||
[this] (f8::Coroutine* co)
|
[this] (f8::Coroutine* co)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user