[Include] player_geolocation.inc
#1

Description
This include gets some information about player IP-address and keeps it during the game session.
Available macros for use:
PHP Code:
GetPlayerCountry(playerid) - get the name of the country in which the player is now located (string).
GetPlayerCity(playerid) - get the name of the city in which the player is now located (string).
GetPlayerLatitude(playerid) - get the latitude coordinates of the player (string).
GetPlayerLongtitude(playerid) - get the longtitude coordinates of the player (string).
GetPlayerProvider(playerid) - get the name of the provider of the player [ISP] (string).
GetPlayerProxyStatus(playerid) - does the player use proxy (string). 
Example:
PHP Code:
public OnPlayerConnect(playerid)
{
    
printf("Country: %s"GetPlayerCountry(playerid));
    
printf("City: %s"GetPlayerCity(playerid));
    
printf("Latitude: %s"GetPlayerLatitude(playerid));
    
printf("Longtitude: %s"GetPlayerLongtitude(playerid));
    
printf("Provider: %s"GetPlayerProvider(playerid));
    
printf("ProxyStatus: %s"GetPlayerProxyStatus(playerid));
    return 
1;

Screenshot:
Quote:

Author: Twixxx (aka whale)
Source code: https://pastebin.com/pDU65WzZ
Download: https://www.dropbox.com/s/uct85d9l2c...ation.inc?dl=0

P.S Im sry for my bad eng, guys
Reply


Messages In This Thread
player_geolocation.inc - by Twixxx - 22.08.2018, 20:55
Re: player_geolocation.inc - by PowerMwK - 22.08.2018, 23:06
Re: player_geolocation.inc - by Romz - 23.08.2018, 01:53
Re: player_geolocation.inc - by iLearner - 23.08.2018, 10:50
Re: player_geolocation.inc - by Twixxx - 23.08.2018, 11:47
Re: player_geolocation.inc - by iKarim - 23.08.2018, 15:52
Re: player_geolocation.inc - by SyS - 23.08.2018, 16:08
Re: player_geolocation.inc - by iKarim - 23.08.2018, 16:32
Re: player_geolocation.inc - by coool - 23.08.2018, 16:43
Re: player_geolocation.inc - by Jefff - 23.08.2018, 22:18

Forum Jump:


Users browsing this thread: 1 Guest(s)