- Registered User
Member for 13 years, 5 months, and 2 days
Last active Fri, Oct, 4 2013 14:30:03
- 0 Followers
- 26 Total Posts
- 0 Thanks
Feb 19, 2008There are many different philosophies to sharing spell information.Posted in: Libraries
Some believe in only sending information on spells they are interested in(Healcomm).
Some believe in sending all starts/stops/sucesses/interrupts (Comcastlib).
Some just send the start and stop for a single spell (CTraid Rez).
Some believe in only sending target information (Healsync).
Some believe guessing at cast targets is a necessary feature, others feel otherwise (Dorjae's/Nissesync).
... the list goes on (Healbot, etc)
I started writing a library to attempt to unite all of these different philosophies. However, I have since had my guild of over a year dissolve on me, and my interest in Warcraft has disappeared. So I am left with a grandiose vision to unite spell communication and tracking under one banner, and a half finished piece of code full of ideas.
However, I was hoping to spark a glimmer of interest in someone here. It is in that hope I link my unfinished code. If nothing else it will server as a proof of concept or an example of spell tracking to future addons:
The idea behind it is to have it scale to the addon's needs.
It should allow:
1) Spell Registration - this information needs to be shared
2) Optional Long Distance Tracking - START/STOP/DELAY/INTERUPT need to be communicated.
3) Optional Target scanning - Guess at someone's spell target by assuming their target. (half implimented.. tracks scanned targets, but currently doesn't distinguish between accurate/inaccurate)
4) CastingInfo function - Returns what someone is casting (not implimented)
5) CastingOn function - returns a list of people casting on a target (not implimented)
6) Event Callbacks for key events/all events pertaining to the spelllist(currently UNIT_SPELLCAST_* is non-key, where START/STOP/etc is KEY)
7) Remote Callbacks - A way to append information to the event (the structure is there, but it is not finished)
8) Incompatible Version Tracking - Major changes should make the libraries ignore each other.
Anyway, if you are intrested in this, yay, if not, I hope it serves as an example of what to do/not to do ;)
Feb 4, 2008CallbackHandler-1.0.lua creates a new table for undefined Fire() events.Posted in: Ace3
For instance, AceComm-3.0 lets CallbackHandler decide if the prefix from CHAT_MSG_ADDON(event,prefix,message,distribution,sender) is registered or not. In doing so, ANY addon sending a message has a table created under callbacks.events.
Is this the way Fire() is supposed to work? I did not expect it to create tables in such a fashion.
Jan 9, 2008Currently trying to serialize an array with a function in it results in AceSerializer-3.0 throwing an error, about being unable to serialize functions, and it fails to serialize anything. I was wondering if it would be possible to ignore the function key/value pair completely.Posted in: Ace3
I currently have a table that has data that needs to be shared with other clients.. but it also passes callback functions which don't need to be passed. With the current form of AceSerializer-3.0, I'd have to make a copy of the array without the callbacks.
Am I missing something obvious?
Edit: peanut gallery
Sep 19, 2007OK.. here is MouseOverUnitLib-1.0 (with test example) in its very nearly final form.Posted in: Lua Code Discussion
I removed all of the hooks except one: GameTooltip:HookScript("OnTooltipCleared",...
This hook is necessary to detect a transition between 2 models of the same name.
Everything is triggered through OnUpdate now. If nothing can get triggered, OnUpdate gets disabled.
It can be set to be triggered off of 3D models, unitframes, or both.
Tested to work with viewports (see test.lua)
I don't know how useful this lib will be... but there it is.
Edit: Add Beta2. I just added some convenience functions
Edit: Add Beta3. I made it work with LibStub.lua. I also noticed that mouseovers on Blizard frame mana/health bars wern't returning unitIDs, so I forced it in.
Edit: Add Beta4. Taking into account some patch 2.2 changes and found a better way to tie into Blizard mana/health bars/raidtab frames. Frame is still a callback parameter because it is still possible to have a frame with a unit identifier that doesn't work with mouseover. I choose to return party/raid/target unitID's over the mouseover unitID.
Sep 18, 2007Oh.. duh... That is because the OnUpdate handler is called right before each frame is painted. Hmm.. that will work, even if it gets triggered as many times a second as your FPS.Posted in: Lua Code Discussion
self:SetScript("OnUpdate", etc...). Ok.. I'll add it back in.
Sep 14, 2007That is essentially what I've done. I'm thinking I'll just strip the 3d mouseover functionality out for now. Another fun side effect of UPDATE_MOUSEOVER_UNIT is that is doesn't fire when you mouseover an invalid spelltarget while in a spell target choosing state.Posted in: Lua Code Discussion
My conclusion is that it is not possible to detect a MouseLeave from a 3D model, nor maybe even consistently detect a mouseEnter on a 3D model.
Sep 13, 2007This is essentially so clickcasters can see Healsync-like spell bars when they mouseover someone. The other example above has it implemented for mousoverframes, but not 3Dmouseovers. You have to type '/ns mouseover on' to turn it on though.Posted in: Lua Code Discussion
I am still left with the problem of detecting a mouseleave on 3d models
Sep 13, 2007I don't do this because it is possible to have a frame with a unitID that doesn't fire OnTooltipSetUnit.Posted in: Lua Code Discussion
Healbot is an example of this, and there are several in my guild that use it.
Sep 13, 2007That doesn't start a trigger or event. There is no other way to trigger a mouseover of a unitframe other than to hook every frame with a unit ID or potential unit ID. That is how Clique works.Posted in: Lua Code Discussion
Only difference is clique has an array of valid unitframes, and I scan for frames with keywords. And I was thinking of adding a frame array anyway.
Look at the other example to see why this is necessary.
Sep 13, 2007I am looking for a trigger to leaving a 3D model with a unitID.Posted in: Lua Code Discussion
I'm writing a little library to detect a OnEnter/OnLeave of any unit (including mouseover and UnitFrames).
Below: MouseOverUnitLibExample.zip has a simple example of the library.
Below: NisseSyncBeta3.zip (Distributed internally to my guild only) is an example of why such a library would be useful (While I haven't integrated the library, this is where I originally wrote the mouseoverunitframe functionality).
Figuring out how to detect a mouseLeave on a 3D player model is the last thing I have to do.
Edit: Fixed a bug in MouseOverUnitLibExample.zip
Edit: Fixed a Tainting issue
Edit: oops.. I left an unused/non-existent library referenced
Edit: SEE IN POST WAY BELOW for a more recent lib (MouseOverUnitLib-1.0Beta1(withexample).zip)
Edit: Removed NisseSync example.. a better way way found IN THE POST WAY BELOW.
Sep 13, 2007I know you can use UPDATE_MOUSEOVER_UNIT to detect a OnEnter on a 3D model, and I know you can use CURSOR_UPDATE to detect the OnLeave on a 3D model that changes the cursor.Posted in: Lua Code Discussion
How do you detect a OnLeave on a 3D model that doesn't change the cursor?
I noticed that tooltips have no problem detecting when you OnLeave a 3D model, so my next inclination is to hook some function in the tooltips. Any idea which one that should be? A quick "FadeOut" test didn't seem to work. While this:
...gets close, it does not trigger after leaving. There is a delay while the tooltip fades.
- To post a comment, please login or register a new account.