Create3DTextLabel over head - 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: Create3DTextLabel over head (
/showthread.php?tid=314519)
Create3DTextLabel over head -
Ballu Miaa - 30.01.2012
Hello everyone,
Im bad at 3d Text Label's. When ever i add on in my server it never gets attached to the player i dont know damn why.
What i want is a 3dTextLabel which is Attached to the Player just above their name tag! It's visibility will be same as the NameTag and even the presentation way. A test code will do or if you can post suggestion's on how i can do this easily please let me know.
This has been a hazard to me nowadays lol.
Thanks
Ballu Miaa
Re: Create3DTextLabel over head -
Ballu Miaa - 30.01.2012
Can i make a attached 3D label with this
pawn Код:
new PlayerText3D:playertextid;
new Float:X, Float:Y, Float:Z;
GetPlayerPos( playerid, X, Y, Z );
playertextid = CreatePlayer3DTextLabel(playerid,"Hello\nI'm at your position",0x008080FF,X,Y,Z,40.0);
Or i should use this for it:
pawn Код:
new Text3D:label = Create3DTextLabel("Hello, I am new here!", 0x008080FF, 30.0, 40.0, 50.0, 40.0, 0);
Attach3DTextLabelToPlayer(label, playerid, 0.0, 0.0, 0.7);
Re: Create3DTextLabel over head - suhrab_mujeeb - 30.01.2012
pawn Код:
// Top of the script
Text3D: AFKPlayer[MAX_PLAYERS],
//Where ever needed
AFKPlayer[playerid] = Create3DTextLabel("Away from keyboard", 0xFFFFFFFF, 0.0, 0.0, 2.0, 40, 0, 0);
Attach3DTextLabelToPlayer(AFKPlayer[playerid], playerid, 0.0, 0.0, 0.4);
I use this for my AFK script and works great,
pawn Код:
// Top of the script under the includes
new PlayerText3D:playertextid;
// Where needed
new Float:X, Float:Y, Float:Z;
GetPlayerPos( playerid, X, Y, Z );
playertextid = CreatePlayer3DTextLabel(playerid,"Hello\nI'm at your position",0x008080FF,X,Y,Z,40.0);
SendClientMessage(playerid, 0xFFFFFFFF, "You are being followed!");
Though this would work better.