Quantcast
WoWInterface - View Single Post - How to send arguments in OnEvent?
View Single Post
11-07-20, 04:42 PM   #1
lungdesire
A Deviate Faerie Dragon
Join Date: May 2020
Posts: 13
How to send arguments in OnEvent?

Hello everyone. How to send arguments in OnEvent?

Code:
h = { "hello", "bye" }

for key, val in pairs(h) do
-- How send "hello" and "bye" in OnEvent ? 
end

local function OnEvent(self, event, ...)
print(arg1)
end

local f = CreateFrame("Frame")
f:RegisterEvent("PLAYER_ENTERING_WORLD")
f:SetScript("OnEvent", OnEvent)

Last edited by lungdesire : 11-08-20 at 04:20 AM.
  Reply With Quote