OnPlayerClickPlayer

From SA-MP Wiki

Jump to: navigation, search


OnPlayerClickPlayer was added in SA-MP 0.3a This callback was added in SA-MP 0.3a and will not work in earlier versions!


Called when a player double-clicks on a player on the scoreboard.


Parameters:
(playerid, clickedplayerid, source)
playerid The ID of the player that clicked the name
clickedplayerid The ID of the player whose name was clicked
source The source of where the playerid clicked on the name of the other player


Image:32px-Ambox_warning_orange.png Note: There is currently only one 'source' (0 - CLICK_SOURCE_SCOREBOARD). The existence of this argument suggests that more sources may be supported in the future.


public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{	
	new message[32];
	format(message, sizeof(message), "You clicked on player %d", clickedplayerid);
	SendClientMessage(playerid, 0xFFFFFFFF, message);
	return 1;
}

Related Functions

The following functions might be useful, as they're related to this callback in one way or another.

Personal tools
In other languages