This repository has been archived by the owner on Feb 19, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 38
GetPlayerResolution
GtakillerIV edited this page Nov 16, 2014
·
3 revisions
Retrieves the player's game resolution
playerid
The player's id.
X
A variable that'll hold the amount of horizontal pixels(width).
Y
A variable that'll hold the amount of vertical pixels(height).
1 on all occasions
CMD:getresolution(playerid, params[])
{
//If the player has the SA-MP+ plugin installed
if(IsUsingSAMPP(playerid))
{
new string[128];
new X, Y;
GetPlayerResolution(playerid, X, Y);
format(string, sizeof(string), "Your resolution is: %d x %d", X, Y);
SendClientMessage(playerid, -1, string);
}
else
{
SendClientMessage(playerid, -1, "You need the SA-MP+ plugin");
}
return 1;
}
See also
Callbacks