SA-MP Forums Archive
How to make a [BOT] name tag? - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: How to make a [BOT] name tag? (/showthread.php?tid=225168)



How to make a [BOT] name tag? - grand.Theft.Otto - 13.02.2011

Just like how player have a name tag over there head, how can I make one for a bot? I don't really like using variables with Attach3DTextLabel and Create3DTextLabel etc...

Any other ways how?

Or how can I make the 3DTextLabel over the bots head to be bolder and easier to see?


Re: How to make a [BOT] name tag? - HyperZ - 13.02.2011

Under inc's:
pawn Код:
new Text3D:MyNpc[MAX_PLAYERS];
OnPlayerSpawn:
pawn Код:
new playername[64];
GetPlayerName(playerid,playername,64);
if(!strcmp(playername,"MyNpc Name",true))//change MyNpc name to your npc name :)
{
    MyNpc[playerid] = Create3DTextLabel("bla bla bla bla bla",0x33FF33AA, 30.0, 40.0, 50.0, 40.0, 0);
    Attach3DTextLabelToPlayer(MyNpc[playerid],playerid,0.0, 0.0, 0.7);
}



Re: How to make a [BOT] name tag? - AlternativeDC - 23.05.2011

NicE greate work!
for the post


Re: How to make a [BOT] name tag? - Vince - 23.05.2011

Quote:
Originally Posted by Clive
Посмотреть сообщение
Under inc's:
pawn Код:
new Text3D:MyNpc[MAX_PLAYERS];
OnPlayerSpawn:
pawn Код:
new playername[64];
GetPlayerName(playerid,playername,64);
if(!strcmp(playername,"MyNpc Name",true))//change MyNpc name to your npc name :)
{
    MyNpc[playerid] = Create3DTextLabel("bla bla bla bla bla",0x33FF33AA, 30.0, 40.0, 50.0, 40.0, 0);
    Attach3DTextLabelToPlayer(MyNpc[playerid],playerid,0.0, 0.0, 0.7);
}
Waste of 499 values. Just saying.

This forum requires that you wait .. <= This is f*cking annoying. 62 seconds, 36 seconds, 9 seconds, ...


Re: How to make a [BOT] name tag? - CrazyBlob - 23.05.2011

use 3dtextlabels and attach3dtextlabeltoplayer


Respuesta: How to make a [BOT] name tag? - admantis - 24.05.2011

I made this function:
pawn Код:
stock SetNPCTag() // by: Admantis
{
    new sz_Name[24], sz_NewName[31];
    sz_NewName = "[BOT]";
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if (!IsPlayerNPC(i))
            continue;
           
        GetPlayerName(i, sz_Name, 24);
        strins(sz_NewName, sz_Name, 25);
        SetPlayerName(i, sz_NewName);
    }
   
    return sz_NewName; // This function returns the name with [BOT] tag
}



Re: How to make a [BOT] name tag? - [MG]Dimi - 24.05.2011

LOL grand you could ask me... xD