Lookup.inc problem - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Lookup.inc problem (
/showthread.php?tid=522073)
Lookup.inc problem -
iThePunisher - 25.06.2014
im using lookup.inc i made the script when player join to show the country name but it doesnt show
Example: it shows this Info: punisher has connected [Country Name]: ? [Country Region]: ?
isnt showing the country name :/
pawn Код:
public OnLookupComplete(playerid)
{
 new string[300];
 new name[24];
 GetPlayerName(playerid, name, sizeof(name));
 format(string, sizeof(string), "{FF00EA}Info: %s has connected {FFAF00}[Country Name]: {FF8000}%s {FFAF00}[Country Region]: {A90202}%s", name,GetPlayerCountryName(playerid),GetPlayerCountryRegion(playerid));
 SendClientMessageToAll(-1,string);
 if(IsProxyUser(playerid))
 {
  GetPlayerName(playerid, name, sizeof(name));
  format(string, sizeof(string), "Kick: {FFFFFF}%s{FF00EA} has Been Kicked From The Server Reason Using Proxy.", name);
  SendClientMessageToAll(red,string);
  Kick(playerid);
 }
 return 1;
}
P.s = is there any other method to kick nerds who change ip using proxy?
Re: Lookup.inc problem -
kepa333 - 25.06.2014
This is exactly how i made it, it dosent work for me aswell, but,
Код:
DisplayLookupData(playerid, targetid)
It works well in this function.
Re: Lookup.inc problem -
iThePunisher - 25.06.2014
and where i can add this function?>
Re: Lookup.inc problem -
kepa333 - 25.06.2014
It's basicly a function wich opens dialog with all targetid data like :Country,Region, Host,... But i dont suggest you to use it at on player connect. Seems like include is broken and it need update or we dont know how to use it.
Re: Lookup.inc problem -
Don_Cage - 25.06.2014
I made it like this in my script and it works good for me.
pawn Код:
public OnLookupComplete(playerid)
{
  if(IsPlayerConnected(playerid))
  {
    new lookup[128];
    new name[24];
    GetPlayerName(playerid,name, sizeof(name));
    if(IsProxyUser(playerid))
    {
      SetTimerEx("KickPlayerOut",1000,0,"i",playerid);
    }
    else
    {
      format(lookup, sizeof(lookup),"[INFO] %s (%d) Has joined ************ Roleplay! ( Country: %s )",name, playerid, GetPlayerCountryName(playerid));
    }
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
      if(IsPlayerConnected(i) && playerid != i)
      {
        if(PlayerInfo[i][pAdmin] >= 1)
        {
          SCM(i,COLOR_RLRPGBLUE,lookup);
        }
      }
    }
  }
  return 1;
}
Re: Lookup.inc problem -
iThePunisher - 26.06.2014
still the same problem