Well, I'm making a custom boss for my server and I want him to cast enrage on himself at 40% health and I want him to only do it once. This is how I have my code written right now:
Well I tried this and when he got to 40% hp nothing happened. I was thinking it might have something to do with the 1 inCode:function Boss_Enrage(Unit, event, miscunit, misc) if Unit:GetHealthPct() == 40 and Didthat == 0 then Unit:FullCastSpell(34670) Didthat = 1 else end end RegisterUnitEvent(9999999,1,"Boss_Enrage")
RegisterUnitEvent(9999999,1,"Boss_Enrage") but I dont know. Please help?