mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-04-28 06:55:23 +00:00
getIPaddress bug
This commit is contained in:
parent
2139ce4d79
commit
af27836d56
1 changed files with 2 additions and 2 deletions
|
|
@ -973,7 +973,7 @@ function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice,
|
||||||
%client.nameBase = %name;
|
%client.nameBase = %name;
|
||||||
}
|
}
|
||||||
// If we still don't have a GUID or name, time to boot the player (unless a local game).
|
// If we still don't have a GUID or name, time to boot the player (unless a local game).
|
||||||
if(getIPAddress(%client) !$= "Local" && (!%client.guid $= "" || %name $= ""))
|
if(%client.getIPAddress() !$= "Local" && (!%client.guid $= "" || %name $= ""))
|
||||||
{
|
{
|
||||||
//statEchoInfo("No name/GUID kick for CID (" @ %client @ ") with IP (" @ getIPAddress(%client) @ ")");
|
//statEchoInfo("No name/GUID kick for CID (" @ %client @ ") with IP (" @ getIPAddress(%client) @ ")");
|
||||||
KickByCID(%client, "You joined the server with a blank name and/or GUID. Try rejoining.",2);
|
KickByCID(%client, "You joined the server with a blank name and/or GUID. Try rejoining.",2);
|
||||||
|
|
@ -1039,7 +1039,7 @@ function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice,
|
||||||
|
|
||||||
// From Eolks
|
// From Eolks
|
||||||
// Minor improvement by Teratos
|
// Minor improvement by Teratos
|
||||||
function getIPAddress(%client)
|
function GameConnection::getIPAddress(%client)
|
||||||
{
|
{
|
||||||
%port = nextToken(nextToken(%client.getAddress(), "ip", ":"), "addr", ":");
|
%port = nextToken(nextToken(%client.getAddress(), "ip", ":"), "addr", ":");
|
||||||
if(%client.isAIControlled()) {
|
if(%client.isAIControlled()) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue