EQ2Interface.com
Search Downloads


Go Back   EQ2Interface > Developer Discussion > XML Modification Help & Info

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2  
Unread 06-07-2009, 02:15 PM
EQAditu's Avatar
EQAditu EQAditu is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Mar 2005
Server: Permafrost
Posts: 256
Default

Assuming there's an appropriate event trigger for ProgressBars(I don't know where there is an up-to-date list). Maybe use the OnTextChanged event for a health label instead.

Anyhow, I expect you'd have to disable EQ2's option to change the color at all so that it remains red. It's an actual game option, but probably a scriptable slash command as well. I'd hope that once it stays red that EQ2's hardcoding doesn't reset it to red on every change or you'll have difficulty.

Depending on which event you handle you'll either have a progress of 0.000 to 1.000 or a text of 0 to 100. You'll have to create a script to compare the current values to the steppings that you want. If you want smoother color transitions, you'll have to add more comparisons.

Sorta like:
Code removed
At the end, you'll end up with a color of red, yellow or green as ProgColor depending on the value of Prog, which you'll have to replace with the actual ProgressBar value or whatever. If you end up using the 1-100, you'll obviously have to use integers not decimals.

So as a short answer, it's not "easy" but not "hard" either. You'd have to calculate your own color transitions and hope EQ2 doesn't override you.

Last edited by EQAditu : 06-08-2009 at 12:17 AM. Reason: Bad code =P
Reply With Quote
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 09:18 PM.


Our Network
EQInterface | EQ2Interface | WoWInterface | LoTROInterface | ESOUI | MMOUI