View Single Post
06-04-09, 08:55 PM   #20
goris29
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Jun 2009
Posts: 16
Now that code doesn't have any errors when WoW loads, but it doesn't display the frame, or show this message that I put in there just to make sure I knew it didn't work.

Code:
function Frame1_OnEvent()
Frame1:RegisterEvent("CHAT_MSG_ADDON")
Frame1:SetScript("OnEvent", 
 function(self, event, prefix, text, channel, sender)
     if event == "CHAT_MSG_ADDON" then
        if prefix == "Roll" then 
            Frame1:Show()
            message("text")
        end
     end 
    end
    )
 end
Is the name of the OnEvent() function supposed to be named after the FRAME or after the name of the LUA file?
  Reply With Quote