3dTextLabel above head -
SiNuS - 17.05.2015
Hi, i did this:
Код:
if(PlayerInfo[playerid][pAdmin] > 1)
{
TitleLabel[playerid] = Create3DTextLabel("< Admin >", COLOR_WHITE, 30.0, 40.0, 50.0, 40.0, 0);
Attach3DTextLabelToPlayer(TitleLabel[playerid], playerid, 0.0, 0.0, 0.5);
}
But if are 2 players connected, its show "<admin>" just for one ..
So, my code works just for 1 player. What is wrong?
Re: 3dTextLabel above head -
Konstantinos - 17.05.2015
https://sampwiki.blast.hk/wiki/Attach3DTextLabelToPlayer
Quote:
This feature is known to be buggy please consider using the streamer plugin to attach 3D text labels
|
Re: 3dTextLabel above head -
SiNuS - 17.05.2015
I use last version streamer, same problem..
Re: 3dTextLabel above head -
n0minal - 17.05.2015
wiki.sa-mp.com/wiki/SetPlayerChatBubble is a nice way to do it
Re: 3dTextLabel above head -
SiNuS - 17.05.2015
I want to do this with 3dtext, i saw this on many servers, i use chatbubble for another thing.
Re: 3dTextLabel above head -
Trucido - 17.05.2015
im new to scripting but ill try to help try somehting like this
Код:
new Text3D:label[MAX_PLAYERS];
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
label[playerid] = CreateDynamic3DTextLabel("Admin", COLOR, x, y, z+1, INVALID_PLAYER_ID, 1);
Re: 3dTextLabel above head -
Konstantinos - 17.05.2015
@Trucido: You'd have to set
attachedplayer parameter to playerid instead of INVALID_PLAYER_ID. Also the parameters you used above are the old ones, update streamer plugin.
pawn Код:
native Text3D:CreateDynamic3DTextLabel(const text[], color, Float:x, Float:y, Float:z, Float:drawdistance, attachedplayer = INVALID_PLAYER_ID, attachedvehicle = INVALID_VEHICLE_ID, testlos = 0, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
pawn Код:
// I hope you didn't try to create the 3D label on connect
new Float: x, Float: y, Float: z;
GetPlayerPos(playerid, x, y, z);
TitleLabel[playerid] = CreateDynamic3DTextLabel("< Admin >", -1, x, y, z, 40.0, playerid);
Re: 3dTextLabel above head -
Trucido - 17.05.2015
Quote:
Originally Posted by Konstantinos
@Trucido: You'd have to set attachedplayer parameter to playerid instead of INVALID_PLAYER_ID. Also the parameters you used above are the old ones, update streamer plugin.
pawn Код:
native Text3D:CreateDynamic3DTextLabel(const text[], color, Float:x, Float:y, Float:z, Float:drawdistance, attachedplayer = INVALID_PLAYER_ID, attachedvehicle = INVALID_VEHICLE_ID, testlos = 0, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
pawn Код:
// I hope you didn't try to create the 3D label on connect new Float: x, Float: y, Float: z; GetPlayerPos(playerid, x, y, z); TitleLabel[playerid] = CreateDynamic3DTextLabel("< Admin >", -1, x, y, z, 40.0, playerid);
|
no i didnt but anyways if i even tried to use the new streamer my pawn just crashes so ye