mirror of
https://gitlab.com/Mr_Goldberg/goldberg_emulator.git
synced 2025-12-06 04:04:53 +01:00
Some networking/matchmaking improvements.
This commit is contained in:
parent
0e72e995ee
commit
a0b66407bf
4 changed files with 20 additions and 7 deletions
|
|
@ -1141,6 +1141,16 @@ bool Networking::sendToIPPort(Common_Message *msg, uint32 ip, uint16 port, bool
|
|||
return true;
|
||||
}
|
||||
|
||||
uint32 Networking::getIP(CSteamID id)
|
||||
{
|
||||
Connection *conn = find_connection(id, this->appid);
|
||||
if (conn) {
|
||||
return ntohl(conn->tcp_ip_port.ip);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
bool Networking::sendTo(Common_Message *msg, bool reliable, Connection *conn)
|
||||
{
|
||||
if (!enabled) return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue