3D Text Labels
#2

The code below gets some standard information about a player (i.e. their name, ID and score) then displays it above their head. Instead of showing a players health and armor, I show this. It looks 10x better (IMO) and it doesn't allow for meta-gaming. (seeing a players health)

pawn Код:
format(string, sizeof(string), "%s (%d)\n Score: %i", GetName(playerid), playerid, GetPlayerScore(playerid));
pNameTag[playerid] = Create3DTextLabel(string, COLOR_YELLOW, 30.0, 40.0, 50.0, 15.0, -1, 1);
Attach3DTextLabelToPlayer(pNameTag[playerid], playerid, 0.0, 0.0, 0.2);
Basically we're formating a string, making the label and of course, attaching the label to a players head. I used custom functions, so do not attempt using this code. It'll just be stupid!
Reply


Messages In This Thread
3D Text Labels - by Mr.Jvxmc - 29.09.2010, 19:50
Re: 3D Text Labels - by Scenario - 29.09.2010, 20:01
Re: 3D Text Labels - by Mr.Jvxmc - 29.09.2010, 20:17
Re: 3D Text Labels - by Scenario - 29.09.2010, 20:21
Re: 3D Text Labels - by Thebest96 - 29.09.2010, 20:25
Re: 3D Text Labels - by Mr.Jvxmc - 29.09.2010, 20:34
Re: 3D Text Labels - by Mr.Jvxmc - 29.09.2010, 22:49

Forum Jump:


Users browsing this thread: 1 Guest(s)