Wow! I seriously didn't expect to get answers that fast! Thank you!
Regarding printing the name of the event, I just printed the value that is passed in the event parameter. I do indeed get the correct event name, LUA_WARNING.
I also tried to do a:
That prints '0 (null)'.
The fact I do get a number and a string (nil - abscence of a string rather) like I am expecting makes me think Blizzard is hiding the information on purpose, but that does sound weird to me. Everything works perfectly for any other event, so I don't understand what is going on
EDIT: I just noticed in your comment that it does say that neither of the values is nilable... That makes this even weirder.
Here is the frame:OnEvent() part (sorry I didn't think it was important since the correct function does get called:
Code:
local function AST_CreateWindowFrame()
_V.MainWindowFrame = CreateFrame("Frame", _V.C.AddOnName, UIParent)
local frame = _V.MainWindowFrame
frame:SetScript("OnEvent", _V.F.MainEventHandler)
local RegEvt = _V.F.RegisterEvent
RegEvt(frame, "ADDON_ACTION_BLOCKED", nil)
RegEvt(frame, "ADDON_ACTION_FORBIDDEN", nil)
RegEvt(frame, "LUA_WARNING", AST_Event_LUAWarning)
RegEvt(frame, "SAVED_VARIABLES_TOO_LARGE", nil)
RegEvt(frame, "ADDONS_UNLOADING", nil)
RegEvt(frame, "ADDON_LOADED", AST_Event_AddOnLoaded)
RegEvt(frame, "PLAYER_ENTERING_WORLD", AST_Event_PlayerEnteringWorld)
RegEvt(frame, "AUCTION_HOUSE_SHOW", nil)
RegEvt(frame, "AUCTION_HOUSE_CLOSED", nil)
frame:SetFrameStrata(_V.C.MainFrameStrata)
frame:SetWidth(_V.F.GetConfigItem("MainFrame Width"))
frame:SetHeight(_V.F.GetConfigItem("MainFrame Height"))
frame:SetPoint("CENTER", UIParent, "CENTER")
frame.skeleton = frame:CreateTexture("AuctionScanner_Skeleton", "BORDER")
frame.skeleton:SetAllPoints()
-- frame.skeleton:SetTexture("Interface/AUCTIONFRAME/AuctionHouseBackgrounds")
-- local top, bottom, left, right = 0.39, 0.79, 0.18, 0.47
-- frame.skeleton:SetTexCoord(left, top, left, bottom, right, top, right, bottom)
frame.skeleton:SetColorTexture(0, 0, 0, 0.25)
frame.title = frame:CreateFontString("AuctionScanner_Title", "OVERLAY", "GameFontNormal")
frame.title:SetPoint("TOP", 0, 0)
frame.title:SetText("Auction Scanner Tool")
-- Make sure you can only run this function ONCE --
_V.F.CreateWindowFrame = _V.F.dummy
end