17.01.2018, 14:23
I've made some textdraws, Now I can't really find a proper tutorial so I'll just ask it here, I have made an HP, kills,deaths,ping,fps textdraws
So I'll start with the HP for now maybe I'll learn something and make the others by my self.
So the first textdraw is a transparent box, All the textdraws that I've made are on that transparent box.
Here is my transparent box
Now as I said directly above, all the textdraws I've made are on it, For example my HP textdraw.
.
So basically what I want to do is make HP textdraw with the current player's HP
- example , HP 'health amount'.
So it updates every time a player gets hit and obviously resets after he dies...
Can anyone provide me a way to do so?
Thanks in advance!
So I'll start with the HP for now maybe I'll learn something and make the others by my self.
So the first textdraw is a transparent box, All the textdraws that I've made are on that transparent box.
Here is my transparent box
Код:
// In OnGameModeInit prefferably, we procced to create our textdraws: Textdraw0 = TextDrawCreate(-10.000000, 431.000000, "_"); TextDrawBackgroundColor(Textdraw0, 255); TextDrawFont(Textdraw0, 1); TextDrawLetterSize(Textdraw0, 0.500000, 6.800000); TextDrawColor(Textdraw0, -1); TextDrawSetOutline(Textdraw0, 1); TextDrawSetProportional(Textdraw0, 0); TextDrawUseBox(Textdraw0, 1); TextDrawBoxColor(Textdraw0, 120); TextDrawTextSize(Textdraw0, 796.000000, 28.000000);
Код:
Textdraw1 = TextDrawCreate(8.000000, 430.000000, "HP"); TextDrawBackgroundColor(Textdraw1, 16711935); TextDrawFont(Textdraw1, 3); TextDrawLetterSize(Textdraw1, 0.700000, 1.800000); TextDrawColor(Textdraw1, 712256255); TextDrawSetOutline(Textdraw1, 1); TextDrawSetProportional(Textdraw1, 1);
So basically what I want to do is make HP textdraw with the current player's HP
- example , HP 'health amount'.
So it updates every time a player gets hit and obviously resets after he dies...
Can anyone provide me a way to do so?
Thanks in advance!