October 31, 20178 yr Some classes has spells to avoid falling damage. For example, priest has "Levitate". Problem is to detect when this spell required 1) declare global LUA variable in additional C# code string fallTime=Lua.LuaDoString("fallTime=nil","fallTime"); 2) add spell "Levitate", with options: Can move during cast = Yes; Cast if mounted = true; Cast spell on = player; Combat only = false 3) add conditions for this spell: - Buff (Name=Levitate, Need=false) - Lua script, with return var "falling" and return value research "ok" falling="no" if(IsFalling()) then if (fallTime==nil) then fallTime=GetTime() elseif (GetTime()-fallTime>=1) then falling="ok" end else fallTime=nil end Thats all. When priest falls more than 1 second, bot automatically buffs him. Now you can queue Arathi Basin and go def LM But not all Spoiler Other classes has chance too. Go to Gatzetdan and buy a lot of Noggenfogger Elixir. And now is time to hack it 1) first step is the same 2) Instead "Levitate" add LUA code, with the same options and timer=3000 UseItemByName("Noggenfogger Elixir") 3) Use the same conditions, and 1 more. This is LUA script with return var "need" and return value research "y": need="y" for i=1,40 do local n,_,_,_,_,_,x,_,_,_,id=UnitBuff("player",i) if n and id==16593 and x>1 then need="n" fallTime=nil break end end Now you have 33% chance to survive. Or acquare strange look. Or both
November 1, 20178 yr Author 52 minutes ago, camelot10 said: ObjectManager.Me.IsFallingFar It would be nice to have C# conditions in fight class editor, but for now there is only LUA. Of course, in C# fight class ObjectManager.Me.IsFallingFar is the best choice
November 1, 20178 yr 1 hour ago, ivanra said: It would be nice to have C# conditions in fight class editor, but for now there is only LUA. Of course, in C# fight class ObjectManager.Me.IsFallingFar is the best choice You can use C# with the condition name "C Sharp Code"
November 1, 20178 yr Author 11 hours ago, Droidz said: You can use C# with the condition name "C Sharp Code" Indeed. So, no need for 1), and for 3) C# conditions are ObjectManager.Me.IsFallingFar && !Me.HaveBuff("Levitate") // for levitate or some other levitate spells/trinkets ObjectManager.Me.BuffTimeLeft(new List<uint> {16593}) < 1000 // for Noggenfogger Elixir
November 2, 20178 yr Author tested: IsFallingFar triggers too fast. Bot uses spell almost immediately (and dismount). So, solution with ~1 second delay after fall start is better
Create an account or sign in to comment