Okay, as I'm getting Clique to Beta stage, I need to get some more feedback about what you want to see from a Click-Casting mod. The standards that have materialized (mostly as a result of CTRA) consist of the following:
Click-casting functions have the prototype funcName("button", "unit"). "button" can be passed from arg1, and typically is handled by the mod calling the click-cast, or set ourselves if we're hooking. Unit typically comes from this.unit, but is again provided from the frames, or pulled via this.unit. Anything else that needs to be said really?
Provide a simple MyModName_CustomClickCast function that can be set by any click-casting mod. If this function has a value, then the mod itself handles calling the click-cast function.. for example:
if MyMod.CustomClickCast then
if MyMod.CustomClickCast(arg1, this.unit) then
-- Here we fall into the typical logic, popping up unit menu, target, trade, feed pet, etc.
These mods don't provide a magical function, so we're forced to hook the handlers, this is okay-- but makes more work on the plugin side.