Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public OnPlayerClickPlayer(playerid, clickedplayerid, source)
- {
- new
- pName[ MAX_PLAYER_NAME ],
- sString[ 128 ];
- GetPlayerName(clickedplayerid, pName, MAX_PLAYER_NAME );
- if(GetPlayerInterior(clickedplayerid) != 0)
- {
- format( sString, sizeof( sString ), "%s (ID:%d) is hiding in an interior!",pName,clickedplayerid);
- SendClientMessage( playerid, COLOR_YELLOW, sString );
- return 1;
- }
- else
- {
- for(new j = 0; j <sizeof(zones); j++)
- {
- if(IsPlayerInZone(clickedplayerid, j))
- {
- GetPlayerName(clickedplayerid, pName, MAX_PLAYER_NAME );
- if ( !IsPlayerConnected( clickedplayerid ) )
- return SendError( playerid, "Player is not connected." );
- format( sString, sizeof( sString ), "%s (ID:%d) is located at \"%s\"",pName,clickedplayerid,zones[j][zone_name]);
- SendClientMessage( playerid, COLOR_YELLOW, sString );
- return 1;
- }
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement