Rename this file to custom.lua to attach custom code to the addon. Once |
renamed, you'll need to completely restart WoW so that it detects the file. |
|
Updated 24/12/12: |
|
* all functions are now inside the table `c` |
|
* RegisterPostFunction calls have been updated, copy and paste the last 4 |
lines into your custom.lua, overwriting the previous 4 lines. |
Updated 14/03/13: |
|
* kn is now set using an AceAddon call rather than a global. Copy and paste |
the topmost line into your custom.lua, overwriting the previous line. |
* Now using AceEvent's RegisterMessage. |
|
* Functions are now in the `mod` table. |
]] |
local kn = LibStub('AceAddon-3.0'):GetAddon('KuiNameplates') |
local c = {} |
local mod = kn:NewModule('CustomInjector', 'AceEvent-3.0') |
|
---------------------------------------------------------------------- Create -- |
function c:PostCreate(frame) |
function mod:PostCreate(msg, frame) |
-- Place code to be performed after a frame is created here. |
end |
|
------------------------------------------------------------------------ Show -- |
function c:PostShow(frame) |
function mod:PostShow(msg, frame) |
-- Place code to be performed after a frame is shown here. |
end |
|
------------------------------------------------------------------------ Hide -- |
function c:PostHide(frame) |
function mod:PostHide(msg, frame) |
-- Place code to be performed after a frame is hidden here. |
end |
|
---------------------------------------------------------------------- Target -- |
function c:PostTarget(frame) |
function mod:PostTarget(msg, frame) |
-- Place code to be performed when a frame becomes the player's target here. |
end |
|
-------------------------------------------------------------------- Register -- |
kn:RegisterPostFunction('create', c, 'PostCreate') |
kn:RegisterPostFunction('show', c, 'PostShow') |
kn:RegisterPostFunction('hide', c, 'PostHide') |
kn:RegisterPostFunction('target', c, 'PostTarget') |