Hey guys!
I just started to learn the basics of lua programming. As the second step after "hello world" I wanted to comminicate with my addon. I though the slash commands would be the easiest way. Since my code didn't work I just copy pasted several sample codes that also didn't work. I'm just getting the response: Type "/help" for a listing of a few commands.
Here is a sample from wowpedia, that also didn't work:
Code:
SLASH_HELLOWORLD1, SLASH_HELLOWORLD2 = '/hiw', '/hellow';
local function handler(msg, editBox)
if msg == 'bye' then
print('Goodbye, World!')
else
print("Hello, World!")
end
end
SlashCmdList["HELLOWORLD"] = handler; -- Also a valid assignment strategy
What is the problem? My only guess is that could be an out of date method and I'm on a wrong way.
Thanks in advance!
Xíry