Quantcast
Download
(13 Kb)
Download
Updated: 12-15-08 03:13 PM
Pictures
File Info
Updated:12-15-08 03:13 PM
Created:12-07-08 01:36 AM
Downloads:2,166
Favorites:13
MD5:

Broker MiniHUD

Version: Beta 2 r2
by: Stolberg [More]

Broker_MiniHUD is a highly flexible, extensible, text-only HUD that uses LDB for output.

Broker_MiniHUD was inspired by OnScreenHealth (authored by the incomparable Phanx), and grew out of my desire to have something that did about the same thing, but used fewer system resources. I'd been wanting to learn Lua and write an addon for a long time, and this seemed like the perfect way to get my feet wet.

Please note: You will need an LDB display addon to make Broker_MiniHUD work at all. Due to its beta state, I've only had time to test it with Fortress, with which it works well. For now, I recommend using Fortress with Broker_MiniHUD, but I welcome reports on how it works with the others, like Wraith, ButtonBin, etc. I'll make every reasonable effort to ensure compatibility with all LDB displays.

You probably would like to free-position your Broker_MiniHUD objects so that they act like a real HUD, so it is not advisable to use strict bar-only LDB displays like Titan or (FuBar w/ Broker2FuBar).

Out of the box, Broker_MiniHUD implements 7 data objects:

  • Player Health
  • Player Mana
  • Pet Health
  • Pet Mana
  • Target Health
  • Target Mana
  • Target Combo Points

After you install Broker_MiniHUD for the first time, you will need to customize it to your liking by dragging the frames to where you want, sizing them properly, and setting your desired font.

Making your own Data Objects
Broker_MiniHUD's displays are generated by a simple tag library (is that an oxymoron?) of my own devising. Each data object has an associated "tag" property which is parsed into a value, color, and format. A tag takes the following form:

VALUE:COLORER:FORMATTER

...where COLORER and FORMATTER are optional. Further, each component takes this form:

Function[([arg1=value1] [, arg2=value1] [...])]

An example of what a tag looks like: "UnitHealth(unit=player):HealthColor:RawValue" This tag calls the UnitHealth value function with "player" as the "unit" argument, passes that value to the HealthColor colorer function, and then passes the color and value to the RawValue formatter, which simply displays it as-is.

This might sound complicated, but if you look through the definitions of the objects that ship with Broker_MiniHUD, you will get the hang of it pretty quickly.

Current built-in tag functions

Notes: "unitid" below should be replaced by the Unit ID (player, target, pet, party1, etc.) you want a value for.

Values

Name(unit=unitid)

Health(unit=unitid)

Mana(unit=unitid)

ComboPoints(unit=unitid)

PlayerXP

InCombat(unit=unitid)

SimpleText(text=value) - Displays a static message

Threat(unit1=unitid,unit2=unitid) - Gives scaled threat for unit1 on unit2, i.e. "Threat(unit1=player,unit2=target)" gives the player's threat on the target mob.

Colorers

ReactionColor - Colors according to reaction. Requires the value function to have contained a "unit" argument.

ManaColor - Requires the value function to have contained a "unit" argument.

HealthColor - Requires the value function to have contained a "unit" argument.

ComboPointColor

NamedColor(color=value) - where value is one of: Blue, Red, Orange, Yellow, Purple. Yes, there will be more colors later.

RGBColor(r=value,g=value,b=value) - where r, g, b are a value between 0 and 1.

Formatters

CurMax - Displays a current/maximum format, i.e. 456/1000

RawValue- Simply passes through the value. Is default; can be omitted.

Percentage - Displays in a percentage remaining format, i.e. 45%

Bar(length=value,char=value,lcap=value,rcap=value) - Displays a text bar. All arguments can be omitted. length is the number of chars the full bar is made out of, char is the actual character to compose the bar out of, lcap and rcap are the characters to put at the start and end of the bar.

Flag(char=value) - Displays a one-character flag if the value is 1, or hides it if it's 0. The value function must return 0 or 1. Currently only works with InCombat. char changes the character that's displayed; it defaults to "+".

FormattedValue(format=value) - Formats the value with a Lua format string. example: "FormattedValue(format=%u)" would display the value as an integer (no decimal places.)

TO DO LIST:
  1. Implement data object delete/rename
  2. More built-in data value sources
  3. clickable data objects (for click-casting, etc.)
  4. click-thru data objects
  5. (possibly) IncomingHealsLib support
  6. documentation on how to extend Broker_MiniHUD

12/15/08 1:11PM PST
* Fixed a bug in ReactionColor that caused all reaction colors to be yellow.
* Fixed a bug where an exception was thrown if the formatter argument was left out of a tag


Beta 2:
* Implemented an options UI. It's kinda half-assed. No delete or rename at the moment, and we could use some help text in there too. It'll get better, but for now you can add and edit data objects ingame.
* Implemented a tag-based value system. Hopefully it's understandable and easily used. Need feedback here more than anywhere else.
Optional Files (0)


Archived Files (2)
File Name
Version
Size
Author
Date
Beta 2
13kB
Stolberg
12-15-08 02:14 AM
Beta 1
9kB
Stolberg
12-07-08 01:36 AM


Post A Reply Comment Options
Unread 12-16-10, 06:30 AM  
spiralofhope
A Deviate Faerie Dragon
 
spiralofhope's Avatar

Forum posts: 11
File comments: 216
Uploads: 0
This seems like a really interesting addon to play with. Is it working with 4.0.1+ ?
__________________
spiralofhope.com
Report comment to moderator  
Reply With Quote
Unread 06-11-09, 12:53 PM  
Whatever4ever
A Kobold Labourer

Forum posts: 0
File comments: 49
Uploads: 0
Doesn’t count Combo Point, just shows the "0" ?...
Last edited by Whatever4ever : 06-12-09 at 12:07 AM.
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: