3d icon showing vehicle health - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: 3d icon showing vehicle health (
/showthread.php?tid=276221)
3d icon showing vehicle health -
Mozz - 12.08.2011
i know how to create a 3d text label and attach it to a vehicle but what if i wanted something unique like an icon or something is that possible?
Re: 3d icon showing vehicle health -
Tigerkiller - 12.08.2011
no you cant inplement icons into labels
Re: 3d icon showing vehicle health -
Mozz - 13.08.2011
how about something like a battery bar instead of the standard health bar as i find that pretty boring
Re: 3d icon showing vehicle health -
dowster - 13.08.2011
Could be created with textdraws, the battery bar
Re: 3d icon showing vehicle health -
Mozz - 13.08.2011
does having more textdraws create lag? because i have like 50 also could you provide me with an example
the 50 are on/off not all static
Re: 3d icon showing vehicle health -
dowster - 13.08.2011
I don't believe the text draws will directly relate to lag, and you could do it by using characters such as the | for the outline and the _ for the levels. I am not too experienced with using the boxes but that may be a better way. If i were you I would go to the wiki, take a look at the functions available and start playing around with them.
Re: 3d icon showing vehicle health -
Mozz - 13.08.2011
ok thanks
Re: 3d icon showing vehicle health -
Whitetiger - 13.08.2011
pawn Код:
new hp = floatround(GetVehicleHealth(GetPlayerVehicleID(playerid)) / 1000) ;
new string[128];
format(string, sizeof(string), "{FF3300}||||||||||");
strins(string, "{000000}", hp);
Update3DTextLabelText(mylabel, -1, string);
this will make the red bar go down for each 100 hp of the vehicle ..
msg me on irc if you need more help. you know where i'm at