Hi. I just found this macro, and instead of having to hit it everytime a loading screen finishes i figure i can write a addon for it.

I did some research but guides everywhere, wowwiki mostly, goes from "Hello World!" to quantum mechanics in 5 steps.

From what i could distinguish was that the event i'm looking for is PLAYER_ENTERING_WORLD(?) and it was something about calling upon this event in XML to save memory(?). After that it became gibberish.

The lines i want it to write after every loading screen are these 2:

/run TargetFrameToT:ClearAllPoints()
/run TargetFrameToT:SetPoint("TOP",120,-40)

Any kind soul in here with help to offer? Thank you.

---------- Post added 2012-10-20 at 04:52 PM ----------

Got help from irc. If anyone is interested, here it is. It moves target of target on blizzard default ui frames. Change coords after "SetPoint" to move it where you want it.

Save as whatever.lua

Code:
local frame = CreateFrame("FRAME")
frame:RegisterEvent("PLAYER_ENTERING_WORLD")
frame:SetScript("OnEvent", function()
    TargetFrameToT:ClearAllPoints()
    TargetFrameToT:SetPoint("TOP",120,-40)
end)
Save as whatever.toc

Code:
## Interface: 50001
## Title: what evs
## Version: 1.0
## Author: 
## Notes: moves blizz default target of target

whatever.lua