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



3D Text - iulicxd - 30.07.2015

new string[256];
format(string,sizeof(string),"Owner:%s",CarInfo[c][Owner]);
CarInfo[c][Text] = Create3DTextLabel(string, 0xFF0000AA, 0.00,0.00,0.00, 100.0, 0, 1 );
Attach3DTextLabelToVehicle(CarInfo[c][Text], c, 0.0, 0.0, 2.0 );
3d text not show ...!


Re: 3D Text - Jacket - 30.07.2015

Remove [c] from CarInfo[c][Text]. Does it work?


Re: 3D Text - jamesmith12 - 30.07.2015

TRY ?



PHP код:
new string[256];
format(string,sizeof(string), "Owner:%s" ,CarInfo[Owner]);
CarInfo[Text] = Create3DTextLabel(string0xFF0000AA0.00,0.00,0.00100.00);
Attach3DTextLabelToVehicle(CarInfo[Text]," VEHICLE ID HERE ?" 0.00.02.0 ); 



Re: 3D Text - iulicxd - 30.07.2015

Quote:
Originally Posted by Jacket
Посмотреть сообщение
Remove [c] from CarInfo[c][Text]. Does it work?
if i remove [c]
Код:
ambiguous constant; tag override is required (symbol "Owner")
D:\SAMP Servers and Tools\Freedom (Engine Ultra)\Freedom (Engine Ultra)\gamemodes\gm.pwn(2748) : error 091: ambiguous constant; tag override is required (symbol "Text")
D:\SAMP Servers and Tools\Freedom (Engine Ultra)\Freedom (Engine Ultra)\gamemodes\gm.pwn(2748) : error 033: array must be indexed (variable "CarInfo")
D:\SAMP Servers and Tools\Freedom (Engine Ultra)\Freedom (Engine Ultra)\gamemodes\gm.pwn(2749) : error 091: ambiguous constant; tag override is required (symbol "Text")



Re: 3D Text - Stanford - 30.07.2015

Your array might start with the value of zero and vehicles start with 1 (index) - so instead of
pawn Код:
Attach3DTextLabelToVehicle(CarInfo[c][Text], c, 0.0, 0.0, 2.0 );
Try:
pawn Код:
Attach3DTextLabelToVehicle(CarInfo[c][Text], c+1, 0.0, 0.0, 2.0 );

I hope I helped any feedback is appreciated!



Re: 3D Text - iulicxd - 30.07.2015

Quote:
Originally Posted by Stanford
Посмотреть сообщение
Your array might start with the value of zero and vehicles start with 1 (index) - so instead of
pawn Код:
Attach3DTextLabelToVehicle(CarInfo[c][Text], c, 0.0, 0.0, 2.0 );
Try:
pawn Код:
Attach3DTextLabelToVehicle(CarInfo[c][Text], c+1, 0.0, 0.0, 2.0 );

I hope I helped any feedback is appreciated!
not working,
Код:
CarInfo[c][CarID] = CreateVehicle(CarInfo[c][Model], CarInfo[c][Vposx], CarInfo[c][Vposy], CarInfo[c][Vposz], CarInfo[c][Vposa], CarInfo[c][Color1], CarInfo[c][Color2], -1);
I need to attach 3d text label for vehicles (CarInfo[c][CarID] )
i try:
Код:
Attach3DTextLabelToVehicle(CarInfo[c][Text], CarInfo[c][CarID], 0.0, 0.0, 2.0 );
But not working

I fixed IT!Thanks guys for assistance!