Text Traw
#1

What is wrong with this, it should show a text draw above the cars showing their plate which is 'cPlate'
It compiles fine but the Text draw dont show.

for(new h = 0; h < sizeof(CarInfo); h++)
{
if(CarInfo[ownvehkey][cPlate] == 0)
{
Delete3DTextLabel(CarLabel);
format(PropertyString,sizeof(PropertyString),"[______]");
CarLabel = Create3DTextLabel(PropertyString ,0x00FF00FF,CarInfo[ownvehkey][cLocationx]+2, CarInfo[ownvehkey][cLocationy], CarInfo[ownvehkey][cLocationz]+2,10, 0);
}
if(CarInfo[ownvehkey][cPlate] == 1)
{
Delete3DTextLabel(CarLabel);
format(PropertyString,sizeof(PropertyString),"[%d]",CarInfo[ownvehkey][cPlate]);
CarLabel = Create3DTextLabel(PropertyString ,0x00FFFFFF,CarInfo[ownvehkey][cLocationx], CarInfo[ownvehkey][cLocationy], CarInfo[ownvehkey][cLocationz]+2,10, 0);
}
}
Reply
#2

I don't see you attaching the 3D Text label to the vehicle.

Attach3DTextLabelToVehicle should help.
Reply
#3

for(new h = 0; h < sizeof(CarInfo); h++)
{
if(CarInfo[ownvehkey][cPlate] == 0)
{
Delete3DTextLabel(CarLabel);
format(PropertyString,sizeof(PropertyString),"[______]");
CarLabel = Create3DTextLabel(PropertyString ,0x00FF00FF,CarInfo[ownvehkey][cLocationx]+2, CarInfo[ownvehkey][cLocationy], CarInfo[ownvehkey][cLocationz]+2,10.0,0,0);
}
if(CarInfo[ownvehkey][cPlate] == 1)
{
Delete3DTextLabel(CarLabel);
format(PropertyString,sizeof(PropertyString),"[%d]",CarInfo[ownvehkey][cPlate]);
CarLabel = Create3DTextLabel(PropertyString ,0x00FFFFFF,CarInfo[ownvehkey][cLocationx], CarInfo[ownvehkey][cLocationy], CarInfo[ownvehkey][cLocationz]+2,10.0,0,0);
}
}
Reply
#4

That wiki dont help me that much, i need a text draw for cars 184 to 800,
can someone help me make it
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)