SA-MP Forums Archive
Dynamic 3D Text Label - View problem. - 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: Dynamic 3D Text Label - View problem. (/showthread.php?tid=649264)



Dynamic 3D Text Label - View problem. - Milak - 05.02.2018

Hello! I'm Milak and this is my first and new thread on this forum. I want to ask you for help.
I have a problem with 3D Text Label, I use it to make custom nicknames and it works but draw distance is little weird, When I'm going away from 3D Text Label then the nickname is bigger and bigger - I don't want it, it's hard to me to get it in words, please look for those screenshots:
When I'm near to him:
https://i.imgur.com/NGYnWRi.png
When I'm far to him:
https://i.imgur.com/iCNPBJS.png
It looks so weird
I forgot: I'm on the lastest SAMP 0.3.8 version using Incognito Plugin.


Re: Dynamic 3D Text Label - View problem. - dani18 - 05.02.2018

code?


Re: Dynamic 3D Text Label - View problem. - Milak - 05.02.2018

new msg[128];
format(msg, sizeof(msg), " %d, %s", playerid, CharacterCache[CharacterUID(playerid)][cICName]);
CharacterCache[CharacterUID(playerid)][cNameLabel] = CreateDynamic3DTextLabel(msg, COLOR_WHITE, 0.0, 0.0, 0.15, 25.0, playerid, INVALID_VEHICLE_ID, 1, -1, -1, -1);
format(msg, sizeof(msg), " ");
CharacterCache[CharacterUID(playerid)][cUnderLabel] = CreateDynamic3DTextLabel(msg, COLOR_WHITE, 0.0, 0.0, 0.10, 25.0, playerid, INVALID_VEHICLE_ID, 1, -1, -
1, -1);

// this is how I create and attach Dynamic 3D Text labels to player who joined to server and logged to game


Re: Dynamic 3D Text Label - View problem. - Weponz - 06.02.2018

3D Text Labels do this, the only thing you can do is show them only when the player is very close.


Re: Dynamic 3D Text Label - View problem. - Sew_Sumi - 06.02.2018

The only way you could even hope to have this 'work' is to have the 3dtexts, be per-player. Otherwise for some it will look fine, and others it won't look right.

However, disable player name tags, and use that 3dtext to do the entire thing (Name/ID/Everything you want) using newline to split the lines.


Re: Dynamic 3D Text Label - View problem. - bigtigerbeee - 06.02.2018

Use only one label

Код:
new msg[128];
new line2[128];
if(CharacterCache[CharacterUID(playerid)][cAFKTime]) {
 format(line2, sizeof(line2), "\nAFK Time %s", CharacterCache[CharacterUID(playerid)][cAFKTime]);
}
format(line2, sizeof(line2), "%s\nLevel %d", line2, CharacterCache[CharacterUID(playerid)][cLevel]);

format(msg, sizeof(msg), " %d, %s%s", playerid, CharacterCache[CharacterUID(playerid)][cICName], line2);
CharacterCache[CharacterUID(playerid)][cNameLabel] = CreateDynamic3DTextLabel(msg, COLOR_WHITE, 0.0, 0.0, 0.15, 25.0, playerid, INVALID_VEHICLE_ID, 1, -1, -1, -1);



Re: Dynamic 3D Text Label - View problem. - Milak - 06.02.2018

Quote:
Originally Posted by Weponz
Посмотреть сообщение
3D Text Labels do this, the only thing you can do is show them only when the player is very close.
I was thinking about it.


Re: Dynamic 3D Text Label - View problem. - Sew_Sumi - 06.02.2018

bigtigerbeee's code would work if you did as I said and took the nametags off altogether.


Re: Dynamic 3D Text Label - View problem. - Milak - 06.02.2018

Quote:
Originally Posted by Weponz
Посмотреть сообщение
3D Text Labels do this, the only thing you can do is show them only when the player is very close.
I will do that! Thanks!