Disable nametag
#1

I'm creating a mask script, when a player is wearing a mask, their nametag isn't there. How can I do this?
I know: https://sampwiki.blast.hk/wiki/ShowPlayerNameTagForPlayer but that disables everyone else's client side.
Reply
#2

This is all you need.
pawn Код:
for(new i; i < MAX_PLAYERS; i++)
{
    if(!IsPlayerConnected(playerid))
    {
        continue;
    }

    ShowPlayerNameTagForPlayer(i, playerid, false);
    /*
        i           all players online
        playerid    a specific player that uses /mask
        false       hide name tag
    */

}
EDIT: https://sampwiki.blast.hk/wiki/ShowPlayerNameTagForPlayer - OnPlayerStreamIn is important public.
Reply
#3

Quote:
Originally Posted by Toreno
Посмотреть сообщение
This is all you need.
pawn Код:
for(new i; i < MAX_PLAYERS; i++)
{
    if(!IsPlayerConnected(playerid))
    {
        continue;
    }

    ShowPlayerNameTagForPlayer(i, playerid, false);
    /*
        i           all players online
        playerid    a specific player that uses /mask
        false       hide name tag
    */

}
EDIT: https://sampwiki.blast.hk/wiki/ShowPlayerNameTagForPlayer - OnPlayerStreamIn is important public.
Doesn't that disable everybodies nametags? I want it so that the individual player's nametag is switched off for everyone else.
Reply
#4

If you switch between "i" and "playerid", it will hide everyone's for this playerid. Use what I posted, it should work properly.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)