Originally Posted by
lostinthewoodslol
Oh kk. so would i be on the right track by doing these two, to swap between respective classes?
Name: Frost Armor
Spell ID: 7302
Delay: 500
Target: Player
Code:
if UnitBuffID("player", 7302) == nil and UnitAffectingCombat("player") == nil and UnitClassBase("Druid, Warrior, Death Knight, Hunter, Rogue") then
return true
end
Name: Mage Armor
Spell ID: 6117
Delay: 500
Target: Player
Code:
if UnitBuffID("player", 6117) == nil and UnitAffectingCombat("player") == nil and UnitClassBase("Mage, Warlock, Shaman, Priest") then
return true
end
nope. lol. confirmed does not work

i tried atleast
Heres what your looking for.
Name: Frost Armor
Spell ID: 7302
Delay: 500
Target: Player
Code:
local class, token = UnitClassBase("target")
local ps = {Druid, Warrior, Death Knight, Hunter, Rogue}
for i,v in ipairs(ps) do
if UnitBuffID("player", 7302) == nil and UnitAffectingCombat("player") == nil and class == v then
return true
end
end
Name: Mage Armor
Spell ID: 6117
Delay: 500
Target: Player
Code:
local class, token = UnitClassBase("target")
local ps = {Mage, Warlock, Shaman, Priest}
for i,v in ipairs(ps) do
if UnitBuffID("player", 7302) == nil and UnitAffectingCombat("player") == nil and class == v then
return true
end
end
I didnt tested it since im at work, but should work.
Try it and say if it worked or not.