PDA

View Full Version : 3D text label problem?


Tanush123
30/12/2011, 03:12 AM
BarInfo[barid][bartext] = Create3DTextLabel(str,Niceyellow,X,Y,Z,100.0,-1,1);


Well when i create a bar i just see ID: 1 beside me after half than a second (0.5 second) the 3DLabel disappears

Guest9328472398472
30/12/2011, 04:27 AM
Re-Read this (http://wiki.sa-mp.com/wiki/Create3DTextLabel) tutorial and see if it solves your problem.

Tanush123
30/12/2011, 04:45 AM
I did and that didn't fix it

Guest9328472398472
30/12/2011, 04:48 AM
I'm not experienced with TextDraws(3D Text). I wish I could help, but right now it seems that in my way..it looks kinda complicated as I'm not experienced with 3D Text.

Tanush123
30/12/2011, 10:16 PM
bump

Fj0rtizFredde
30/12/2011, 10:22 PM
Can you show a bit more of your code? Do you attach it somewhere? Use it in a timer? Or anything like that? :)

Tanush123
30/12/2011, 10:42 PM
CMD:createbar(playerid,params[])
{
if(PlayerData[playerid][AdminLevel] < 4) return 0;
if(sscanf(params,"i",barid)) return SendClientMessage(playerid,grey,"USAGE: /createbar [Bar ID]");
if(barid > MAX_BARS) return SendClientMessage(playerid,red,"Available BARS 1-9");
CheckMySQL();
format(str,sizeof(str),"SELECT * FROM Bars WHERE ID = '%d'",barid);
mysql_query(str);
mysql_store_result();
if(mysql_num_rows() == 0)
{
mysql_free_result();
GetPlayerPos(playerid,X,Y,Z);
format(str,sizeof(str),"INSERT INTO Bars (ID,PosX,PosY,PosZ) VALUES ('%d','%f','%f','%f')",barid,X,Y,Z);
mysql_query(str);
format(str,sizeof(str),"You have created Bar ID: %d!",barid);
SendClientMessage(playerid,orange,str);
BarInfo[barid][barcheck] = CreateDynamicCP(X,Y,Z,1,-1,-1,-1,50);
format(str,sizeof(str),"ID: {FFFFFF}%d",barid);
BarInfo[barid][bartext] = Create3DTextLabel(str,Niceyellow,X,Y,Z,100.0,-1,1);
}
else
{
SendClientMessage(playerid,red,"ERROR: This Bar ID is already used.");
}
return 1;
}

Tanush123
03/01/2012, 09:57 PM
BUMP

Tanush123
04/01/2012, 06:49 AM
bump

SupremeCommander
04/01/2012, 07:39 AM
oops.. Delete this. I thougt it was CreateDynamic3DTextLabel

Joe_
04/01/2012, 10:45 AM
If it's dissapearing, Destroy3DTextLabel is being used somewhere, use CTRL+F to find it, in your gamemode and any filterscripts/includes you're using. There might be an ID mixup.

Also, try changing the TestLOS parameter from 1 to 0, see if that changes anything.

Tanush123
04/01/2012, 05:20 PM
i tryed testlos on 0 and 1 but it wont work, i just only see for half a second and it disappears and i have destroy3DTextLabel for ongamemodeexit but that is not the problem