Thread Tools Display Modes
Prev Previous Post   Next Post Next
10-15-20, 03:12 PM   #1
awildgoose11
A Defias Bandit
Join Date: Mar 2020
Posts: 3
Question Help with Hunter pet addon (WoW classic)

I am a complete noob with Lua, but the basic thing I want it to do is use the message to pop up on the screen when the "var1" from GetPetHappiness() goes from 3 to 2.

Any help would be appreciated!

Code:
local p = {}
local var1,var2,var3=GetPetHappiness()
function p.repeatloop()
    local var1,var2,var3=GetPetHappiness()
    local result
 
    result = ';repeat\n'
    repeat 
        result = result .. ":var1 = " .. var1 .. '\n'
        var1,var2,var3=GetPetHappiness()
    until var1 = 2
    message('Feed your pet!')
 
    return result
end

return p
  Reply With Quote
 

WoWInterface » Developer Discussions » General Authoring Discussion » Help with Hunter pet addon (WoW classic)

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off