06.11.2012, 18:14
Hello,
could anyone tell me how could I make such thing:
I've got a textdraw box which size is 601 when the vehicle health is 1000.
The box size should keep getting smaller as the vehicle health is going down.
The minimum size that the box can go down is from 601 to 541.
Now I've done this,
I subtracted max from min ( 601 - 541 ) and received 60.
According to me, 250/60=0.24 < 250 is the vehicle health as I consider it 0. The 0.24 should be the multipler that the box size should stick to and go down, in other words:
601(Box size) - ((1000maximum vehicle health - Current vehicle health) * 0.24 )
This results 601-60 only when vehicle health is 250, it reduces the box size more than 60 whenever it's above 250.. Can anyone tell me whats' wrong?
could anyone tell me how could I make such thing:
I've got a textdraw box which size is 601 when the vehicle health is 1000.
The box size should keep getting smaller as the vehicle health is going down.
The minimum size that the box can go down is from 601 to 541.
Now I've done this,
I subtracted max from min ( 601 - 541 ) and received 60.
According to me, 250/60=0.24 < 250 is the vehicle health as I consider it 0. The 0.24 should be the multipler that the box size should stick to and go down, in other words:
601(Box size) - ((1000maximum vehicle health - Current vehicle health) * 0.24 )
This results 601-60 only when vehicle health is 250, it reduces the box size more than 60 whenever it's above 250.. Can anyone tell me whats' wrong?