Do something like: ((HIT/MAX_HIT)*100)= i if i >= 66 color green else if i >= 33 color yellow else if i >= 0 color red I don't know if this will help any, or if I am on the right track, but here is my 2 cents. <--------------------------------------------------------------------------- -------------------------------> | Shawn A. Daniel | | Damion Thaed | |Co-Implementor of CyberMUD, Modesto's first WWIV BBS MUD, dial up | <--------------------------------------------------------------------------- -------------------------------> ---------- > From: Bruce, Ray, Phil <bherbert@ns.technonet.com> > To: circle@cspo.queensu.ca > Subject: [Circle] Health Percentage... > Date: Saturday, November 16, 1996 18:43 > > I'm editing my PROMPT and I was thinking of making the Health, Mana, and > Movement points change color from GREEN to YELLOW and RED according to > their percentage from their Maximum. Could someone direct me on how to > calculate that? I can do the color and formatting myself... I'm just not > sure on how to do the math. > I would want to do it at 33.3% for each so: > out of 100 HP > 100 - 66 GREEN > 66 - 33 YELLOW > 33 - 0 RED > > Get it? > > *Frostiana* BETA > http://www.durand.net/Frostiana > telnet://206.31.114.50:5000 > > +-----------------------------------------------------------+ > | Ensure that you have read the CircleMUD Mailing List FAQ: | > | http://cspo.queensu.ca/~fletcher/Circle/list_faq.html | > +-----------------------------------------------------------+ +-----------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://cspo.queensu.ca/~fletcher/Circle/list_faq.html | +-----------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/18/00 PST