Help me making this
#5

Quote:
Originally Posted by LaGrande
Посмотреть сообщение
If it's related with gametext then it will be much easy.
Show us the code
Not gametexts it's textdraws - and it's not really hard to make that. You have to use timer for it and update the textdraws according to what you want to do.

For speed you can use the following function:-

pawn Код:
stock GetVehicleSpeed(vehicleid)
{
    new Float:V[3];
    GetVehicleVelocity(vehicleid, V[0], V[1], V[2]);
    return floatround(floatsqroot(V[0] * V[0] + V[1] * V[1] + V[2] * V[2]) * 180.00);
}
Note: this is in km/h so ye and it is not really tested by me.

For fuel you can just checkout the following tutorial made by gamer:-

https://sampforum.blast.hk/showthread.php?tid=169284

EDIT: I just realized you want to change the color and you have already made this code. Anyway to change the colors check in the timer if you are using something like GetVehicleSpeed you could use it something like:

pawn Код:
if( GetVehicleSpeed( vehicleid ) < 100 ) // if speed is less then 100
{
     TextDrawSetString( YOURTD, "~r~%d" ); // I am sorry but I am on my internet tablet you have to format it before setting string into the textdraw and you should know that ~r~ is red colour ~b~ blue, ~g~ green, ~w~ white and etc..
}
Regards,
FalconX
Reply


Messages In This Thread
deleted - by Joe Vagos - 28.06.2012, 17:28
Re: Help me making this - by Joe Vagos - 30.06.2012, 11:17
Re: Help me making this - by Joe Vagos - 01.07.2012, 12:51
Re: Help me making this - by LaGrande - 01.07.2012, 13:07
Re: Help me making this - by FalconX - 01.07.2012, 13:45
deleted - by Joe Vagos - 01.07.2012, 14:26
deleted - by Joe Vagos - 01.07.2012, 14:33
Re: Help me making this - by LaGrande - 01.07.2012, 14:41
deleted - by Joe Vagos - 01.07.2012, 15:04
Re: Help me making this - by Joe Vagos - 02.07.2012, 12:21

Forum Jump:


Users browsing this thread: 1 Guest(s)