-2

I know with Javascript and the Meter Command you can create "Heath bar" kind of things but im trying to create a negative bar sort of like how radiation is handled in fallout 4 heath and negative heath

Right now the only way i can see that working is using CSS to layer one meter atop another but I figured id ask you guys on a better or even a good CSS implementation sinc the normal heath wont always be full, and my code will already deduct the negative heath if the normal heath hits its range (though i imagine if css overlays are the only way overlay really inst an issue)

Lexx Alolia
  • 35
  • 1
  • 7

1 Answers1

0

so I found an answer https://www.w3schools.com/bootstrap/bootstrap_progressbars.asp

can't right justify the red meter but works well enough.

http://www.maskedriders.info/Mee6RP/index.php

here's an example with the important bits set as variables
        echo "";
             echo "";
                  echo number_format($CURRHPCalc, 0, '.', ',')." HP (".$HPPercent."%)";
             echo "";
             if ($Toxic_Percent > 0){
                 echo "";
                      echo number_format($Toxic_Damage, 0, '.', ',')." RADS (".$Toxic_Percent."%)";
                 echo "";
             };//if
        echo "";
Lexx Alolia
  • 35
  • 1
  • 7
  • Whilst this may theoretically answer the question, [it would be preferable](//meta.stackoverflow.com/q/8259) to include the essential parts of the answer here, and provide the link for reference. – 4castle Aug 08 '17 at 01:53