Cant make an player invisible in map
#1

On spawn the player is invisible when come close the player visible in map its static..here is the code

Код:
if(pClass{playerid} == CLASS_SNIPER)
    {
        SetPlayerColor(playerid, GetPlayerColor(playerid) & ~0xFF);
        foreach(new i : Player)
        {
            SetPlayerMarkerForPlayer( i, playerid, (GetPlayerColor(playerid) & 0xFFFFFF00));
        }
    }
Reply
#2

Quote:
Originally Posted by Jokers98s
Посмотреть сообщение
On spawn the player is invisible when come close the player visible in map its static..here is the code

Код:
if(pClass{playerid} == CLASS_SNIPER)
    {
        SetPlayerColor(playerid, GetPlayerColor(playerid) & ~0xFF);
        foreach(new i : Player)
        {
            SetPlayerMarkerForPlayer( i, playerid, (GetPlayerColor(playerid) & 0xFFFFFF00));
        }
    }
Код:
if(pClass{playerid} == CLASS_SNIPER)
    {
        SetPlayerMarkerVisibility(playerid, 0)
    }
    

SetPlayerMarkerVisibility(playerid, alpha = 0xFF)
{
	new oldcolor, newcolor;
	alpha = clamp(alpha, 0x00, 0xFF);
	oldcolor = GetPlayerColor(playerid);
	newcolor = (oldcolor & ~0xFF) | alpha;
	return SetPlayerColor(playerid, newcolor);
}
Reply
#3

Alternatively, you could use Vince's version.

http://forum.sa-mp.com/showpost.php?...postcount=4319
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)