Happy botting!
GoldenLotus.AoeSpamKey = 69;
More quests, fixed some bugs, optimized some stuff.Currently supports around 70 quests.
I intended to polish it as soon as some of the bot issues described in this thread and in http://mmocrawlerbots.com/forum/bugs/14c-no-longer-fighting-friendly-mobs-bug/ are resolved.I'm not aware of any issues with the script that are not caused by certain bot behaviours that cannot be controlled via a profile at this time. Feel free to be more specific :-).I didn't check yet if the new plugin system is helpful for addressing any of these issues.
local LastMob = {};for i=1,10,1 do table.insert(LastMob, i, { 0 });endlocal MobCount = {};for i=1,10,1 do table.insert(MobCount, i, { 0 });endfunction MobAttackOutdoor(MobID, MobPosHolder, SearchForText, MaxDistance, MinMobHP, WaitTime, Precision, XYDistance, MessageLevel) -- MobAttackOutdoor(67756, 1, "Domination Point Supply Cart", 70, 100, 2000, 10, 20, 1) -- MobID == Object ID of NPC-- MobPosHolder is an internal ID for the Counter (MobCount) and the position of the Last killed Mob-- You can get the value with this function:-- local Wert = MobCount[1]-- if Wert[1] >= 4 then-- _Log("####Check####")-- end-- If you Use 3 as second Parameter: MobAttackOutdoor(67756, 3, "Domination Point Supply Cart", 70, 100, 2000, 10, 20, 1)-- Then you can get the Value with the following function:-- local Wert = MobCount[3]-- if Wert[1] >= 4 then-- _Log("####Check####")-- end-- The MobAttackOutdoor-function will remember his last Target on the MobPosHolder ID (1 or 3 in my example), so this function will not fly two times to the same Mob.-- This is only nessesary, if you set the MinMobHP to 0. (Not needed at this time, but who know what will come. ^^)-- SearchForText is the Text you want to display in your log. The Script will Add (Range to SEARCHFORTEXT:)-- MaxDistance is the max Range, you would fly or walk to an NPC. if the NPC has an Range of 75 to your Char, he will not be attacked. If he is in an range of 65, your Char will fly to him an starts to fight.-- MinMobHP is the nessesary Life of the NPC -- If the NPC has 95% Life, he will not be attacked.-- If you change the 100 to 50, then the Bot will also attack an NPC with 55% life. ^^-- WaitTime is the Time for Sleep. The Script will make the following when the Bot reaches the NPC-- DisMount, Sleep(1000)-- InteractWith(TaAdr), KillMob(GetTargetAddress()), Sleep(1000)-- If you change 2000 to 3000 he will Sleep two times for: Sleep(1500)-- Get it?-- Precision is the Precision of the coordinates to where the Bot will Navigate to.-- If you change it to 1 you will have many UNSTUCKs.-- Beleave me, that 10 is an good value.-- XYDistance is the x and y distance to the npc. If you have an Range-Char with an range of 40, then set it max to 20. For an Meele you should use 5 or 7-- MessageLevel is only 0 or 1. If you dont want to see text from this function in your Log, then set it to 0 WowLuaDoString('fighting = InCombatLockdown()') if tonumber(WowGetLuaValue("fighting")) == 1 then WowLuaDoString("attackingmob = UnitAffectingCombat('target')") WowLuaDoString("existingmob = UnitExists('target')") attackingmob = tonumber(WowGetLuaValue("attackingmob")) existingmob = tonumber(WowGetLuaValue("existingmob")) if attackingmob == 1 and existingmob == 1 then if GetTargetAddress() ~= 0 then KillMob(GetTargetAddress()) Sleep(1000) FightCheck() WowLuaDoString("AttackTarget()") WowLuaDoString("ClearTarget()") end end end DoMount() WowLuaDoString("ClearTarget()") TaAdr = GetObjectByID(MobID) if TaAdr > 0 then TApos = GetUnitPos(TaAdr) local Wert = LastMob[MobPosHolder] if Wert[1]==TApos[0] then return false else _Log("source") source = GetUnitPos(GetPlayer()) if math.floor(math.sqrt(math.pow(source[0] - TApos[0],2) + math.pow(source[1] - TApos[1],2) + math.pow(source[2] - TApos[2],2))) < MaxDistance then SetTarget(TaAdr) local target; if (TaAdr == Player) then target="player"; else target="target"; end WowLuaDoString('hp=100 * UnitHealth("' .. target .. '") / UnitHealthMax("' .. target .. '")'); if tonumber(WowGetLuaValue("hp")) >= MinMobHP then if MessageLevel == 1 then _Log("Range to " .. SearchForText .. ": " ..math.floor(math.sqrt(math.pow(source[0] - TApos[0],2) + math.pow(source[1] - TApos[1],2) + math.pow(source[2] - TApos[2],2)))) end GlobalFlyingNavigate(TApos[0]+XYDistance, TApos[1]+XYDistance, TApos[2]+15, Precision); TApos = GetUnitPos(TaAdr) GlobalFlyingNavigate(TApos[0]+XYDistance, TApos[1]+XYDistance, TApos[2]+5, Precision); Sleep(WaitTime/2) DisMount() Sleep(WaitTime) InteractWith(TaAdr) KillMob(GetTargetAddress()) Sleep(WaitTime/2) TApos = GetUnitPos(TaAdr) local Wert = LastMob[MobPosHolder] table.remove(LastMob,MobPosHolder) table.insert(LastMob, MobPosHolder, { TApos[0] }); local Wert = LastMob[MobPosHolder] DoMount() local Wert = MobCount[MobPosHolder] table.remove(MobCount,MobPosHolder) table.insert(MobCount, MobPosHolder, { Wert[1] +1 }); local Wert = MobCount[MobPosHolder] CurrentPlayerPos = GetUnitPos(GetPlayer()) GlobalFlyingNavigate(CurrentPlayerPos[0], CurrentPlayerPos[1], CurrentPlayerPos[2]+15, Precision); WowLuaDoString("ClearTarget()") return true else return false end else return false end end else return false end end