Intro
The idea of this plugin arises from the need to know the hp of the tank, without having to resort to other plugins that use HUDs or entities. So to help a friend on his server, i decided to create this plugin.
The color of the tank changes as he suffers some type of damage. The color varies gradually depending on your percentage of health, among the default colors:
(full color)
White-
Yellow-
Red. You can also choose the 3 colors for your state of hp percent
Cvars:
PHP Code:
// 0: Disable, 1: Enable plugin
// Default: "1"
tank_hpcolor_on "1"
// 0: Disable restore color, 1: Activated for each delay interval, 2: Reset the delay for each damage"
// Default: "0"
tank_hpcolor_reset "0"
// Set time in seconds to restore color
// Default: "0.5"
// Minimum: "0.100000"
tank_hpcolor_reset_delay "0.5"
// Set color full hp"
// Default: "255,255,255"
tank_hpcolor_full "255,255,255"
// Set color half hp"
// Default: "255,255,0"
tank_hpcolor_half "255,255,0"
// Set color critic hp"
// Default: "255,0,0"
tank_hpcolor_critic "255,0,0"
Code:
2019-04-24(v1.0.0)
* Initial release.
2019-05-3 (v1.0.5)
* Fixed check prop max health.
2019-05-27 (v1.1.0)
* Added new metod reset color in cvar: tank_hpcolor_reset
2019-05-27 (v1.2.0)
* Added new cvars to choose the 3 colors of the state of %hp.
tank_hpcolor_full, tank_hpcolor_half, tank_hpcolor_critic
Notes:
-if you use other plugins that change the color of the tank, possibly there is some conflict between them,
therefore it is recommended to activate the cvar: tank_hpcolor_reset "1"
credits
Skyy
Franc1sco
pd: sorry for me bad english :/