SA-MP Forums Archive
Whats wrong. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Whats wrong. (/showthread.php?tid=315534)



Whats wrong. - cs_waller - 03.02.2012

Hello guys.I tried to make /mask command but the command dont work,nothing happens.Here is my code

pawn Код:
if(strcmp(cmd, "/maskon", true) == 0)
    {
        for(new i = 0; i < PLAYERS; i++)
        {
        ShowPlayerNameTagForPlayer(i, playerid, 0);
        new sendername[MAX_PLAYER_NAME];
        new Float:x, Float:y, Float:z;
        GetPlayerPos(playerid,x,y,z);
        Mask[playerid] = Create3DTextLabel(sendername,COLOR_WHITE,x,y,z+2,20,0,0);
        Attach3DTextLabelToPlayer(Mask[playerid],playerid,0.0,0.0,0.0);
        }
        return 1;
    }



Re: Whats wrong. - milanosie - 03.02.2012

did u add the New3DTextLabel:Mask[MAX_PLAYERS];

at the top of ur script?


Re: Whats wrong. - cs_waller - 03.02.2012

Yes I added this code


Re: Whats wrong. - milanosie - 03.02.2012

change the second last 0 to 40

not the last but the second last
Mask[playerid] = Create3DTextLabel(sendername,COLOR_WHITE,x,y,z+2,2 0,40,0);
Attach3DTextLabelToPlayer(Mask[playerid],playerid,0.0,0.0,0.4);


Re: Whats wrong. - cs_waller - 03.02.2012

Doesn't work :X


Re: Whats wrong. - coole210 - 03.02.2012

pawn Код:
if(strcmp(cmd, "/maskon", true) == 0)
    {
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            ShowPlayerNameTagForPlayer(i, playerid, 0);
        }
        new sendername[MAX_PLAYER_NAME];
        GetPlayerName(playerid,sendername,sizeof(sendername));
        new Float:x, Float:y, Float:z;
        GetPlayerPos(playerid,x,y,z);
        Mask[playerid] = Create3DTextLabel(sendername,COLOR_WHITE,x,y,z+2,20,0,0);
        Attach3DTextLabelToPlayer(Mask[playerid],playerid,0.0,0.0,0.0);
        return 1;
    }



Re: Whats wrong. - cs_waller - 03.02.2012

Doesn't work :X