diff --git a/Addons/DataToColor/Constants.lua b/Addons/DataToColor/Constants.lua index 6763c18c4..57958fb53 100644 --- a/Addons/DataToColor/Constants.lua +++ b/Addons/DataToColor/Constants.lua @@ -21,7 +21,8 @@ DataToColor.C.Totem = "Totem" -- Character's name DataToColor.C.CHARACTER_NAME = UnitName(DataToColor.C.unitPlayer) DataToColor.C.CHARACTER_GUID = UnitGUID(DataToColor.C.unitPlayer) -_, DataToColor.C.CHARACTER_CLASS = UnitClass(DataToColor.C.unitPlayer) +_, DataToColor.C.CHARACTER_CLASS, DataToColor.C.CHARACTER_CLASS_ID = UnitClass(DataToColor.C.unitPlayer) +_, _, DataToColor.C.CHARACTER_RACE_ID = UnitRace(DataToColor.C.unitPlayer) -- Actionbar power cost DataToColor.C.MAX_POWER_TYPE = 1000000 diff --git a/Addons/DataToColor/DataToColor.lua b/Addons/DataToColor/DataToColor.lua index ac1091572..c2e50c311 100644 --- a/Addons/DataToColor/DataToColor.lua +++ b/Addons/DataToColor/DataToColor.lua @@ -48,12 +48,23 @@ DataToColor.lastCombatCreatureDied = 0 DataToColor.lastAutoShot = 0 DataToColor.lastMainHandMeleeSwing = 0 +DataToColor.lastCastEvent = 0 +DataToColor.lastCastSpellId = 0 + +DataToColor.lastCastStartTime = 0 +DataToColor.CastNum = 0 DataToColor.targetChanged = true DataToColor.playerGUID = UnitGUID(DataToColor.C.unitPlayer) DataToColor.petGUID = UnitGUID(DataToColor.C.unitPet) +-- buff / debuff counters +local playerDebuffCount = 0 +local playerBuffCount = 0 +local targetDebuffCount = 0 +local targetBuffCount = 0 + -- Update Queue stack = {} DataToColor.stack = stack @@ -169,6 +180,16 @@ function DataToColor:Reset() DataToColor.lastAutoShot = 0 DataToColor.lastMainHandMeleeSwing = 0 + DataToColor.lastCastEvent = 0 + DataToColor.lastCastSpellId = 0 + + DataToColor.lastCastStartTime = 0 + DataToColor.CastNum = 0 + + playerDebuffCount = 0 + playerBuffCount = 0 + targetDebuffCount = 0 + targetBuffCount = 0 end function DataToColor:Update() @@ -336,10 +357,14 @@ function DataToColor:CreateFrames(n) -- 20 bagNum = DataToColor.stack:pop(DataToColor.bagQueue) if bagNum then - local freeSlots, bagType = GetContainerNumFreeSlots(bagNum) or 0, 0 + local freeSlots, bagType = GetContainerNumFreeSlots(bagNum) + if not bagType then + bagType = 0 + end + -- BagType + Index + FreeSpace + BagSlots MakePixelSquareArrI(bagType * 1000000 + bagNum * 100000 + freeSlots * 1000 + DataToColor:bagSlots(bagNum), 20) - --DataToColor:Print("bagQueue "..bagType.." -> "..bagNum.." -> "..freeSlots.." -> "..DataToColor:bagSlots(bagNum)) + --DataToColor:Print("bagQueue bagType:"..bagType.." | bagNum: "..bagNum.." | freeSlots: "..freeSlots.." | BagSlots: "..DataToColor:bagSlots(bagNum)) end -- 21 22 23 @@ -425,7 +450,7 @@ function DataToColor:CreateFrames(n) --MakePixelSquareArrI(DataToColor:GetGossipIcons(), 45) -- Returns which gossip icons are on display in dialogue box - MakePixelSquareArrI(DataToColor.S.PlayerClass, 46) -- Returns player class as an integer + MakePixelSquareArrI(DataToColor.C.CHARACTER_RACE_ID * 100 + DataToColor.C.CHARACTER_CLASS_ID, 46) MakePixelSquareArrI(DataToColor:isUnskinnable(), 47) -- Returns 1 if creature is unskinnable MakePixelSquareArrI(DataToColor:shapeshiftForm(), 48) -- Shapeshift id https://wowwiki.fandom.com/wiki/API_GetShapeshiftForm MakePixelSquareArrI(DataToColor:getRange(), 49) -- 15 Represents if target is within 0-5 5-15 15-20, 20-30, 30-35, or greater than 35 yards @@ -437,7 +462,25 @@ function DataToColor:CreateFrames(n) MakePixelSquareArrI(DataToColor:CastingInfoSpellId(DataToColor.C.unitPlayer), 53) -- Spell being cast MakePixelSquareArrI(DataToColor:ComboPoints(), 54) -- Combo points for rogue / druid - MakePixelSquareArrI(DataToColor:getAuraCount(UnitDebuff, DataToColor.C.unitPlayer), 55) + + playerDebuffCount = DataToColor:getAuraCount(UnitDebuff, DataToColor.C.unitPlayer) + playerBuffCount = DataToColor:getAuraCount(UnitBuff, DataToColor.C.unitPlayer) + + if UnitExists(DataToColor.C.unitTarget) then + targetDebuffCount = DataToColor:getAuraCount(UnitDebuff, DataToColor.C.unitTarget) + targetBuffCount = DataToColor:getAuraCount(UnitBuff, DataToColor.C.unitTarget) + else + targetDebuffCount = 0 + targetBuffCount = 0 + end + + if playerDebuffCount > 16 then + playerDebuffCount = 16 + end + + -- player/target buff and debuff counts + -- formula playerDebuffCount + playerBuffCount + targetDebuffCount + targetBuffCount + MakePixelSquareArrI(playerDebuffCount * 1000000 + playerBuffCount * 10000 + targetDebuffCount * 100 + targetBuffCount, 55) if DataToColor.targetChanged then MakePixelSquareArrI(DataToColor:targetNpcId(), 56) -- target id @@ -450,9 +493,8 @@ function DataToColor:CreateFrames(n) MakePixelSquareArrI(DataToColor.lastAutoShot, 60) MakePixelSquareArrI(DataToColor.lastMainHandMeleeSwing, 61) - -- 62 not used - -- 63 not used - -- 64 not used + MakePixelSquareArrI(DataToColor.lastCastEvent, 62) + MakePixelSquareArrI(DataToColor.lastCastSpellId, 63) MakePixelSquareArrI(DataToColor.lastCombatCreature, 64) -- Combat message creature MakePixelSquareArrI(DataToColor.lastCombatDamageDoneCreature, 65) -- Last Combat damage done @@ -461,10 +503,13 @@ function DataToColor:CreateFrames(n) MakePixelSquareArrI(DataToColor:getGuid(DataToColor.C.unitPet), 68) -- pet guid MakePixelSquareArrI(DataToColor:getGuid(DataToColor.C.unitPetTarget), 69) -- pet target + MakePixelSquareArrI(DataToColor.CastNum, 70) -- Timers - MakePixelSquareArrI(DataToColor.globalTime, 70) - MakePixelSquareArrI(DataToColor.lastLoot, 71) + MakePixelSquareArrI(DataToColor.lastLoot, 97) + MakePixelSquareArrI(DataToColor.globalTime, 98) + + -- 99 Reserved DataToColor:ConsumeChanges() diff --git a/Addons/DataToColor/DataToColor.toc b/Addons/DataToColor/DataToColor.toc index cf33a38cc..77588a444 100644 --- a/Addons/DataToColor/DataToColor.toc +++ b/Addons/DataToColor/DataToColor.toc @@ -2,7 +2,7 @@ ## Title: DataToColor ## Author: FreeHongKongMMO ## Notes: An addon that displays player position as color -## Version: 1.1.26 +## Version: 1.1.35 ## RequiredDeps: ## OptionalDeps: Ace3, LibDataBroker-1.1, LibCompress, LibRangeCheck ## SavedVariables: diff --git a/Addons/DataToColor/EventHandlers.lua b/Addons/DataToColor/EventHandlers.lua index 7e4fbb241..812679acd 100644 --- a/Addons/DataToColor/EventHandlers.lua +++ b/Addons/DataToColor/EventHandlers.lua @@ -1,6 +1,9 @@ local Load = select(2, ...) local DataToColor = unpack(Load) +local CAST_START = 999998 +local CAST_SUCCESS = 999999 + local ignoreErrorList = { "ERR_ABILITY_COOLDOWN", "ERR_OUT_OF_RAGE", @@ -23,6 +26,8 @@ local errorList = { "ERR_SPELL_COOLDOWN", --7 "Spell is not ready yet." "ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS", --8 "Another action is in progress" "ERR_SPELL_FAILED_STUNNED", -- 9 "Can't do that while stunned" + "SPELL_FAILED_INTERRUPTED", -- 10 "Interrupted" + "SPELL_FAILED_ITEM_NOT_READY" -- 11 "Item is not ready yet" }; function DataToColor:RegisterEvents() @@ -39,53 +44,85 @@ function DataToColor:RegisterEvents() end function DataToColor:OnUIErrorMessage(event, messageType, message) - local errorName = GetGameMessageInfo(messageType) + local code, ignored, foundMessage, message = DataToColor:GetErrorCode(messageType, message) + + if ignored then + UIErrorsFrame:AddMessage(message, 0.7, 0.7, 0.7) -- show as grey messasge + elseif foundMessage and code ~= 0 then + DataToColor.uiErrorMessage = code; + UIErrorsFrame:AddMessage(message, 0, 1, 0) -- show as green messasge + else + UIErrorsFrame:AddMessage(message, 0, 0, 1) -- show as blue message (unknown message) + end +end + +function DataToColor:GetErrorCode(messageType, message) + + local errorName + local foundMessage = false + local ignored = false + local code = 0 + + if messageType ~= nil then + errorName = GetGameMessageInfo(messageType) + end - local foundMessage=false; for i = 1, table.getn(ignoreErrorList), 1 do - if ignoreErrorList[i]==errorName then - foundMessage=true; - UIErrorsFrame:AddMessage(message, 0.7, 0.7, 0.7) -- show as grey messasge + if ignoreErrorList[i] == errorName then + foundMessage = true; + ignored = true end end - if not foundMessage then + if not ignored and not foundMessage then for i = 1, table.getn(errorList), 1 do - if errorList[i]==errorName then - DataToColor.uiErrorMessage = i; - - if errorName==errorList[2] then -- ERR_SPELL_FAILED_S - if message==SPELL_FAILED_UNIT_NOT_INFRONT then - DataToColor.uiErrorMessage = 1 - message = message.." ("..ERR_BADATTACKFACING..")" - elseif message==SPELL_FAILED_MOVING then - DataToColor.uiErrorMessage = 6 - elseif message==SPELL_FAILED_STUNNED then - DataToColor.uiErrorMessage = 9 - --message = message.." ("..SPELL_FAILED_STUNNED..")" - --else - -- message = message.." (Spell related)" - end - end - - foundMessage=true; - UIErrorsFrame:AddMessage(message, 0, 1, 0) -- show as green messasge + if errorList[i] == errorName or + (_G[errorList[i]] ~= nil and string.find(_G[errorList[i]], message)) then + code = i; + foundMessage = true; end end end - if not foundMessage then - UIErrorsFrame:AddMessage(message, 0, 0, 1) -- show as blue message (unknown message) + -- ERR_SPELL_FAILED_S + -- find by message ex combatlog + if not ignored and (not foundMessage or errorName == errorList[2]) then + if string.find(message, SPELL_FAILED_UNIT_NOT_INFRONT) then + code = 1 + foundMessage = true + message = message.." ("..ERR_BADATTACKFACING..")" + elseif string.find(message, SPELL_FAILED_MOVING) then + foundMessage = true + code = 6 + elseif string.find(message, SPELL_FAILED_STUNNED) then + foundMessage = true + code = 9 + end end + + return code, ignored, foundMessage, message end local watchedSpells = { [DataToColor.C.Spell.AutoShotId] = function () --DataToColor:Print("Auto Shot detected") DataToColor.lastAutoShot = DataToColor.globalTime - end + end } +local swing_reset_spells = { + --[[ Maul ]] + [132136]=1, + --[[ Raptor Strike ]] + [132223]=1, + --[[ Cleave ]] + [132338]=1, + --[[ Heroic Strike ]] + [132282]=1, + --[[ Slam ]] + [132340]=1 +} + function DataToColor:OnCombatEvent(...) local _, eventType, _, sourceGUID, sourceName, _, _, destGUID, destName, _, _, spellId, _, _ = CombatLogGetCurrentEventInfo(); --print(CombatLogGetCurrentEventInfo()) @@ -93,32 +130,58 @@ function DataToColor:OnCombatEvent(...) DataToColor.lastCombatCreature=0; elseif string.find(sourceGUID, "Creature") then DataToColor.lastCombatCreature = DataToColor:getGuidFromUUID(sourceGUID); - --print(CombatLogGetCurrentEventInfo()) else DataToColor.lastCombatCreature=0; - --print("Other "..eventType); end if string.find(sourceGUID, "Creature") and (destGUID == DataToColor.playerGUID or destGUID == DataToColor.petGUID) then DataToColor.lastCombatDamageTakenCreature = DataToColor:getGuidFromUUID(sourceGUID); - --print(sourceGUID.." "..DataToColor.lastCombatDamageTakenCreature.." "..sourceName); end - if eventType=="SPELL_CAST_SUCCESS" and sourceGUID == DataToColor.playerGUID then - if watchedSpells[spellId] then watchedSpells[spellId]() end - end + if sourceGUID == DataToColor.playerGUID then + if eventType=="SPELL_CAST_SUCCESS" then + if watchedSpells[spellId] then watchedSpells[spellId]() end + + local _, _, icon = GetSpellInfo(spellId) + if swing_reset_spells[icon] then + --DataToColor:Print("Special Melee Swing detected") + DataToColor.lastMainHandMeleeSwing = DataToColor.globalTime + end + end - if string.find(eventType, "_DAMAGE") then - if sourceGUID == DataToColor.playerGUID or sourceGUID == DataToColor.petGUID then + if string.find(eventType, "_CAST_START") then + DataToColor.lastCastEvent = CAST_START + DataToColor.lastCastSpellId = spellId + --print(CombatLogGetCurrentEventInfo()) + --print("_CAST_START "..spellId) + end + + if string.find(eventType, "_CAST_SUCCESS") or string.find(eventType, "_CAST_FAILED") then + --print(CombatLogGetCurrentEventInfo()) + DataToColor.lastCastSpellId = spellId + + if string.find(eventType, "_CAST_FAILED") then + --local lastCastEvent = DataToColor.lastCastEvent + local failedType = select(15, CombatLogGetCurrentEventInfo()) + DataToColor.lastCastEvent = DataToColor:GetErrorCode(nil, failedType) + --print(lastCastEvent.." -> "..DataToColor.lastCastEvent.." "..failedType.." "..spellId) + else + DataToColor.lastCastEvent = CAST_SUCCESS + end + end + + -- matches SWING_ RANGE_ SPELL_ but not SPELL_PERIODIC + if not string.find(eventType, "SPELL_PERIODIC") and + (string.find(eventType, "_DAMAGE") or string.find(eventType, "_MISSED")) then DataToColor.lastCombatDamageDoneCreature = DataToColor:getGuidFromUUID(destGUID); end - end - if sourceGUID == DataToColor.playerGUID and string.find(eventType, "SWING_") then - local _, _, _, _, _, _, _, _, _, isOffHand = select(12, ...) - if not isOffHand then - --DataToColor:Print("Melee Swing detected") - DataToColor.lastMainHandMeleeSwing = DataToColor.globalTime + if string.find(eventType, "SWING_") then + local _, _, _, _, _, _, _, _, _, isOffHand = select(12, ...) + if not isOffHand then + --DataToColor:Print("Normal Melee Swing detected") + DataToColor.lastMainHandMeleeSwing = DataToColor.globalTime + end end end diff --git a/Addons/DataToColor/Query.lua b/Addons/DataToColor/Query.lua index 95cd84bd7..14b9900f7 100644 --- a/Addons/DataToColor/Query.lua +++ b/Addons/DataToColor/Query.lua @@ -98,13 +98,21 @@ function DataToColor:GetTargetName(partition) return 0 end -function DataToColor:CastingInfoSpellId(target) - local _, _, _, _, _, _, _, spellID = UnitCastingInfo(target) +function DataToColor:CastingInfoSpellId(unitId) + local _, _, _, _, startTime, _, _, spellID = UnitCastingInfo(unitId) if spellID ~= nil then + if unitId == DataToColor.C.unitPlayer and startTime ~= DataToColor.lastCastStartTime then + DataToColor.lastCastStartTime = startTime + DataToColor.CastNum = DataToColor.CastNum + 1 + end return spellID end - _, _, _, _, _, _, spellID = UnitChannelInfo(target) + _, _, _, startTime, _, _, spellID = UnitChannelInfo(unitId) if spellID ~= nil then + if unitId == DataToColor.C.unitPlayer and startTime ~= DataToColor.lastCastStartTime then + DataToColor.lastCastStartTime = startTime + DataToColor.CastNum = DataToColor.CastNum + 1 + end return spellID end return 0 diff --git a/Addons/DataToColor/Storage.lua b/Addons/DataToColor/Storage.lua index 3d73f19cf..9afefc78b 100644 --- a/Addons/DataToColor/Storage.lua +++ b/Addons/DataToColor/Storage.lua @@ -1,45 +1,18 @@ local Load = select(2, ...) local DataToColor = unpack(Load) -DataToColor.S.PlayerClass = 0 DataToColor.S.spellInRangeList = {} DataToColor.S.playerBuffs = {} DataToColor.S.targetDebuffs = {} function DataToColor:InitStorage() - CreatePlayerClass() CreateSpellInRangeList() CreatePlayerBuffList() CreateTargetDebuffList() end -function CreatePlayerClass() - -- UnitClass returns class and the class in uppercase e.g. "Mage" and "MAGE" - if DataToColor.C.CHARACTER_CLASS == "MAGE" then - DataToColor.S.PlayerClass = 128 - elseif DataToColor.C.CHARACTER_CLASS == "ROGUE" then - DataToColor.S.PlayerClass = 64 - elseif DataToColor.C.CHARACTER_CLASS == "WARRIOR" then - DataToColor.S.PlayerClass = 32 - elseif DataToColor.C.CHARACTER_CLASS == "PALADIN" then - DataToColor.S.PlayerClass = 16 - elseif DataToColor.C.CHARACTER_CLASS == "HUNTER" then - DataToColor.S.PlayerClass = 8 - elseif DataToColor.C.CHARACTER_CLASS == "PRIEST" then - DataToColor.S.PlayerClass = 4 - elseif DataToColor.C.CHARACTER_CLASS == "SHAMAN" then - DataToColor.S.PlayerClass = 2 - elseif DataToColor.C.CHARACTER_CLASS == "WARLOCK" then - DataToColor.S.PlayerClass = 1 - elseif DataToColor.C.CHARACTER_CLASS == "DRUID" then - DataToColor.S.PlayerClass = 256 - else - DataToColor.S.PlayerClass = 0 - end -end - function CreateSpellInRangeList() if DataToColor.C.CHARACTER_CLASS == "ROGUE" then DataToColor.S.spellInRangeList = { @@ -63,9 +36,10 @@ function CreateSpellInRangeList() elseif DataToColor.C.CHARACTER_CLASS == "PRIEST" then DataToColor.S.spellInRangeList = { 589, -- "Shadow Word: Pain" - 8092, -- "Mind Blast" + 5019, -- "Shoot" 15407, -- "Mind Flay" - 5019 -- "Shoot" + 8092, -- "Mind Blast" + 585 -- "Smite" } elseif DataToColor.C.CHARACTER_CLASS == "PALADIN" then DataToColor.S.spellInRangeList = { @@ -104,6 +78,7 @@ function CreatePlayerBuffList() DataToColor.S.playerBuffs[1] = { "Drink", [132794]=1, [132800]=1, [132805]=1, [132802]=1 } DataToColor.S.playerBuffs[2] = { "Well Fed", [136000]=1 } DataToColor.S.playerBuffs[3] = { "Mana Regeneration", [2]=1 } -- potion? + DataToColor.S.playerBuffs[4] = { "Clearcasting", [136170]=1 } -- Druid / Mage / Shaman if DataToColor.C.CHARACTER_CLASS == "PRIEST" then DataToColor.S.playerBuffs[10] = { "Fortitude", [135987]=1, [135941]=1 } @@ -129,6 +104,8 @@ function CreatePlayerBuffList() DataToColor.S.playerBuffs[13] = { "Ward", [135806]=1, [135850]=1 } DataToColor.S.playerBuffs[14] = { "Fire Power", [135817]=1 } -- not sure what is this DataToColor.S.playerBuffs[15] = { "Mana Shield", [136153]=1 } + DataToColor.S.playerBuffs[16] = { "Presence of Mind", [136031]=1 } + DataToColor.S.playerBuffs[17] = { "Arcane Power", [136048]=1 } elseif DataToColor.C.CHARACTER_CLASS == "ROGUE" then DataToColor.S.playerBuffs[10] = { "Slice and Dice", [132306]=1 } DataToColor.S.playerBuffs[11] = { "Stealth", [132320]=1 } @@ -143,6 +120,7 @@ function CreatePlayerBuffList() DataToColor.S.playerBuffs[10] = { "Lightning Shield", [136051]=1 } DataToColor.S.playerBuffs[11] = { "Water Shield", [132315]=1 } DataToColor.S.playerBuffs[12] = { "Focused", [136027]=1 } -- Shamanistic Focus + DataToColor.S.playerBuffs[13] = { "Stoneskin", [136098]=1 } elseif DataToColor.C.CHARACTER_CLASS == "HUNTER" then DataToColor.S.playerBuffs[10] = { "Aspect of", [136076]=1, [132159]=1, [132252]=1, [132267]=1, [132160]=1, [136074]=1 } DataToColor.S.playerBuffs[11] = { "Rapid Fire", [132208]=1 } @@ -160,9 +138,11 @@ function CreateTargetDebuffList() DataToColor.S.targetDebuffs[2] = { "Rip", [132152]=1 } DataToColor.S.targetDebuffs[3] = { "Moonfire", [136096]=1 } DataToColor.S.targetDebuffs[4] = { "Entangling Roots", [136100]=1 } + DataToColor.S.targetDebuffs[5] = { "Rake", [132122]=1 } elseif DataToColor.C.CHARACTER_CLASS == "PALADIN" then elseif DataToColor.C.CHARACTER_CLASS == "MAGE" then DataToColor.S.targetDebuffs[0] = { "Frostbite", [135842]=1 } + DataToColor.S.targetDebuffs[1] = { "Slow", [136091]=1 } elseif DataToColor.C.CHARACTER_CLASS == "ROGUE" then elseif DataToColor.C.CHARACTER_CLASS == "WARRIOR" then DataToColor.S.targetDebuffs[0] = { "Rend", [132155]=1 } diff --git a/BlazorServer/Pages/GoapGoalView.razor b/BlazorServer/Pages/GoapGoalView.razor index 45749cbe8..abe554f98 100644 --- a/BlazorServer/Pages/GoapGoalView.razor +++ b/BlazorServer/Pages/GoapGoalView.razor @@ -27,11 +27,10 @@ @if (this.goal.Keys != null) { - var lastKeyClicked = Core.KeyAction.LastKeyClicked(); - + int lastKeyClicked = Core.KeyAction.LastKeyClicked(); foreach (var key in this.goal.Keys) { - + @key.Name [@key.ConsoleKey] diff --git a/Core/Actionbar/ActionBarBits.cs b/Core/Actionbar/ActionBarBits.cs index c88e10c7f..19138335b 100644 --- a/Core/Actionbar/ActionBarBits.cs +++ b/Core/Actionbar/ActionBarBits.cs @@ -21,7 +21,7 @@ public bool Is(KeyAction item) { if (KeyReader.ActionBarSlotMap.TryGetValue(item.Key, out int slot)) { - slot += Stance.RuntimeSlotToActionBar(playerReader, slot); + slot += Stance.RuntimeSlotToActionBar(item, playerReader, slot); int array = (int)(slot / 24); return bits[array].IsBitSet((slot - 1) % 24); @@ -29,5 +29,16 @@ public bool Is(KeyAction item) return false; } + + public int Num(KeyAction item) + { + if (KeyReader.ActionBarSlotMap.TryGetValue(item.Key, out int slot)) + { + slot += Stance.RuntimeSlotToActionBar(item, playerReader, slot); + return slot; + } + + return 0; + } } } diff --git a/Core/Actionbar/ActionBarCostReader.cs b/Core/Actionbar/ActionBarCostReader.cs index 08992cd59..19ae107d5 100644 --- a/Core/Actionbar/ActionBarCostReader.cs +++ b/Core/Actionbar/ActionBarCostReader.cs @@ -62,13 +62,18 @@ public void Read() } } + public void Reset() + { + dict.Clear(); + } + public Tuple GetCostByActionBarSlot(PlayerReader playerReader, KeyAction keyAction) { if (KeyReader.ActionBarSlotMap.TryGetValue(keyAction.Key, out int slot)) { - if (keyAction.FormEnum != Form.None && slot <= 12) + if (slot <= 12) { - slot += Stance.FormToActionBar(playerReader.PlayerClass, keyAction.FormEnum); + slot += Stance.RuntimeSlotToActionBar(keyAction, playerReader, slot); } if (dict.TryGetValue(slot, out var tuple)) diff --git a/Core/ActionbarPopulator/ActionBarPopulator.cs b/Core/ActionbarPopulator/ActionBarPopulator.cs index 36e5be072..8b43aa8e1 100644 --- a/Core/ActionbarPopulator/ActionBarPopulator.cs +++ b/Core/ActionbarPopulator/ActionBarPopulator.cs @@ -7,12 +7,12 @@ namespace Core { public class ActionBarPopulator { - struct ActionBarSource { + struct ActionBarSource + { public string Name; public string Key; public bool Item; - public string Requirement; - public Form Form; + public KeyAction KeyAction; } private readonly ILogger logger; @@ -57,15 +57,14 @@ private void CollectKeyActions() private void AddUnique(KeyAction a) { if (!KeyReader.KeyMapping.ContainsKey(a.Key)) return; - if (sources.Any(i => i.Key == a.Key && i.Form == a.FormEnum)) return; + if (sources.Any(i => i.KeyAction.ConsoleKeyFormHash == a.ConsoleKeyFormHash)) return; var source = new ActionBarSource { Name = a.Name, Key = a.Key, Item = false, - Requirement = a.Requirement, - Form = a.FormEnum + KeyAction = a }; sources.Add(source); @@ -155,7 +154,7 @@ private string CalculateActionNumber(ActionBarSource a, string key, string prefi { if (offset == 0 && hotkey <= 12) { - offset += Stance.FormToActionBar(addonReader.PlayerReader.PlayerClass, a.Form); + offset += Stance.RuntimeSlotToActionBar(a.KeyAction, addonReader.PlayerReader, hotkey); } if (hotkey == 0) diff --git a/Core/Addon/AddonReader.cs b/Core/Addon/AddonReader.cs index a6657ca50..d01e481f2 100644 --- a/Core/Addon/AddonReader.cs +++ b/Core/Addon/AddonReader.cs @@ -106,6 +106,7 @@ public void Refresh() public void Reset() { PlayerReader.Initialized = false; + ActionBarCostReader.Reset(); PlayerReader.Reset(); } diff --git a/Core/Addon/AuraCount.cs b/Core/Addon/AuraCount.cs new file mode 100644 index 000000000..f8f657abc --- /dev/null +++ b/Core/Addon/AuraCount.cs @@ -0,0 +1,32 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Core +{ + public class AuraCount + { + public int Hash { private set; get; } + public int PlayerDebuff { private set; get; } + public int PlayerBuff { private set; get; } + public int TargetDebuff { private set; get; } + public int TargetBuff { private set; get; } + + public AuraCount(ISquareReader squareReader, int cell) + { + Hash = TargetBuff = (int)squareReader.GetLongAtCell(cell); + + // formula + // playerDebuffCount * 1000000 + playerBuffCount * 10000 + targetDebuffCount * 100 + targetBuffCount + + PlayerDebuff = (int)(TargetBuff / 1000000f); + TargetBuff -= 1000000 * PlayerDebuff; + + PlayerBuff = (int)(TargetBuff / 10000f); + TargetBuff -= 10000 * PlayerBuff; + + TargetDebuff = (int)(TargetBuff / 100f); + TargetBuff -= 100 * TargetDebuff; + } + } +} diff --git a/Core/Addon/BuffStatus.cs b/Core/Addon/BuffStatus.cs index 63d88842f..b8c77c976 100644 --- a/Core/Addon/BuffStatus.cs +++ b/Core/Addon/BuffStatus.cs @@ -19,6 +19,7 @@ public bool IsBitSet(int pos) public bool Drinking => IsBitSet(1); public bool WellFed => IsBitSet(2); public bool ManaRegeneration => IsBitSet(3); + public bool Clearcasting => IsBitSet(4); // Priest public bool Fortitude => IsBitSet(10); @@ -47,6 +48,8 @@ public bool IsBitSet(int pos) public bool Ward => IsBitSet(13); public bool FirePower => IsBitSet(14); public bool ManaShield => IsBitSet(15); + public bool PresenceOfMind => IsBitSet(16); + public bool ArcanePower => IsBitSet(17); // Rogue public bool SliceAndDice => IsBitSet(10); @@ -65,6 +68,7 @@ public bool IsBitSet(int pos) public bool LightningShield => IsBitSet(10); public bool WaterShield => IsBitSet(11); public bool ShamanisticFocus => IsBitSet(12); + public bool Stoneskin => IsBitSet(13); // Hunter public bool Aspect => IsBitSet(10); //Any Aspect of diff --git a/Core/Addon/DeBuffStatus.cs b/Core/Addon/DeBuffStatus.cs index 55714d55b..3a4b3e11c 100644 --- a/Core/Addon/DeBuffStatus.cs +++ b/Core/Addon/DeBuffStatus.cs @@ -31,11 +31,13 @@ public bool IsBitSet(int pos) public bool Rip => IsBitSet(2); public bool Moonfire => IsBitSet(3); public bool EntanglingRoots => IsBitSet(4); + public bool Rake => IsBitSet(5); // Paladin // Mage public bool Frostbite => IsBitSet(0); + public bool Slow => IsBitSet(1); // Rogue diff --git a/Core/Addon/PlayerClassEnum.cs b/Core/Addon/PlayerClassEnum.cs index 69e700cba..e3d5e707c 100644 --- a/Core/Addon/PlayerClassEnum.cs +++ b/Core/Addon/PlayerClassEnum.cs @@ -2,14 +2,18 @@ { public enum PlayerClassEnum { - Druid = 256, - Mage = 128, - Rogue = 64, - Warrior = 32, - Paladin = 16, - Hunter = 8, - Priest = 4, - Shaman = 2, - Warlock = 1 + None, + Warrior, + Paladin, + Hunter, + Rogue, + Priest, + Death_Knight, + Shaman, + Mage, + Warlock, + Monk, + Druid, + Demon_Hunter } } \ No newline at end of file diff --git a/Core/Addon/PlayerReader.cs b/Core/Addon/PlayerReader.cs index d55a679ff..dcf326e37 100644 --- a/Core/Addon/PlayerReader.cs +++ b/Core/Addon/PlayerReader.cs @@ -113,7 +113,9 @@ public string Target public long Gold => reader.GetLongAtCell(44) + (reader.GetLongAtCell(45) * 1000000); - public PlayerClassEnum PlayerClass => (PlayerClassEnum)reader.GetLongAtCell(46); + public RaceEnum PlayerRace => (RaceEnum)(int)(reader.GetLongAtCell(46) / 100f); + + public PlayerClassEnum PlayerClass => (PlayerClassEnum)(int)(reader.GetLongAtCell(46) - ((int)PlayerRace * 100f)); public bool Unskinnable => reader.GetLongAtCell(47) != 0; // Returns 1 if creature is unskinnable @@ -142,7 +144,14 @@ public string Target public long SpellBeingCast => reader.GetLongAtCell(53); public long ComboPoints => reader.GetLongAtCell(54); - public long PlayerDebuffCount => reader.GetLongAtCell(55); + public AuraCount AuraCount => new AuraCount(reader, 55); + + public int PlayerDebuffCount => AuraCount.PlayerDebuff; + public int PlayerBuffCount => AuraCount.PlayerBuff; + + public int TargetBuffCount => AuraCount.TargetBuff; + public int TargetDebuffCount => AuraCount.TargetDebuff; + public int TargetId => (int)reader.GetLongAtCell(56); public long TargetGuid => reader.GetLongAtCell(57); @@ -156,6 +165,8 @@ public string Target public RecordInt AutoShot = new RecordInt(60); public RecordInt MainHandSwing = new RecordInt(61); + public RecordInt CastEvent = new RecordInt(62); + public RecordInt CastSpellId = new RecordInt(63); public RecordInt CombatCreatureGuid = new RecordInt(64); public RecordInt CombatDamageDoneGuid = new RecordInt(65); @@ -166,8 +177,11 @@ public string Target public int PetTargetGuid => (int)reader.GetLongAtCell(69); public bool PetHasTarget => PetTargetGuid != 0; - public RecordInt GlobalTime = new RecordInt(70); - public long LastLootTime => reader.GetLongAtCell(71); + public int CastCount => (int)reader.GetLongAtCell(70); + + public long LastLootTime => reader.GetLongAtCell(97); + + public RecordInt GlobalTime = new RecordInt(98); // https://wowpedia.fandom.com/wiki/Mob_experience public bool TargetYieldXP => PlayerLevel switch @@ -278,21 +292,25 @@ internal void Updated() Reset(); } + if (UIErrorMessage > 0) + { + LastUIErrorMessage = (UI_ERROR)UIErrorMessage; + } + UIMapId.Update(reader); AutoShot.Update(reader); MainHandSwing.Update(reader); + CastEvent.Update(reader); + CastSpellId.Update(reader); UpdateCreatureLists(); - - if (UIErrorMessage > 0) - { - LastUIErrorMessage = (UI_ERROR)UIErrorMessage; - } } internal void Reset() { + FormCost.Clear(); + // Reset all CreatureHistory Creatures.Clear(); DamageTaken.Clear(); @@ -305,6 +323,8 @@ internal void Reset() AutoShot.Reset(); MainHandSwing.Reset(); + CastEvent.Reset(); + CastSpellId.Reset(); CombatCreatureGuid.Reset(); CombatDamageDoneGuid.Reset(); diff --git a/Core/Addon/RaceEnum.cs b/Core/Addon/RaceEnum.cs new file mode 100644 index 000000000..d05640aea --- /dev/null +++ b/Core/Addon/RaceEnum.cs @@ -0,0 +1,18 @@ +namespace Core +{ + public enum RaceEnum + { + None, + Human, + Orc, + Dwarf, + NightElf, + Undead, + Tauren, + Gnome, + Troll, + Goblin, + BloodElf, + Draenei + } +} \ No newline at end of file diff --git a/Core/Addon/RecordInt.cs b/Core/Addon/RecordInt.cs index a9dde119f..e5bda91b2 100644 --- a/Core/Addon/RecordInt.cs +++ b/Core/Addon/RecordInt.cs @@ -49,5 +49,10 @@ public void Reset() Value = 0; temp = 0; } + + public void ForceUpdate(int value) + { + Value = value; + } } } \ No newline at end of file diff --git a/Core/Addon/SpellInRange.cs b/Core/Addon/SpellInRange.cs index fd20486f9..c91a16beb 100644 --- a/Core/Addon/SpellInRange.cs +++ b/Core/Addon/SpellInRange.cs @@ -28,10 +28,10 @@ public bool IsBitSet(int pos) // Priest public bool Priest_ShadowWordPain => IsBitSet(0); - - public bool Priest_MindBlast => IsBitSet(1); + public bool Priest_Shoot => IsBitSet(1); public bool Priest_MindFlay => IsBitSet(2); - public bool Priest_Shoot => IsBitSet(3); + public bool Priest_MindBlast => IsBitSet(3); + public bool Priest_Smite => IsBitSet(4); // Druid public bool Druid_Wrath => IsBitSet(0); @@ -66,8 +66,8 @@ public bool IsBitSet(int pos) { PlayerClassEnum.Warrior => (playerReader.PlayerLevel >= 4 && Warrior_Charge) || playerReader.IsInMeleeRange, PlayerClassEnum.Rogue => Rogue_Throw, - PlayerClassEnum.Priest => Priest_ShadowWordPain, - PlayerClassEnum.Druid => playerReader.Form == Form.Druid_Bear ? Druid_Maul : playerReader.Form == Form.Druid_Cat ? Druid_Rip : Druid_Wrath, + PlayerClassEnum.Priest => Priest_Smite, + PlayerClassEnum.Druid => Druid_Wrath, PlayerClassEnum.Paladin => (playerReader.PlayerLevel >= 4 && Paladin_Judgement) || playerReader.IsInMeleeRange, PlayerClassEnum.Mage => (playerReader.PlayerLevel >= 4 && Mage_Frostbolt) || Mage_Fireball, PlayerClassEnum.Hunter => (playerReader.PlayerLevel >=4 && Hunter_SerpentSting) || Hunter_AutoShoot, @@ -80,8 +80,8 @@ public bool IsBitSet(int pos) { PlayerClassEnum.Warrior => (playerReader.PlayerLevel >= 4 && Warrior_Rend) || playerReader.IsInMeleeRange, PlayerClassEnum.Rogue => Rogue_SinisterStrike, - PlayerClassEnum.Priest => Priest_Shoot, - PlayerClassEnum.Druid => playerReader.Form == Form.Druid_Bear ? Druid_Maul : playerReader.Form == Form.Druid_Cat ? Druid_Rip : Druid_Wrath, + PlayerClassEnum.Priest => Priest_Smite, + PlayerClassEnum.Druid => Druid_Wrath || playerReader.IsInMeleeRange, PlayerClassEnum.Paladin => (playerReader.PlayerLevel >= 4 && Paladin_Judgement) || playerReader.IsInMeleeRange, PlayerClassEnum.Mage => Mage_Frostbolt || Mage_Fireball, PlayerClassEnum.Hunter => (playerReader.PlayerLevel >= 4 && Hunter_SerpentSting) || Hunter_AutoShoot || playerReader.IsInMeleeRange, diff --git a/Core/Addon/Stance.cs b/Core/Addon/Stance.cs index 3238b234a..e50c2d442 100644 --- a/Core/Addon/Stance.cs +++ b/Core/Addon/Stance.cs @@ -68,15 +68,17 @@ public Stance(long value) _ => Form.None }; - public static int RuntimeSlotToActionBar(PlayerReader playerReader, int slot) + public static int RuntimeSlotToActionBar(KeyAction item, PlayerReader playerReader, int slot) { - if (slot > 12 || playerReader.Form == Form.None) - return 0; + if (slot <= 12) + { + return FormToActionBar(playerReader.PlayerClass, item.HasFormRequirement() ? item.FormEnum : playerReader.Form); + } - return FormToActionBar(playerReader.PlayerClass, playerReader.Form); + return 0; } - public static int FormToActionBar(PlayerClassEnum playerClass, Form form) + private static int FormToActionBar(PlayerClassEnum playerClass, Form form) { switch (playerClass) { diff --git a/Core/Addon/UI_ERROR.cs b/Core/Addon/UI_ERROR.cs index 8f0f61a58..b8c0426f2 100644 --- a/Core/Addon/UI_ERROR.cs +++ b/Core/Addon/UI_ERROR.cs @@ -11,6 +11,13 @@ public enum UI_ERROR SPELL_FAILED_MOVING = 6, ERR_SPELL_COOLDOWN = 7, ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS = 8, - ERR_SPELL_FAILED_STUNNED = 9 + ERR_SPELL_FAILED_STUNNED = 9, + ERR_SPELL_FAILED_INTERRUPTED = 10, + SPELL_FAILED_ITEM_NOT_READY = 11, + + MAX_ERROR_RANGE = 2000, + + CAST_START = 999998, + CAST_SUCCESS = 999999 } } \ No newline at end of file diff --git a/Core/Blacklist/Blacklist.cs b/Core/Blacklist/Blacklist.cs index b08fd720c..600f6ec60 100644 --- a/Core/Blacklist/Blacklist.cs +++ b/Core/Blacklist/Blacklist.cs @@ -43,6 +43,10 @@ public bool IsTargetBlacklisted() LastWarningTargetGuid = 0; return false; } + else if (playerReader.DamageTaken.Exists(x => x.LastKnownHealthPercent > 0 && x.CreatureId == playerReader.TargetGuid)) + { + return false; + } if(this.playerReader.PetHasTarget && this.playerReader.TargetGuid == playerReader.PetGuid) diff --git a/Core/BotController.cs b/Core/BotController.cs index 2f2ed4fba..f0ceecdab 100644 --- a/Core/BotController.cs +++ b/Core/BotController.cs @@ -127,7 +127,7 @@ public BotController(ILogger logger, IPPather pather, DataConfig dataConfig, ICo Thread.Sleep(100); } - logger.LogDebug($"Woohoo, I have read the player class. You are a {AddonReader.PlayerReader.PlayerClass}."); + logger.LogDebug($"Woohoo, I have read the player class. You are a {AddonReader.PlayerReader.PlayerRace} {AddonReader.PlayerReader.PlayerClass}."); npcNameFinder = new NpcNameFinder(logger, WowScreen); npcNameTargeting = new NpcNameTargeting(logger, npcNameFinder, WowProcessInput); diff --git a/Core/ClassConfig/ClassConfiguration.cs b/Core/ClassConfig/ClassConfiguration.cs index f5caeec1a..61766fde0 100644 --- a/Core/ClassConfig/ClassConfiguration.cs +++ b/Core/ClassConfig/ClassConfiguration.cs @@ -104,12 +104,15 @@ public void Initialise(DataConfig dataConfig, AddonReader addonReader, Requireme Interact.Name = "Interact"; Interact.WaitForGCD = false; Interact.DelayAfterCast = 0; + Interact.PressDuration = 30; Interact.Initialise(addonReader, requirementFactory, logger); Approach.Key = InteractKey; Approach.Name = "Approach"; Approach.WaitForGCD = false; Approach.DelayAfterCast = 0; + Approach.PressDuration = 10; + Approach.Cooldown = 150; Approach.Initialise(addonReader, requirementFactory, logger); AutoAttack.Key = InteractKey; @@ -118,15 +121,19 @@ public void Initialise(DataConfig dataConfig, AddonReader addonReader, Requireme AutoAttack.DelayAfterCast = 0; AutoAttack.Initialise(addonReader, requirementFactory, logger); + StopAttack.PressDuration = 10; + InitializeKeyActions(Pull, Interact, Approach, AutoAttack); InitializeKeyActions(Combat, Interact, Approach, AutoAttack); + logger.LogInformation("[Form] Initialise KeyActions."); Form.ForEach(i => i.InitialiseForm(addonReader, requirementFactory, logger)); - Pull.Initialise(addonReader, requirementFactory, logger); - Combat.Initialise(addonReader, requirementFactory, logger); - Adhoc.Initialise(addonReader, requirementFactory, logger); - NPC.Initialise(addonReader, requirementFactory, logger); - Parallel.Initialise(addonReader, requirementFactory, logger); + + Pull.Initialise("Pull", addonReader, requirementFactory, logger); + Combat.Initialise("Combat", addonReader, requirementFactory, logger); + Adhoc.Initialise("Adhoc", addonReader, requirementFactory, logger); + NPC.Initialise("AdhocNpc", addonReader, requirementFactory, logger); + Parallel.Initialise("Parallel", addonReader, requirementFactory, logger); Jump.Key = JumpKey; Jump.Initialise(addonReader, requirementFactory, logger); @@ -153,6 +160,7 @@ public void Initialise(DataConfig dataConfig, AddonReader addonReader, Requireme TargetTargetOfTarget.Initialise(addonReader, requirementFactory, logger); PetAttack.Key = PetAttackKey; + PetAttack.PressDuration = 10; PetAttack.Initialise(addonReader, requirementFactory, logger); Mount.Key = MountKey; @@ -191,6 +199,8 @@ private static void InitializeKeyActions(KeyActions keyActions, params KeyAction a.Key = l.Key; a.DelayAfterCast = l.DelayAfterCast; a.WaitForGCD = l.WaitForGCD; + a.PressDuration = l.PressDuration; + a.Cooldown = l.Cooldown; } }); }); diff --git a/Core/ClassConfig/KeyAction.cs b/Core/ClassConfig/KeyAction.cs index 075634ebe..926a95bac 100644 --- a/Core/ClassConfig/KeyAction.cs +++ b/Core/ClassConfig/KeyAction.cs @@ -60,16 +60,16 @@ public class KeyAction public List RequirementObjects { get; } = new List(); - protected static ConcurrentDictionary LastClicked { get; } = new ConcurrentDictionary(); + public int ConsoleKeyFormHash; - public static ConsoleKey LastKeyClicked() - { - if (!LastClicked.Any()) { return ConsoleKey.NoName; } + protected static ConcurrentDictionary LastClicked { get; } = new ConcurrentDictionary(); - var last = LastClicked.OrderByDescending(s => s.Value).First(); - if ( (DateTime.Now- last.Value).TotalSeconds>2) + public static int LastKeyClicked() + { + var last = LastClicked.OrderByDescending(s => s.Value).FirstOrDefault(); + if (last.Key == 0 || (DateTime.Now - last.Value).TotalSeconds > 2) { - return ConsoleKey.NoName; + return (int)ConsoleKey.NoName; } return last.Key; } @@ -92,7 +92,7 @@ public void Initialise(AddonReader addonReader, RequirementFactory requirementFa Requirements.Add(this.Requirement); } - if (!string.IsNullOrEmpty(Form)) + if (HasFormRequirement()) { if (Enum.TryParse(typeof(Form), Form, out var desiredForm)) { @@ -101,7 +101,7 @@ public void Initialise(AddonReader addonReader, RequirementFactory requirementFa if (KeyReader.ActionBarSlotMap.TryGetValue(Key, out int slot)) { - int offset = Stance.FormToActionBar(playerReader.PlayerClass, FormEnum); + int offset = Stance.RuntimeSlotToActionBar(this, playerReader, slot); this.logger.LogInformation($"[{Name}] Actionbar Form key map: Key:{Key} -> Actionbar:{slot} -> Form Map:{slot + offset}"); } } @@ -111,6 +111,8 @@ public void Initialise(AddonReader addonReader, RequirementFactory requirementFa } } + ConsoleKeyFormHash = ((int)FormEnum * 1000) + (int)ConsoleKey; + UpdateMinResourceRequirement(playerReader, addonReader.ActionBarCostReader); requirementFactory.InitialiseRequirements(this); @@ -120,7 +122,7 @@ public void InitialiseForm(AddonReader addonReader, RequirementFactory requireme { Initialise(addonReader, requirementFactory, logger); - if (!string.IsNullOrEmpty(Form)) + if (HasFormRequirement()) { if (addonReader.PlayerReader.FormCost.ContainsKey(FormEnum)) { @@ -128,7 +130,7 @@ public void InitialiseForm(AddonReader addonReader, RequirementFactory requireme } addonReader.PlayerReader.FormCost.Add(FormEnum, MinMana); - LogInformation($"Added {FormEnum} to FormCost with {MinMana}"); + logger.LogInformation($"[{Name}] Added {FormEnum} to FormCost with {MinMana}"); } } @@ -139,7 +141,7 @@ public void CreateCooldownRequirement() this.RequirementObjects.Add(new Requirement { HasRequirement = () => GetCooldownRemaining() == 0, - LogMessage = () => $"Cooldown {GetCooldownRemaining()}", + LogMessage = () => $"Cooldown {GetCooldownRemaining() / 1000:F1}", VisibleIfHasRequirement = false }); } @@ -149,12 +151,12 @@ public float GetCooldownRemaining() { try { - if (!LastClicked.ContainsKey(this.ConsoleKey)) + if (!LastClicked.ContainsKey(ConsoleKeyFormHash)) { return 0; } - var remaining = this.Cooldown - ((int)(DateTime.Now - LastClicked[this.ConsoleKey]).TotalSeconds); + var remaining = Cooldown - (float)(DateTime.Now - LastClicked[ConsoleKeyFormHash]).TotalMilliseconds; return remaining < 0 ? 0 : remaining; } @@ -165,6 +167,12 @@ public float GetCooldownRemaining() } } + public bool CanDoFormChangeAndHaveMinimumMana() + { + return playerReader != null && + (playerReader.FormCost.ContainsKey(FormEnum) && playerReader.ManaCurrent >= playerReader.FormCost[FormEnum] + MinMana); + } + internal void SetClicked() { try @@ -174,13 +182,13 @@ internal void SetClicked() LastClickPostion = this.playerReader.PlayerLocation; } - if (LastClicked.ContainsKey(this.ConsoleKey)) + if (LastClicked.ContainsKey(ConsoleKeyFormHash)) { - LastClicked[this.ConsoleKey] = DateTime.Now; + LastClicked[ConsoleKeyFormHash] = DateTime.Now; } else { - LastClicked.TryAdd(this.ConsoleKey, DateTime.Now); + LastClicked.TryAdd(ConsoleKeyFormHash, DateTime.Now); } } catch (Exception ex) @@ -189,14 +197,11 @@ internal void SetClicked() } } - public double MillisecondsSinceLastClick => LastClicked.ContainsKey(this.ConsoleKey) ? (DateTime.Now - LastClicked[this.ConsoleKey]).TotalMilliseconds : double.MaxValue; + public double MillisecondsSinceLastClick => LastClicked.ContainsKey(ConsoleKeyFormHash) ? (DateTime.Now - LastClicked[ConsoleKeyFormHash]).TotalMilliseconds : double.MaxValue; internal void ResetCooldown() { - if (LastClicked.ContainsKey(ConsoleKey)) - { - LastClicked.TryRemove(ConsoleKey, out _); - } + LastClicked.TryRemove(ConsoleKeyFormHash, out _); } public void CreateChargeRequirement() @@ -244,6 +249,11 @@ public bool CanRun() return !this.RequirementObjects.Any(r => !r.HasRequirement()); } + public bool HasFormRequirement() + { + return !string.IsNullOrEmpty(Form); + } + private void UpdateMinResourceRequirement(PlayerReader playerReader, ActionBarCostReader actionBarCostReader) { var tuple = actionBarCostReader.GetCostByActionBarSlot(playerReader, this); @@ -266,7 +276,13 @@ private void UpdateMinResourceRequirement(PlayerReader playerReader, ActionBarCo break; } - logger.LogInformation($"[{Name}] Update {tuple.Item1} cost to {tuple.Item2} from {oldValue}"); + int formCost = 0; + if (HasFormRequirement() && FormEnum != Core.Form.None && playerReader.FormCost.ContainsKey(FormEnum)) + { + formCost = playerReader.FormCost[FormEnum]; + } + + logger.LogInformation($"[{Name}] Update {tuple.Item1} cost to {tuple.Item2} from {oldValue}" + (formCost > 0 ? $" +{formCost} Mana to change {FormEnum} Form" : "")); } } diff --git a/Core/ClassConfig/KeyActions.cs b/Core/ClassConfig/KeyActions.cs index a5ec37238..29ef1ce6f 100644 --- a/Core/ClassConfig/KeyActions.cs +++ b/Core/ClassConfig/KeyActions.cs @@ -7,8 +7,13 @@ public class KeyActions { public List Sequence { get; } = new List(); - public void Initialise(AddonReader addonReader, RequirementFactory requirementFactory, ILogger logger) + public void Initialise(string prefix, AddonReader addonReader, RequirementFactory requirementFactory, ILogger logger) { + if (Sequence.Count > 0) + { + logger.LogInformation($"[{prefix}] Initialise KeyActions."); + } + Sequence.ForEach(i => i.Initialise(addonReader, requirementFactory, logger)); } } diff --git a/Core/Goals/ApproachTargetGoal.cs b/Core/Goals/ApproachTargetGoal.cs index 22785ad53..9f8b75591 100644 --- a/Core/Goals/ApproachTargetGoal.cs +++ b/Core/Goals/ApproachTargetGoal.cs @@ -82,6 +82,7 @@ public override async Task OnEnter() public override async Task PerformAction() { lastPlayerLocation = playerReader.PlayerLocation; + await wait.Update(1); if (!playerReader.PlayerBitValues.PlayerInCombat) { @@ -110,12 +111,14 @@ public override async Task PerformAction() playerWasInCombat = true; } - await input.TapInteractKey(""); - await wait.Update(1); + if (input.ClassConfig.Approach.GetCooldownRemaining() == 0) + { + await input.TapApproachKey(""); + } lastPlayerDistance = WowPoint.DistanceTo(lastPlayerLocation, playerReader.PlayerLocation); - if (lastPlayerDistance < 0.5 && playerReader.LastUIErrorMessage == UI_ERROR.ERR_AUTOFOLLOW_TOO_FAR) + if (lastPlayerDistance < 0.05 && playerReader.LastUIErrorMessage == UI_ERROR.ERR_AUTOFOLLOW_TOO_FAR) { playerReader.LastUIErrorMessage = UI_ERROR.NONE; @@ -123,11 +126,11 @@ public override async Task PerformAction() await wait.Update(1); } - if (SecondsSinceApproachStarted > 1 && lastPlayerDistance < 0.5 && !playerReader.PlayerBitValues.PlayerInCombat) + if (SecondsSinceApproachStarted > 1 && lastPlayerDistance < 0.05 && !playerReader.PlayerBitValues.PlayerInCombat) { await input.TapClearTarget(""); await wait.Update(1); - await input.KeyPress(random.Next(2) == 0 ? ConsoleKey.LeftArrow : ConsoleKey.RightArrow, 1000, "Seems stuck! Clear Target. Turn away."); + await input.KeyPress(random.Next(2) == 0 ? ConsoleKey.LeftArrow : ConsoleKey.RightArrow, 1000, $"Seems stuck! Clear Target. Turn away. d: {lastPlayerDistance}"); approachStart = DateTime.Now; } diff --git a/Core/Goals/CastingHandler.cs b/Core/Goals/CastingHandler.cs index f97f1f278..a35f80317 100644 --- a/Core/Goals/CastingHandler.cs +++ b/Core/Goals/CastingHandler.cs @@ -21,11 +21,14 @@ public class CastingHandler private readonly StopMoving stopMoving; private readonly KeyAction defaultKeyAction = new KeyAction(); - private const int MaxWaitCastTimeMs = 500; - private const int MaxWaitBuffTimeMs = 500; + + private const int GCD = 1500; + private const int SpellQueueTimeMs = 325; + + private const int MaxWaitCastTimeMs = GCD; + private const int MaxWaitBuffTimeMs = GCD; private const int MaxCastTimeMs = 15000; private const int MaxSwingTimeMs = 4000; - private const int GCD = 1500; private const int MaxAirTimeMs = 10000; public CastingHandler(ILogger logger, ConfigurableInput input, Wait wait, PlayerReader playerReader, ClassConfiguration classConfig, IPlayerDirection direction, NpcNameFinder npcNameFinder, StopMoving stopMoving) @@ -49,9 +52,13 @@ protected bool CanRun(KeyAction item) var needAdds = bool.Parse(item.CastIfAddsVisible); if (needAdds != npcNameFinder.PotentialAddsExist) { - item.LogInformation($"Only cast if adds exist = {item.CastIfAddsVisible} and it is {npcNameFinder.PotentialAddsExist}"); + item.LogInformation($"Only cast if adds exist = {item.CastIfAddsVisible} and it is {npcNameFinder.PotentialAddsExist} - Targets:{npcNameFinder.TargetCount} - Adds:{npcNameFinder.AddCount}"); return false; } + else + { + item.LogInformation($"Only cast if adds exist = {item.CastIfAddsVisible} and it is {npcNameFinder.PotentialAddsExist} - Targets:{npcNameFinder.TargetCount} - Adds:{npcNameFinder.AddCount}"); + } } if(item.School != SchoolMask.None) @@ -95,22 +102,56 @@ private async Task PressKeyAction(KeyAction item) item.SetClicked(); } + private static bool CastSuccessfull(UI_ERROR uiEvent) + { + return + uiEvent == UI_ERROR.CAST_START || + uiEvent == UI_ERROR.CAST_SUCCESS || + uiEvent == UI_ERROR.NONE; + } + private async Task CastInstant(KeyAction item) { if (item.StopBeforeCast) { await stopMoving.Stop(); + await wait.Update(1); } - float minRange = playerReader.MinRange; + playerReader.CastEvent.ForceUpdate(0); + int beforeCastEventValue = playerReader.CastEvent.Value; + int beforeSpellId = playerReader.CastSpellId.Value; + bool beforeUsable = playerReader.UsableAction.Is(item); await PressKeyAction(item); - (bool input, double inputElapsedMs) = await wait.InterruptTask(item.AfterCastWaitNextSwing ? MaxSwingTimeMs : MaxWaitCastTimeMs, - () => playerReader.LastUIErrorMessage != UI_ERROR.NONE || !playerReader.CurrentAction.Is(item) || minRange != playerReader.MinRange); - if (!input) + bool inputNotHappened; + double inputElapsedMs; + + if (item.AfterCastWaitNextSwing) + { + (inputNotHappened, inputElapsedMs) = await wait.InterruptTask(MaxSwingTimeMs, + interrupt: () => !playerReader.CurrentAction.Is(item), + repeat: async () => + { + if (classConfig.Approach.GetCooldownRemaining() == 0) + { + await input.TapApproachKey(""); + } + }); + } + else + { + (inputNotHappened, inputElapsedMs) = await wait.InterruptTask(MaxWaitCastTimeMs, + interrupt: () => + (beforeSpellId != playerReader.CastSpellId.Value && beforeCastEventValue != playerReader.CastEvent.Value) || + beforeUsable != playerReader.UsableAction.Is(item) + ); + } + + if (!inputNotHappened) { - item.LogInformation($" ... instant input after {inputElapsedMs}ms"); + item.LogInformation($" ... instant input {inputElapsedMs}ms"); } else { @@ -118,34 +159,27 @@ private async Task CastInstant(KeyAction item) return false; } - item.LogInformation($" ... usable: {playerReader.UsableAction.Is(item)} -- {playerReader.LastUIErrorMessage}"); + item.LogInformation($" ... usable: {beforeUsable}->{playerReader.UsableAction.Is(item)} -- ({(UI_ERROR)beforeCastEventValue}->{(UI_ERROR)playerReader.CastEvent.Value})"); - if (playerReader.LastUIErrorMessage != UI_ERROR.NONE) + if (!CastSuccessfull((UI_ERROR)playerReader.CastEvent.Value) || !(beforeUsable && !playerReader.UsableAction.Is(item))) { - if (playerReader.LastUIErrorMessage == UI_ERROR.ERR_SPELL_COOLDOWN) - { - item.LogInformation($" ... instant wait until its ready"); - bool before = playerReader.UsableAction.Is(item); - await wait.While(() => before != playerReader.UsableAction.Is(item)); - } - else - { - await ReactToLastUIErrorMessage($"{item.Name}-{GetType().Name}: CastInstant"); - } - + await ReactToLastCastingEvent(item, $"{item.Name}-{GetType().Name}: CastInstant"); return false; } + if (item.RequirementObjects.Any()) + { + (bool firstReq, double firstReqElapsedMs) = await wait.InterruptTask(SpellQueueTimeMs, + () => !item.CanRun() + ); + item.LogInformation($" ... instant interrupt: {!firstReq} | CanRun:{item.CanRun()} | Delay: {firstReqElapsedMs}ms"); + } + return true; } private async Task CastCastbar(KeyAction item) { - if (item.StopBeforeCast) - { - await stopMoving.Stop(); - } - if (playerReader.PlayerBitValues.IsFalling) { (bool notfalling, double fallingElapsedMs) = await wait.InterruptTask(MaxAirTimeMs, () => !playerReader.PlayerBitValues.IsFalling); @@ -155,15 +189,28 @@ private async Task CastCastbar(KeyAction item) } } + await stopMoving.Stop(); + await wait.Update(1); + bool beforeHasTarget = playerReader.HasTarget; + bool beforeUsable = playerReader.UsableAction.Is(item); + int beforeCastEventValue = playerReader.CastEvent.Value; + int beforeSpellId = playerReader.CastSpellId.Value; + int beforeCastCount = playerReader.CastCount; + await PressKeyAction(item); (bool input, double inputElapsedMs) = await wait.InterruptTask(MaxWaitCastTimeMs, - () => playerReader.IsCasting || playerReader.LastUIErrorMessage != UI_ERROR.NONE); + interrupt: () => + beforeCastEventValue != playerReader.CastEvent.Value || + beforeSpellId != playerReader.CastSpellId.Value || + beforeCastCount != playerReader.CastCount + ); + if (!input) { - item.LogInformation($" ... castbar input after {inputElapsedMs}ms"); + item.LogInformation($" ... castbar input {inputElapsedMs}ms"); } else { @@ -171,26 +218,25 @@ private async Task CastCastbar(KeyAction item) return false; } - item.LogInformation($" ... usable: {playerReader.UsableAction.Is(item)} -- {playerReader.LastUIErrorMessage}"); + item.LogInformation($" ... casting: {playerReader.IsCasting} -- count:{playerReader.CastCount} -- usable: {beforeUsable}->{playerReader.UsableAction.Is(item)} -- {(UI_ERROR)beforeCastEventValue}->{(UI_ERROR)playerReader.CastEvent.Value}"); - if (playerReader.LastUIErrorMessage != UI_ERROR.NONE) + if (!CastSuccessfull((UI_ERROR)playerReader.CastEvent.Value)) { - if (playerReader.LastUIErrorMessage == UI_ERROR.ERR_SPELL_COOLDOWN) - { - item.LogInformation($" ... castbar wait until its ready"); - bool before = playerReader.UsableAction.Is(item); - await wait.While(() => before != playerReader.UsableAction.Is(item)); - } - else - { - await ReactToLastUIErrorMessage($"{item.Name}-{GetType().Name}: CastCastbar"); - } - + await ReactToLastCastingEvent(item, $"{item.Name}-{GetType().Name}: CastCastbar"); return false; } - item.LogInformation(" ... waiting for cast bar to end or target loss."); - await wait.InterruptTask(MaxCastTimeMs, () => !playerReader.IsCasting || beforeHasTarget != playerReader.HasTarget); + if (playerReader.IsCasting) + { + item.LogInformation(" ... waiting for visible cast bar to end or target loss."); + await wait.InterruptTask(MaxCastTimeMs, () => !playerReader.IsCasting || beforeHasTarget != playerReader.HasTarget); + } + else if ((UI_ERROR)playerReader.CastEvent.Value == UI_ERROR.CAST_START) + { + beforeCastEventValue = playerReader.CastEvent.Value; + item.LogInformation(" ... waiting for hidden cast bar to end or target loss."); + await wait.InterruptTask(MaxCastTimeMs, () => beforeCastEventValue != playerReader.CastEvent.Value || beforeHasTarget != playerReader.HasTarget); + } return true; } @@ -207,14 +253,33 @@ public async Task CastIfReady(KeyAction item, int sleepBeforeCast = 0) return false; } - if (!await SwitchToCorrectStanceForm(item)) + if (item.Name == classConfig.Approach.Name || + item.Name == classConfig.AutoAttack.Name || + item.Name == classConfig.Interact.Name) + { + await PressKeyAction(item); + return true; + } + + bool beforeUsable = playerReader.UsableAction.Is(item); + var beforeForm = playerReader.Form; + + if (!await SwitchToCorrectStanceForm(beforeForm, item)) { return false; } + if (beforeForm != playerReader.Form && !beforeUsable && !playerReader.UsableAction.Is(item)) + { + item.LogInformation(" ... after Form switch still not usable!"); + return false; + } + if (playerReader.IsShooting) { await input.TapStopAttack("Stop AutoRepeat Shoot"); + await input.TapStopAttack("Stop AutoRepeat Shoot"); + await wait.Update(1); (bool interrupted, double elapsedMs) = await wait.InterruptTask(GCD, () => playerReader.UsableAction.Is(item)); @@ -227,31 +292,25 @@ public async Task CastIfReady(KeyAction item, int sleepBeforeCast = 0) if (sleepBeforeCast > 0) { + if (item.StopBeforeCast || item.HasCastBar) + { + await stopMoving.Stop(); + await wait.Update(1); + await stopMoving.Stop(); + await wait.Update(1); + } + item.LogInformation($" Wait {sleepBeforeCast}ms before press."); await Task.Delay(sleepBeforeCast); } - long beforeBuff = playerReader.Buffs.Value; bool beforeHasTarget = playerReader.HasTarget; + int auraHash = playerReader.AuraCount.Hash; - if (item.WaitForGCD) - { - (bool gcd, double gcdElapsedMs) = await wait.InterruptTask(GCD, - () => playerReader.UsableAction.Is(item) || beforeHasTarget != playerReader.HasTarget); - if (!gcd) - { - item.LogInformation($" ... gcd interrupted {gcdElapsedMs}ms"); - if (beforeHasTarget != playerReader.HasTarget) - { - item.LogInformation($" ... lost target!"); - return false; - } - } - else - { - item.LogInformation($" ... gcd fully waited {gcdElapsedMs}ms"); - } + if (!await WaitForGCD(item, beforeHasTarget)) + { + return false; } if (!item.HasCastBar) @@ -279,11 +338,8 @@ public async Task CastIfReady(KeyAction item, int sleepBeforeCast = 0) if (item.AfterCastWaitBuff) { - (bool notappeared, double elapsedMs) = await wait.InterruptTask(MaxWaitBuffTimeMs, () => beforeBuff != playerReader.Buffs.Value); - if (!notappeared) - logger.LogInformation($" ... AfterCastWaitBuff: Buff: {!notappeared} | Delay: {elapsedMs}ms"); - else - logger.LogInformation($" ... AfterCastWaitBuff: No buff | Delay: {elapsedMs}ms"); + (bool notappeared, double elapsedMs) = await wait.InterruptTask(MaxWaitBuffTimeMs, () => auraHash != playerReader.AuraCount.Hash); + item.LogInformation($" ... AfterCastWaitBuff: Buff: {!notappeared} | pb: {playerReader.AuraCount.PlayerBuff} | pd: {playerReader.AuraCount.PlayerDebuff} | tb: {playerReader.AuraCount.TargetBuff} | td: {playerReader.AuraCount.TargetDebuff} | Delay: {elapsedMs}ms"); } if (item.DelayAfterCast != defaultKeyAction.DelayAfterCast) @@ -339,7 +395,32 @@ public async Task CastIfReady(KeyAction item, int sleepBeforeCast = 0) return true; } - protected async Task SwitchToCorrectStanceForm(KeyAction item) + private async Task WaitForGCD(KeyAction item, bool beforeHasTarget) + { + if (item.WaitForGCD) + { + (bool gcd, double gcdElapsedMs) = await wait.InterruptTask(GCD, + () => playerReader.UsableAction.Is(item) || beforeHasTarget != playerReader.HasTarget); + if (!gcd) + { + item.LogInformation($" ... gcd interrupted {gcdElapsedMs}ms"); + + if (beforeHasTarget != playerReader.HasTarget) + { + item.LogInformation($" ... lost target!"); + return false; + } + } + else + { + item.LogInformation($" ... gcd fully waited {gcdElapsedMs}ms"); + } + } + + return true; + } + + protected async Task SwitchToCorrectStanceForm(Form beforeForm, KeyAction item) { if (string.IsNullOrEmpty(item.Form)) return true; @@ -349,18 +430,25 @@ protected async Task SwitchToCorrectStanceForm(KeyAction item) return true; } - var formKeyKey = classConfig.Form + var formKeyAction = classConfig.Form .Where(s => s.FormEnum == item.FormEnum) .FirstOrDefault(); - if (formKeyKey == null) + if (formKeyAction == null) { logger.LogWarning($"Unable to find key in Form to transform into {item.FormEnum}"); return false; } - await input.KeyPress(formKeyKey.ConsoleKey, item.PressDuration); - await wait.Update(1); + await input.KeyPress(formKeyAction.ConsoleKey, formKeyAction.PressDuration); + (bool notChanged, double elapsedMs) = await wait.InterruptTask(SpellQueueTimeMs, () => beforeForm != playerReader.Form); + item.LogInformation($" ... form changed: {!notChanged} | Delay: {elapsedMs}ms"); + + if (playerReader.Form == Form.None) + { + item.LogInformation($" ... wait for GCD after form change {beforeForm}->{playerReader.Form}!"); + await WaitForGCD(item, playerReader.HasTarget); + } return playerReader.Form == item.FormEnum; } @@ -370,13 +458,17 @@ public async Task PressKey(ConsoleKey key, string description = "", int duration await input.KeyPress(key, duration, description); } - public virtual async Task ReactToLastUIErrorMessage(string source) + public async Task ReactToLastUIErrorMessage(string source) { //var lastError = playerReader.LastUIErrorMessage; switch (playerReader.LastUIErrorMessage) { case UI_ERROR.NONE: break; + case UI_ERROR.CAST_START: + break; + case UI_ERROR.CAST_SUCCESS: + break; case UI_ERROR.ERR_SPELL_FAILED_STUNNED: long debuffCount = playerReader.PlayerDebuffCount; if (debuffCount != 0) @@ -384,6 +476,7 @@ public virtual async Task ReactToLastUIErrorMessage(string source) logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_FAILED_STUNNED} -- Wait till losing debuff!"); await wait.While(() => debuffCount == playerReader.PlayerDebuffCount); + await wait.Update(1); playerReader.LastUIErrorMessage = UI_ERROR.NONE; } else @@ -398,9 +491,11 @@ public virtual async Task ReactToLastUIErrorMessage(string source) return; } - logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_OUT_OF_RANGE} -- Start moving forward"); - + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_OUT_OF_RANGE} -- Face enemy and start moving forward"); + await input.TapInteractKey(""); input.SetKeyState(ConsoleKey.UpArrow, true, false, ""); + + await wait.Update(1); playerReader.LastUIErrorMessage = UI_ERROR.NONE; break; case UI_ERROR.ERR_BADATTACKFACING: @@ -419,6 +514,7 @@ public virtual async Task ReactToLastUIErrorMessage(string source) await direction.SetDirection(desiredDirection, new WowPoint(0, 0), ""); } + await wait.Update(1); playerReader.LastUIErrorMessage = UI_ERROR.NONE; break; case UI_ERROR.SPELL_FAILED_MOVING: @@ -431,9 +527,15 @@ public virtual async Task ReactToLastUIErrorMessage(string source) case UI_ERROR.ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS: logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS} -- Wait till casting!"); await wait.While(() => playerReader.IsCasting); + + await wait.Update(1); + playerReader.LastUIErrorMessage = UI_ERROR.NONE; break; case UI_ERROR.ERR_SPELL_COOLDOWN: logger.LogInformation($"{source} -- Cant react to {UI_ERROR.ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS}"); + + await wait.Update(1); + playerReader.LastUIErrorMessage = UI_ERROR.NONE; break; case UI_ERROR.ERR_BADATTACKPOS: if (playerReader.IsAutoAttacking) @@ -441,6 +543,8 @@ public virtual async Task ReactToLastUIErrorMessage(string source) logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_BADATTACKPOS} -- Interact!"); await input.TapInteractKey(""); await stopMoving.Stop(); + await wait.Update(1); + playerReader.LastUIErrorMessage = UI_ERROR.NONE; } else @@ -459,5 +563,140 @@ public virtual async Task ReactToLastUIErrorMessage(string source) // break; } } + + private async Task ReactToLastCastingEvent(KeyAction item, string source) + { + switch ((UI_ERROR)playerReader.CastEvent.Value) + { + case UI_ERROR.NONE: + break; + case UI_ERROR.ERR_SPELL_FAILED_INTERRUPTED: + item.SetClicked(); + break; + case UI_ERROR.CAST_START: + break; + case UI_ERROR.CAST_SUCCESS: + break; + case UI_ERROR.ERR_SPELL_COOLDOWN: + logger.LogInformation($"{source} React to {UI_ERROR.ERR_SPELL_COOLDOWN} -- wait until its ready"); + bool before = playerReader.UsableAction.Is(item); + await wait.While(() => before != playerReader.UsableAction.Is(item)); + + break; + case UI_ERROR.ERR_SPELL_FAILED_STUNNED: + long debuffCount = playerReader.PlayerDebuffCount; + if (debuffCount != 0) + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_FAILED_STUNNED} -- Wait till losing debuff!"); + await wait.While(() => debuffCount == playerReader.PlayerDebuffCount); + } + else + { + logger.LogInformation($"{source} -- Didn't know how to react {UI_ERROR.ERR_SPELL_FAILED_STUNNED} when PlayerDebuffCount: {debuffCount}"); + } + + break; + case UI_ERROR.ERR_SPELL_OUT_OF_RANGE: + if (playerReader.PlayerClass == PlayerClassEnum.Hunter && playerReader.IsInMeleeRange) + { + logger.LogInformation($"{source} -- As a Hunter didn't know how to react {UI_ERROR.ERR_SPELL_OUT_OF_RANGE}"); + return; + } + + float minRange = playerReader.MinRange; + if (playerReader.PlayerBitValues.PlayerInCombat && playerReader.HasTarget && !playerReader.IsTargetCasting) + { + await wait.Update(2); + if (playerReader.TargetTarget == TargetTargetEnum.TargetIsTargettingMe) + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_OUT_OF_RANGE} -- Just wait for the target to get in range."); + + (bool inputNotHappened, double inputElapsedMs) = await wait.InterruptTask(MaxWaitCastTimeMs, + () => minRange != playerReader.MinRange || playerReader.IsTargetCasting + ); + } + } + else + { + double beforeDirection = playerReader.Direction; + await input.TapInteractKey(""); + await input.TapStopAttack(); + await stopMoving.Stop(); + await wait.Update(1); + + if (beforeDirection != playerReader.Direction) + { + await input.TapInteractKey(""); + + (bool inputNotHappened, double inputElapsedMs) = await wait.InterruptTask(MaxWaitCastTimeMs, + () => minRange != playerReader.MinRange); + + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_OUT_OF_RANGE} -- Approached target {minRange}->{playerReader.MinRange}"); + } + else + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_OUT_OF_RANGE} -- Start moving forward"); + input.SetKeyState(ConsoleKey.UpArrow, true, false, ""); + } + + + } + + break; + case UI_ERROR.ERR_BADATTACKFACING: + if (playerReader.IsInMeleeRange) + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_BADATTACKFACING} -- Interact!"); + await input.TapInteractKey(""); + } + else + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_BADATTACKFACING} -- Turning 180!"); + + double desiredDirection = playerReader.Direction + Math.PI; + desiredDirection = desiredDirection > Math.PI * 2 ? desiredDirection - (Math.PI * 2) : desiredDirection; + await direction.SetDirection(desiredDirection, new WowPoint(0, 0), ""); + + await wait.Update(1); + } + + break; + case UI_ERROR.SPELL_FAILED_MOVING: + logger.LogInformation($"{source} -- React to {UI_ERROR.SPELL_FAILED_MOVING} -- Stop moving!"); + await stopMoving.Stop(); + await wait.Update(1); + + break; + case UI_ERROR.ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS: + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_SPELL_FAILED_ANOTHER_IN_PROGRESS} -- Wait till casting!"); + await wait.While(() => playerReader.IsCasting); + + break; + case UI_ERROR.ERR_BADATTACKPOS: + if (playerReader.IsAutoAttacking) + { + logger.LogInformation($"{source} -- React to {UI_ERROR.ERR_BADATTACKPOS} -- Interact!"); + await input.TapInteractKey(""); + await stopMoving.Stop(); + await wait.Update(1); + } + else + { + logger.LogInformation($"{source} -- Didn't know how to React to {(UI_ERROR)playerReader.CastEvent.Value}"); + } + + break; + default: + logger.LogInformation($"{source} -- Didn't know how to React to {(UI_ERROR)playerReader.CastEvent.Value}"); + + break; + //case UI_ERROR.ERR_SPELL_FAILED_S: + //case UI_ERROR.ERR_BADATTACKPOS: + //case UI_ERROR.ERR_SPELL_OUT_OF_RANGE: + //case UI_ERROR.ERR_AUTOFOLLOW_TOO_FAR: + // this.playerReader.LastUIErrorMessage = UI_ERROR.NONE; + // break; + } + } } } \ No newline at end of file diff --git a/Core/Goals/CombatGoal.cs b/Core/Goals/CombatGoal.cs index 2495ddb9e..e5c6bb8ca 100644 --- a/Core/Goals/CombatGoal.cs +++ b/Core/Goals/CombatGoal.cs @@ -76,13 +76,14 @@ protected async Task Fight() lastKnownMaxDistance = playerReader.MaxRange; } - if (playerReader.IsAutoAttacking) - { - await castingHandler.ReactToLastUIErrorMessage($"{GetType().Name}: Fight AutoAttacking"); - } - if (await castingHandler.CastIfReady(item, item.DelayBeforeCast)) { + if (item.Name == classConfiguration.Approach.Name || + item.Name == classConfiguration.AutoAttack.Name) + { + await castingHandler.ReactToLastUIErrorMessage($"{GetType().Name}: Fight {item.Name}"); + } + break; } } @@ -132,14 +133,9 @@ public override async Task OnEnter() await input.TapDismount(); } - // this one is important for melees - // if not waiting a bit, the player will constantly moving forward - await stopMoving.Stop(); - await wait.Update(1); lastDirectionForTurnAround = playerReader.Direction; - logger.LogInformation($"{GetType().Name}: OnEnter"); SendActionEvent(new ActionEventArgs(GoapKey.fighting, true)); } @@ -166,8 +162,9 @@ public override async Task PerformAction() lastDirectionForTurnAround = playerReader.Direction; } - if (await StopDrowning()) + if (playerReader.PlayerBitValues.IsDrowning) { + await StopDrowning(); return; } @@ -218,31 +215,35 @@ private async Task CreatureTargetMeOrMyPet() return playerReader.HasTarget; } - await input.TapNearestTarget($"{GetType().Name}: Checking target in front of me"); - await wait.Update(1); - if (playerReader.HasTarget) + if (playerReader.CombatCreatureCount > 1) { - if (playerReader.PlayerBitValues.TargetInCombat && playerReader.PlayerBitValues.TargetOfTargetIsPlayer) + await input.TapNearestTarget($"{GetType().Name}: Checking target in front of me"); + await wait.Update(1); + if (playerReader.HasTarget) { - ResetCooldowns(); - - logger.LogWarning("---- Somebody is attacking me!"); - await input.TapInteractKey("Found new target to attack"); + if (playerReader.PlayerBitValues.TargetInCombat && playerReader.PlayerBitValues.TargetOfTargetIsPlayer) + { + ResetCooldowns(); + + logger.LogWarning("---- Somebody is attacking me!"); + await input.TapInteractKey("Found new target to attack"); + await stopMoving.Stop(); + await wait.Update(1); + return true; + } + + await input.TapClearTarget(); await wait.Update(1); - return true; } - - await input.TapClearTarget(); - await wait.Update(1); - } - else - { - // threat must be behind me - var anyDamageTakens = playerReader.DamageTaken.Where(x => (DateTime.Now - x.LastEvent).TotalSeconds < 10 && x.LastKnownHealthPercent > 0); - if (anyDamageTakens.Any()) + else { - logger.LogWarning($"---- Possible threats found behind {anyDamageTakens.Count()}. Waiting for my target to change!"); - await wait.Interrupt(2000, () => playerReader.HasTarget); + // threat must be behind me + var anyDamageTakens = playerReader.DamageTaken.Where(x => (DateTime.Now - x.LastEvent).TotalSeconds < 10 && x.LastKnownHealthPercent > 0); + if (anyDamageTakens.Any()) + { + logger.LogWarning($"---- Possible threats found behind {anyDamageTakens.Count()}. Waiting for my target to change!"); + await wait.Interrupt(2000, () => playerReader.HasTarget); + } } } @@ -251,16 +252,10 @@ private async Task CreatureTargetMeOrMyPet() return false; } - private async Task StopDrowning() + private async Task StopDrowning() { - if (playerReader.PlayerBitValues.IsDrowning) - { - await input.TapJump("Drowning! Swim up"); - await wait.Update(1); - return true; - } - - return false; + await input.TapJump("Drowning! Swim up"); + await wait.Update(1); } private WowPoint GetCorpseLocation(double distance) diff --git a/Core/Goals/FollowRouteGoal.cs b/Core/Goals/FollowRouteGoal.cs index c5558eb1b..398de4a76 100644 --- a/Core/Goals/FollowRouteGoal.cs +++ b/Core/Goals/FollowRouteGoal.cs @@ -156,6 +156,11 @@ public override async Task PerformAction() return; } + if (playerReader.PlayerBitValues.IsDrowning) + { + await StopDrowning(); + } + await SwitchGatherType(); if (this.playerReader.PlayerBitValues.PlayerInCombat && classConfiguration.Mode != Mode.AttendedGather) { return; } @@ -191,7 +196,6 @@ public override async Task PerformAction() } await RandomJump(); - await StopDrowning(); var location = new WowPoint(playerReader.XCoord, playerReader.YCoord, playerReader.ZCoord); var distance = WowPoint.DistanceTo(location, routeToWaypoint.Peek()); @@ -259,7 +263,7 @@ public override async Task PerformAction() LastActive = DateTime.Now; - await Task.Delay(10); + await wait.Update(1); } private void StartLookingForTarget() @@ -274,6 +278,7 @@ private void StartLookingForTarget() while (!found && !targetFinderCts.IsCancellationRequested) { found = await targetFinder.Search(GetType().Name, targetFinderCts.Token); + await wait.Update(1); } if (found) @@ -342,6 +347,7 @@ private async Task MountIfRequired() if (!npcNameFinder.MobsVisible) { await mountHandler.MountUp(); + stuckDetector.ResetStuckParameters(); } else { @@ -509,11 +515,8 @@ public static Vector2 GetClosestPointOnLineSegment(Vector2 A, Vector2 B, Vector2 private async Task StopDrowning() { - if (playerReader.PlayerBitValues.IsDrowning) - { - await input.TapJump("Drowning! Swim up"); - await wait.Update(1); - } + await input.TapJump("Drowning! Swim up"); + await wait.Update(1); } private void Log(string text) diff --git a/Core/Goals/GoalThread.cs b/Core/Goals/GoalThread.cs index 75542d335..15b93987b 100644 --- a/Core/Goals/GoalThread.cs +++ b/Core/Goals/GoalThread.cs @@ -47,7 +47,9 @@ public void OnActionEvent(object sender, ActionEventArgs e) if (routeInfo != null && routeInfo.PoiList.Any()) { var closest = routeInfo.PoiList.Where(p => p.Name == "Corpse"). - Min(i => (WowPoint.DistanceTo(goapAgent.PlayerReader.PlayerLocation, i.Location), i)); + Select(i => new { i, d = WowPoint.DistanceTo(goapAgent.PlayerReader.PlayerLocation, i.Location) }). + Aggregate((a, b) => a.d <= b.d ? a : b); + if (closest.i != null) { routeInfo.PoiList.Remove(closest.i); diff --git a/Core/Goals/LootGoal.cs b/Core/Goals/LootGoal.cs index e73aa7aa8..7d85230ac 100644 --- a/Core/Goals/LootGoal.cs +++ b/Core/Goals/LootGoal.cs @@ -70,7 +70,7 @@ public override async Task PerformAction() await stopMoving.Stop(); combatUtil.Update(); - await npcNameTargeting.WaitForNUpdate(1); + await npcNameTargeting.WaitForNUpdate(2); bool foundCursor = await npcNameTargeting.FindByCursorType(Cursor.CursorClassification.Loot); if (foundCursor) { diff --git a/Core/Goals/MountHandler.cs b/Core/Goals/MountHandler.cs index 5ed4ed8f9..44e42bd9f 100644 --- a/Core/Goals/MountHandler.cs +++ b/Core/Goals/MountHandler.cs @@ -41,21 +41,25 @@ public async Task MountUp() } else { - await stopMoving.Stop(); - await wait.Update(1); - if (playerReader.PlayerBitValues.IsFalling) { (bool notfalling, double fallingElapsedMs) = await wait.InterruptTask(10000, () => !playerReader.PlayerBitValues.IsFalling); - if (!notfalling) - { - logger.LogInformation($"{GetType().Name}: waited for landing {fallingElapsedMs}ms"); - } + logger.LogInformation($"{GetType().Name}: waited for landing interrupted: {!notfalling} - {fallingElapsedMs}ms"); } - playerReader.LastUIErrorMessage = UI_ERROR.NONE; + await stopMoving.Stop(); + await wait.Update(1); + await input.TapMount(); - await wait.Interrupt(mountCastTimeMs, () => playerReader.PlayerBitValues.IsMounted || playerReader.LastUIErrorMessage != UI_ERROR.NONE); + + (bool notStartedCasted, double castStartElapsedMs) = await wait.InterruptTask(400, () => playerReader.PlayerBitValues.IsMounted || playerReader.IsCasting); + logger.LogInformation($"{GetType().Name}: casting: {!notStartedCasted} | Mounted: {playerReader.PlayerBitValues.IsMounted} | Delay: {castStartElapsedMs}ms"); + + if (!playerReader.PlayerBitValues.IsMounted) + { + (bool notmounted, double elapsedMs) = await wait.InterruptTask(mountCastTimeMs, () => playerReader.PlayerBitValues.IsMounted || !playerReader.IsCasting); + logger.LogInformation($"{GetType().Name}: interrupted: {!notmounted} | Mounted: {playerReader.PlayerBitValues.IsMounted} | Delay: {elapsedMs}ms"); + } } } } diff --git a/Core/Goals/PullTargetGoal.cs b/Core/Goals/PullTargetGoal.cs index a3294c8a5..6cd8a01e2 100644 --- a/Core/Goals/PullTargetGoal.cs +++ b/Core/Goals/PullTargetGoal.cs @@ -60,6 +60,10 @@ public override async Task OnEnter() await input.TapDismount(); } + await input.TapApproachKey($"{GetType().Name}: OnEnter - Face the target and stop"); + await stopMoving.Stop(); + await wait.Update(1); + pullStart = DateTime.Now; } @@ -116,25 +120,15 @@ public override async Task PerformAction() await stuckDetector.Unstick(); } - await Interact("No pulled!"); - await wait.Update(1); + if (classConfiguration.Approach.GetCooldownRemaining() == 0) + { + await input.TapApproachKey($"{GetType().Name}"); + await wait.Update(1); + } } else { SendActionEvent(new ActionEventArgs(GoapKey.pulled, true)); - playerReader.LastUIErrorMessage = UI_ERROR.NONE; - } - } - - private async Task Interact(string source) - { - if (classConfiguration.Interact.GetCooldownRemaining() == 0) - { - playerReader.LastUIErrorMessage = UI_ERROR.NONE; - await input.TapInteractKey($"{GetType().Name} {source}"); - await wait.Update(1); - - await castingHandler.ReactToLastUIErrorMessage($"{GetType().Name}-Interact: "); } } @@ -146,19 +140,20 @@ protected bool HasPickedUpAnAdd } } - protected async Task WaitForWithinMeleeRange(KeyAction item) + protected async Task WaitForWithinMeleeRange(KeyAction item, bool lastCastSuccess) { await stopMoving.Stop(); + await wait.Update(1); var start = DateTime.Now; - var playerHealth = playerReader.HealthCurrent; + var lastKnownHealth = playerReader.HealthCurrent; int maxWaitTime = 10; Log($"Waiting for the target to reach melee range - max {maxWaitTime}s"); while (playerReader.HasTarget && !playerReader.IsInMeleeRange && (DateTime.Now - start).TotalSeconds < maxWaitTime) { - if (playerHealth < playerReader.HealthCurrent) + if (playerReader.HealthCurrent < lastKnownHealth) { Log("Got damage. Stop waiting for melee range."); break; @@ -170,6 +165,13 @@ protected async Task WaitForWithinMeleeRange(KeyAction item) break; } + if (lastCastSuccess && playerReader.UsableAction.Is(item)) + { + Log($"While waiting, repeat current action: {item.Name}"); + lastCastSuccess = await castingHandler.CastIfReady(item, item.DelayBeforeCast); + Log($"Repeat current action: {lastCastSuccess}"); + } + await wait.Update(1); } } @@ -180,8 +182,6 @@ public async Task Pull() { await input.TapStopAttack(); await wait.Update(1); - - playerReader.LastUIErrorMessage = UI_ERROR.NONE; } if (playerReader.PlayerBitValues.HasPet && !playerReader.PetHasTarget) @@ -189,32 +189,35 @@ public async Task Pull() await input.TapPetAttack(); } + bool castAny = false; foreach (var item in Keys) { - if (item.StopBeforeCast) - { - await stopMoving.Stop(); - await wait.Update(1); - } - var success = await castingHandler.CastIfReady(item, item.DelayBeforeCast); - - if (!playerReader.HasTarget) + if (success) { - return false; - } + if (!playerReader.HasTarget) + { + return false; + } - if (success && item.WaitForWithinMeleeRange) - { - await WaitForWithinMeleeRange(item); + castAny = true; + + if (item.WaitForWithinMeleeRange) + { + await WaitForWithinMeleeRange(item, success); + } } } - // Wait for combat - (bool interrupted, double elapsedMs) = await wait.InterruptTask(1000, () => playerReader.PlayerBitValues.PlayerInCombat); - if (!interrupted) + if (castAny) { - Log($"Entered combat after {elapsedMs}ms"); + (bool interrupted, double elapsedMs) = await wait.InterruptTask(1000, + () => playerReader.TargetTarget == TargetTargetEnum.TargetIsTargettingMe || + playerReader.TargetTarget == TargetTargetEnum.TargetIsTargettingPet); + if (!interrupted) + { + Log($"Entered combat after {elapsedMs}ms"); + } } return playerReader.PlayerBitValues.PlayerInCombat; diff --git a/Core/Goals/StopMoving.cs b/Core/Goals/StopMoving.cs index da2151403..fea842c9a 100644 --- a/Core/Goals/StopMoving.cs +++ b/Core/Goals/StopMoving.cs @@ -41,7 +41,7 @@ public async Task StopForward() input.SetKeyState(ConsoleKey.UpArrow, false, false, ""); input.SetKeyState(ConsoleKey.DownArrow, false, false, "StopForward"); - await Task.Delay(1); + await Task.Delay(10); } this.XCoord = playerReader.XCoord; diff --git a/Core/Goals/TargetFinder.cs b/Core/Goals/TargetFinder.cs index c4be85078..ecf0a3b62 100644 --- a/Core/Goals/TargetFinder.cs +++ b/Core/Goals/TargetFinder.cs @@ -68,7 +68,10 @@ private async Task LookForTarget(string source, CancellationToken cancella else { if (!cancellationToken.IsCancellationRequested) + { + npcNameTargeting.ChangeNpcType(NpcNameToFind); await input.TapNearestTarget(source); + } if (!playerReader.HasTarget && !cancellationToken.IsCancellationRequested) { diff --git a/Core/Goals/Wait.cs b/Core/Goals/Wait.cs index 6cdfbcd81..926b44ff3 100644 --- a/Core/Goals/Wait.cs +++ b/Core/Goals/Wait.cs @@ -49,6 +49,21 @@ public async Task> InterruptTask(int durationMs, Func return Tuple.Create(true, elapsedMs); } + public async Task> InterruptTask(int durationMs, Func interrupt, Action repeat) + { + DateTime start = DateTime.Now; + double elapsedMs; + while ((elapsedMs = (DateTime.Now - start).TotalMilliseconds) < durationMs) + { + repeat(); + await Update(1); + if (interrupt()) + return Tuple.Create(false, elapsedMs); + } + + return Tuple.Create(true, elapsedMs); + } + public async Task Interrupt(int durationMs, Task exit) { DateTime start = DateTime.Now; diff --git a/Core/Input/ConfigurableInput.cs b/Core/Input/ConfigurableInput.cs index 090439f7d..442ee8cce 100644 --- a/Core/Input/ConfigurableInput.cs +++ b/Core/Input/ConfigurableInput.cs @@ -27,6 +27,12 @@ public async Task TapInteractKey(string source) this.ClassConfig.Interact.SetClicked(); } + public async Task TapApproachKey(string source) + { + await KeyPress(ClassConfig.Approach.ConsoleKey, ClassConfig.Approach.PressDuration, string.IsNullOrEmpty(source) ? "" : $"TapApproachKey ({source})"); + this.ClassConfig.Approach.SetClicked(); + } + public async Task TapLastTargetKey(string source) { await KeyPress(ClassConfig.TargetLastTarget.ConsoleKey, defaultKeyPress, $"TapLastTarget ({source})"); @@ -47,7 +53,7 @@ public async Task TapClearTarget(string desc = "") public async Task TapStopAttack(string desc = "") { - await KeyPress(ClassConfig.StopAttack.ConsoleKey, defaultKeyPress, string.IsNullOrEmpty(desc) ? "" : $"TapStopAttack: {desc}"); + await KeyPress(ClassConfig.StopAttack.ConsoleKey, ClassConfig.StopAttack.PressDuration, string.IsNullOrEmpty(desc) ? "" : $"TapStopAttack: {desc}"); this.ClassConfig.StopAttack.SetClicked(); } @@ -77,7 +83,7 @@ public async Task TapJump(string desc = "") public async Task TapPetAttack(string source = "") { - await KeyPress(ClassConfig.PetAttack.ConsoleKey, defaultKeyPress, $"TapPetAttack ({source})"); + await KeyPress(ClassConfig.PetAttack.ConsoleKey, ClassConfig.PetAttack.PressDuration, $"TapPetAttack ({source})"); this.ClassConfig.PetAttack.SetClicked(); } diff --git a/Core/Requirement/RequirementFactory.cs b/Core/Requirement/RequirementFactory.cs index 71f078a45..4b3622e3c 100644 --- a/Core/Requirement/RequirementFactory.cs +++ b/Core/Requirement/RequirementFactory.cs @@ -34,7 +34,7 @@ public void InitialiseRequirements(KeyAction item) }; foreach (string part in requirement.Split("||")) { - var sub = GetRequirement(item.Name, part, item.FormEnum); + var sub = GetRequirement(item.Name, part); orCombinedRequirement = orCombinedRequirement.Or(sub); } @@ -48,7 +48,7 @@ public void InitialiseRequirements(KeyAction item) }; foreach (string part in requirement.Split("&&")) { - var sub = GetRequirement(item.Name, part, item.FormEnum); + var sub = GetRequirement(item.Name, part); andCombinedRequirement = andCombinedRequirement.And(sub); } @@ -56,7 +56,7 @@ public void InitialiseRequirements(KeyAction item) } else { - item.RequirementObjects.Add(GetRequirement(item.Name, requirement, item.FormEnum)); + item.RequirementObjects.Add(GetRequirement(item.Name, requirement)); } } @@ -64,13 +64,13 @@ public void InitialiseRequirements(KeyAction item) CreateMinRequirement(item.RequirementObjects, "Rage", item.MinRage); CreateMinRequirement(item.RequirementObjects, "Energy", item.MinEnergy); + CreateConsumableRequirement("Water", item); + CreateConsumableRequirement("Food", item); + CreateMinComboPointsRequirement(item.RequirementObjects, item); CreateTargetIsCastingRequirement(item.RequirementObjects, item.UseWhenTargetIsCasting); CreateActionUsableRequirement(item.RequirementObjects, item); - CreateWaterRequirement(item); - CreateFoodRequirement(item); - item.CreateCooldownRequirement(); item.CreateChargeRequirement(); } @@ -91,11 +91,11 @@ private void CreateMinRequirement(List RequirementObjects, string t { if (value > 0) { - if( type == "Mana") + if (type == "Mana") { RequirementObjects.Add(new Requirement { - HasRequirement = () => playerReader.ManaCurrent >= value, + HasRequirement = () => playerReader.ManaCurrent >= value || playerReader.Buffs.Clearcasting, LogMessage = () => $"{type} {playerReader.ManaCurrent} >= {value}" }); } @@ -103,7 +103,7 @@ private void CreateMinRequirement(List RequirementObjects, string t { RequirementObjects.Add(new Requirement { - HasRequirement = () => playerReader.PTCurrent >= value, + HasRequirement = () => playerReader.PTCurrent >= value || playerReader.Buffs.Clearcasting, LogMessage = () => $"{type} {playerReader.PTCurrent} >= {value}" }); } @@ -121,51 +121,33 @@ private void CreateMinComboPointsRequirement(List RequirementObject }); } } + private void CreateActionUsableRequirement(List RequirementObjects, KeyAction item) { if (item.WhenUsable && !string.IsNullOrEmpty(item.Key)) { RequirementObjects.Add(new Requirement { - HasRequirement = () => playerReader.UsableAction.Is(item), - LogMessage = () => $"Usable" - }); - } - } - - private void CreateWaterRequirement(KeyAction item) - { - if (item.Name == "Water") - { - item.RequirementObjects.Add(new Requirement - { - HasRequirement = () => bagReader.ItemCount(bagReader.HighestQuantityOfWaterId()) > 0, - LogMessage = () => $"Has Water" - }); - - item.RequirementObjects.Add(new Requirement - { - HasRequirement = () => !playerReader.PlayerBitValues.IsSwimming, - LogMessage = () => $"Not swim" - }); - - item.RequirementObjects.Add(new Requirement - { - HasRequirement = () => !playerReader.PlayerBitValues.IsFalling, - LogMessage = () => $"Not falling" + HasRequirement = () => + !item.HasFormRequirement() ? playerReader.UsableAction.Is(item) : + (playerReader.Form == item.FormEnum && playerReader.UsableAction.Is(item)) || + (playerReader.Form != item.FormEnum && item.CanDoFormChangeAndHaveMinimumMana()), + + LogMessage = () => + !item.HasFormRequirement() ? $"Usable" : // {playerReader.UsableAction.Num(item)} + (playerReader.Form != item.FormEnum && item.CanDoFormChangeAndHaveMinimumMana()) ? $"Usable after Form change" : // {playerReader.UsableAction.Num(item)} + (playerReader.Form == item.FormEnum && playerReader.UsableAction.Is(item)) ? $"Usable current Form" : $"not Usable current Form" // {playerReader.UsableAction.Num(item)} }); } } - private void CreateFoodRequirement(KeyAction item) + private void CreateConsumableRequirement(string name, KeyAction item) { - if (item.Name == "Food") + if (item.Name == name) { - item.RequirementObjects.Add(new Requirement - { - HasRequirement = () => bagReader.ItemCount(bagReader.HighestQuantityOfFoodId()) > 0, - LogMessage = () => $"Has Food" - }); + item.StopBeforeCast = true; + item.WhenUsable = true; + item.AfterCastWaitBuff = true; item.RequirementObjects.Add(new Requirement { @@ -181,7 +163,7 @@ private void CreateFoodRequirement(KeyAction item) } } - public Requirement GetRequirement(string name, string requirement, Form form) + public Requirement GetRequirement(string name, string requirement) { this.logger.LogInformation($"[{name}] Processing requirement: {requirement}"); @@ -189,7 +171,7 @@ public Requirement GetRequirement(string name, string requirement, Form form) if (requirement.Contains(">") || requirement.Contains("<")) { - return GetValueBasedRequirement(name, requirement, form); + return GetValueBasedRequirement(name, requirement); } if (requirement.Contains("npcID:")) @@ -212,6 +194,16 @@ public Requirement GetRequirement(string name, string requirement, Form form) return CreateTargetCastingSpellRequirement(requirement); } + if (requirement.Contains("Form")) + { + return CreateFormRequirement(requirement); + } + + if (requirement.Contains("Race")) + { + return CreateRaceRequirement(requirement); + } + if (BuffDictionary.Count == 0) { BuffDictionary = new Dictionary> @@ -244,6 +236,7 @@ public Requirement GetRequirement(string name, string requirement, Form form) { "Drinking", ()=> playerReader.Buffs.Drinking }, { "Mana Regeneration", ()=> playerReader.Buffs.ManaRegeneration }, { "Well Fed", ()=> playerReader.Buffs.WellFed }, + { "Clearcasting", ()=> playerReader.Buffs.Clearcasting }, //Priest { "Fortitude", ()=> playerReader.Buffs.Fortitude }, { "InnerFire", ()=> playerReader.Buffs.InnerFire }, @@ -271,6 +264,8 @@ public Requirement GetRequirement(string name, string requirement, Form form) { "Ward", ()=>playerReader.Buffs.Ward }, { "Fire Power", ()=>playerReader.Buffs.FirePower }, { "Mana Shield", ()=>playerReader.Buffs.ManaShield }, + { "Presence of Mind", ()=>playerReader.Buffs.PresenceOfMind }, + { "Arcane Power", ()=>playerReader.Buffs.ArcanePower }, // Rogue { "Slice and Dice", ()=> playerReader.Buffs.SliceAndDice }, { "Stealth", ()=> playerReader.Buffs.Stealth }, @@ -286,6 +281,7 @@ public Requirement GetRequirement(string name, string requirement, Form form) { "Lightning Shield", ()=> playerReader.Buffs.LightningShield }, { "Water Shield", ()=> playerReader.Buffs.WaterShield }, { "Shamanistic Focus", ()=> playerReader.Buffs.ShamanisticFocus }, + { "Stoneskin", ()=> playerReader.Buffs.Stoneskin }, //Hunter { "Aspect of the Cheetah", ()=> playerReader.Buffs.Aspect }, { "Aspect of the Pack", ()=> playerReader.Buffs.Aspect }, @@ -303,12 +299,14 @@ public Requirement GetRequirement(string name, string requirement, Form form) { "Rip", ()=> playerReader.Debuffs.Rip }, { "Moonfire", ()=> playerReader.Debuffs.Moonfire }, { "Entangling Roots", ()=> playerReader.Debuffs.EntanglingRoots }, + { "Rake", ()=> playerReader.Debuffs.Rake }, // Warrior Debuff { "Rend", ()=> playerReader.Debuffs.Rend }, // Priest Debuff { "Shadow Word: Pain", ()=> playerReader.Debuffs.ShadowWordPain }, // Mage Debuff { "Frostbite", ()=> playerReader.Debuffs.Frostbite }, + { "Slow", ()=> playerReader.Debuffs.Slow }, // Warlock Debuff { "Curse of Weakness", ()=> playerReader.Debuffs.Curseof }, { "Curse of Elements", ()=> playerReader.Debuffs.Curseof }, @@ -397,6 +395,47 @@ private Requirement CreateTargetCastingSpellRequirement(string requirement) } } + private Requirement CreateFormRequirement(string requirement) + { + var parts = requirement.Split(":"); + var form = Enum.Parse
(parts[1]); + + if (requirement.StartsWith("!") || requirement.StartsWith("not ")) + { + return new Requirement + { + HasRequirement = () => playerReader.Form != form, + LogMessage = () => $"not {form}" + }; + } + return new Requirement + { + HasRequirement = () => playerReader.Form == form, + LogMessage = () => $"{playerReader.Form}" + }; + } + + private Requirement CreateRaceRequirement(string requirement) + { + var parts = requirement.Split(":"); + var race = Enum.Parse(parts[1]); + + if (requirement.StartsWith("!") || requirement.StartsWith("not ")) + { + return new Requirement + { + HasRequirement = () => playerReader.PlayerRace != race, + LogMessage = () => $"not {race}" + }; + } + return new Requirement + { + HasRequirement = () => playerReader.PlayerRace == race, + LogMessage = () => $"{playerReader.PlayerRace}" + }; + } + + private Requirement CreateNpcRequirement(string requirement) { var parts = requirement.Split(":"); @@ -459,7 +498,7 @@ private Requirement CreateSpellInRangeRequirement(string requirement) }; } - private Requirement GetValueBasedRequirement(string name, string requirement, Form form) + private Requirement GetValueBasedRequirement(string name, string requirement) { var symbol = "<"; if (requirement.Contains(">")) @@ -495,23 +534,20 @@ private Requirement GetValueBasedRequirement(string name, string requirement, Fo } var valueCheck = valueDictionary[parts[0]]; - - Func formChangeCost = () => playerReader.Form != form ? (playerReader.FormCost.TryGetValue(form, out int cost) ? cost : 0) : 0; - if (symbol == ">") { return new Requirement { - HasRequirement = () => valueCheck() + formChangeCost() >= value, - LogMessage = () => $"{parts[0]} {valueCheck() + formChangeCost()} >= {value}" + HasRequirement = () => valueCheck() >= value, + LogMessage = () => $"{parts[0]} {valueCheck()} >= {value}" }; } else { return new Requirement { - HasRequirement = () => valueCheck() + formChangeCost() <= value, - LogMessage = () => $"{parts[0]} {valueCheck() + formChangeCost()} <= {value}" + HasRequirement = () => valueCheck() <= value, + LogMessage = () => $"{parts[0]} {valueCheck()} <= {value}" }; } } diff --git a/Json/class/Druid.json b/Json/class/Druid.json deleted file mode 100644 index d8dfa6b2e..000000000 --- a/Json/class/Druid.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "ClassName": "Druid", - "Loot": true, - "NPCMaxLevels_Below": 4, - "NPCMaxLevels_Above": 1, - - "PathFilename": "1_NightElf.json", - "SpiritPathFilename": "", - "PathThereAndBack": true, - "PathReduceSteps": false, - - "Blacklist": ["Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Form": [ - { - "Name": "/cancelform", - "Key": "F8", - "Form": "None" - }, - { - "Name": "Druid_Cat", - "Key": "2", - "Form": "Druid_Cat" - }, - { - "Name": "Druid_Travel", - "Key": "1", - "Form": "Druid_Travel" - } - ], - - "Pull": { - "Sequence": [ - { - "Name": "Wrath", - "Key": "2", - "StopBeforeCast": true, - "Form": "None", - "HasCastBar": true, - "MinMana": 20 - } - ] - }, - - "Combat": { - "Sequence": [ - { - "Name": "Approach", - "Cooldown": 10, - "Log": false, - "DelayAfterCast": "200" - }, - { - "Name": "Heal", - "Key": "3", - "Requirement": "Health%<50", - "Cooldown": 10, - "HasCastBar": true, - "Log": false, - "Form": "None", - "MinMana": 25 - }, - { - "Name": "Wrath", - "Key": "2", - "StopBeforeCast": true, - "Form": "None", - "HasCastBar": true, - "MinMana": 20 - } - ] - }, - "Adhoc": { - "Sequence": [ - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "-", - "Requirement": "Mana%<30", - "Cooldown": 10, - "Log": false, - "Form": "None" - } - ] - } -} diff --git a/Json/class/Druid_1.json b/Json/class/Druid_1.json index 72adfab33..db07105d1 100644 --- a/Json/class/Druid_1.json +++ b/Json/class/Druid_1.json @@ -8,7 +8,6 @@ { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true } ] @@ -18,25 +17,23 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<50", - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "Requirement": "TargetHealth%>50", "HasCastBar": true }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -45,11 +42,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Druid_10_bear.json b/Json/class/Druid_10_bear.json index 5ff78073a..65e0c1183 100644 --- a/Json/class/Druid_10_bear.json +++ b/Json/class/Druid_10_bear.json @@ -13,33 +13,33 @@ "Form": "None" }, { - //macro: #showtooltip Bear form /cast [nostance:1] Bear form - "Name": "bearform", + "Name": "Bear Form", "Key": "F2", "Form": "Druid_Bear" } ], "Pull": { "Sequence": [ -/* { - "Name": "Wrath", - "Key": "2", + "Name": "Moonfire", + "Key": "5", + "AfterCastWaitBuff": true, + "CastIfAddsVisible": true, + "Requirements": ["SpellInRange:0", "not InMeleeRange", "not Moonfire", "Mana%>50"], + "WaitForWithinMeleeRange": true, "StopBeforeCast": true, - "HasCastBar": true, - "Requirement": "SpellInRange:0", "Form": "None" }, -*/ { - "Name": "Moonfire", - "Key": "5", - "Requirement": "SpellInRange:0", - "Form": "None" + "Name": "Bear Form", + "Key": "F2", + "WaitForWithinMeleeRange": true, + "Requirements": ["Moonfire", "not Form:Druid_Bear"] }, { - "Name": "Approach", - "Log": false + "Name": "Bear Form", + "Key": "F2", + "Requirements": ["not Form:Druid_Bear"] } ] }, @@ -48,10 +48,9 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<25", - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { @@ -59,7 +58,7 @@ "Key": "6", "AfterCastWaitBuff": true, "Requirements": ["Health%<55", "not Rejuvenation"], - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { @@ -67,24 +66,24 @@ "Key": "3", "MinRage": 10, "WhenUsable": true, - "Requirements": ["InMeleeRange", "not Demoralizing Roar"], + "Requirements": ["InMeleeRange", "not Demoralizing Roar", "Form:Druid_Bear"], "Form": "Druid_Bear" }, { "Name": "Maul", "Key": "2", "MinRage": 15, - "Requirements": ["InMeleeRange", "LastMainHandMs>2100"], // bear swing speed fixed at 2.5 + "Requirements": ["InMeleeRange", "LastMainHandMs>2100", "Form:Druid_Bear"], // bear swing speed fixed at 2.5 "AfterCastWaitNextSwing": true, "Form": "Druid_Bear" }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -109,11 +108,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Requirement": "Mana%<40", - "Cooldown": 10, "Form": "None" } ] diff --git a/Json/class/Druid_12_bear.json b/Json/class/Druid_12_bear.json index 3a256d907..b0f9a77b1 100644 --- a/Json/class/Druid_12_bear.json +++ b/Json/class/Druid_12_bear.json @@ -13,8 +13,7 @@ "Form": "None" }, { - //macro: #showtooltip Bear form /cast [nostance:1] Bear form - "Name": "bearform", + "Name": "Bear Form", "Key": "F2", "Form": "Druid_Bear", "MinMana": 50 @@ -27,18 +26,29 @@ "Key": "6", "AfterCastWaitBuff": true, "Requirements": ["Health%<75", "not Rejuvenation"], - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { "Name": "Moonfire", "Key": "5", - "Requirements": ["SpellInRange:0", "not InMeleeRange", "Mana%>50"], + "AfterCastWaitBuff": true, + "CastIfAddsVisible": true, + "Requirements": ["SpellInRange:0", "not InMeleeRange", "not Moonfire", "Mana%>50"], + "WaitForWithinMeleeRange": true, + "StopBeforeCast": true, "Form": "None" }, { - "Name": "Approach", - "Log": false + "Name": "Bear Form", + "Key": "F2", + "WaitForWithinMeleeRange": true, + "Requirements": ["Moonfire", "not Form:Druid_Bear"] + }, + { + "Name": "Bear Form", + "Key": "F2", + "Requirements": ["not Form:Druid_Bear"] } ] }, @@ -47,10 +57,9 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<30", - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { @@ -65,24 +74,24 @@ "Key": "3", "MinRage": 10, "WhenUsable": true, - "Requirements": ["InMeleeRange", "not Demoralizing Roar"], + "Requirements": ["InMeleeRange", "not Demoralizing Roar", "Form:Druid_Bear"], "Form": "Druid_Bear" }, { "Name": "Maul", "Key": "2", "MinRage": 15, - "Requirements": ["InMeleeRange", "LastMainHandMs>2100"], // bear swing speed fixed at 2.5 + "Requirements": ["InMeleeRange", "LastMainHandMs>2100", "Form:Druid_Bear"], // bear swing speed fixed at 2.5 "AfterCastWaitNextSwing": true, "Form": "Druid_Bear" }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -114,11 +123,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Requirement": "Mana%<40", - "Cooldown": 10, "Form": "None" } ] diff --git a/Json/class/Druid_14_bear.json b/Json/class/Druid_14_bear.json index d9cfffe07..dd311a1a5 100644 --- a/Json/class/Druid_14_bear.json +++ b/Json/class/Druid_14_bear.json @@ -13,8 +13,7 @@ "Form": "None" }, { - //macro: #showtooltip Bear form /cast [nostance:1] Bear form - "Name": "bearform", + "Name": "Bear Form", "Key": "F2", "Form": "Druid_Bear", "MinMana": 50 @@ -27,18 +26,29 @@ "Key": "6", "AfterCastWaitBuff": true, "Requirements": ["Health%<75", "not Rejuvenation"], - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { "Name": "Moonfire", "Key": "5", - "Requirements": ["SpellInRange:0", "not InMeleeRange", "Mana%>50"], + "AfterCastWaitBuff": true, + "CastIfAddsVisible": true, + "Requirements": ["SpellInRange:0", "not InMeleeRange", "not Moonfire", "Mana%>50"], + "WaitForWithinMeleeRange": true, + "StopBeforeCast": true, "Form": "None" }, { - "Name": "Approach", - "Log": false + "Name": "Bear Form", + "Key": "F2", + "WaitForWithinMeleeRange": true, + "Requirements": ["Moonfire", "not Form:Druid_Bear"] + }, + { + "Name": "Bear Form", + "Key": "F2", + "Requirements": ["not Form:Druid_Bear"] } ] }, @@ -47,10 +57,9 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<30", - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { @@ -63,10 +72,9 @@ { "Name": "Bash", "Key": "5", - "Requirement": "InMeleeRange", - "UseWhenTargetIsCasting": true, "WhenUsable": true, "MinRage": 10, + "Requirements": ["SpellInRange:1", "TargetCastingSpell||Health%<38"], "Form": "Druid_Bear" }, { @@ -74,24 +82,24 @@ "Key": "3", "MinRage": 10, "WhenUsable": true, - "Requirements": ["InMeleeRange", "not Demoralizing Roar"], + "Requirements": ["InMeleeRange", "not Demoralizing Roar", "Form:Druid_Bear"], "Form": "Druid_Bear" }, { "Name": "Maul", "Key": "2", "MinRage": 15, - "Requirements": ["InMeleeRange", "LastMainHandMs>2100"], // bear swing speed fixed at 2.5 + "Requirements": ["InMeleeRange", "LastMainHandMs>2100", "Form:Druid_Bear"], // bear swing speed fixed at 2.5 "AfterCastWaitNextSwing": true, "Form": "Druid_Bear" }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -123,11 +131,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Requirement": "Mana%<40", - "Cooldown": 10, "Form": "None" } ] diff --git a/Json/class/Druid_16_bear.json b/Json/class/Druid_16_bear.json index 51ac93087..9b5bd86c8 100644 --- a/Json/class/Druid_16_bear.json +++ b/Json/class/Druid_16_bear.json @@ -4,6 +4,7 @@ "PathFilename": "_pack\\1-20\\Night elf\\15-18_Darkshore_Twilight Vale - Blackwood.json", "PathReduceSteps": true, "CheckTargetGivesExp": true, + "NPCMaxLevels_Below": 10, "Form": [ { @@ -13,8 +14,7 @@ "Form": "None" }, { - //macro: #showtooltip Bear form /cast [nostance:1] Bear form - "Name": "bearform", + "Name": "Bear Form", "Key": "F2", "Form": "Druid_Bear", "MinMana": 50 @@ -27,18 +27,29 @@ "Key": "6", "AfterCastWaitBuff": true, "Requirements": ["Health%<75", "not Rejuvenation"], - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { "Name": "Moonfire", "Key": "5", - "Requirements": ["SpellInRange:0", "not InMeleeRange", "Mana%>50"], + "AfterCastWaitBuff": true, + "CastIfAddsVisible": true, + "Requirements": ["SpellInRange:0", "not InMeleeRange", "not Moonfire", "Mana%>50"], + "WaitForWithinMeleeRange": true, + "StopBeforeCast": true, "Form": "None" }, { - "Name": "Approach", - "Log": false + "Name": "Bear Form", + "Key": "F2", + "WaitForWithinMeleeRange": true, + "Requirements": ["Moonfire", "not Form:Druid_Bear"] + }, + { + "Name": "Bear Form", + "Key": "F2", + "Requirements": ["not Form:Druid_Bear"] } ] }, @@ -47,10 +58,9 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<30", - "Cooldown": 5, + "Cooldown": 5000, "Form": "None" }, { @@ -63,8 +73,7 @@ { "Name": "Bash", "Key": "5", - "Requirement": "InMeleeRange", - "UseWhenTargetIsCasting": true, + "Requirements": ["SpellInRange:1", "TargetCastingSpell||Health%<38"], "WhenUsable": true, "MinRage": 10, "Form": "Druid_Bear" @@ -74,7 +83,7 @@ "Key": "3", "MinRage": 10, "WhenUsable": true, - "Requirements": ["InMeleeRange", "not Demoralizing Roar"], + "Requirements": ["InMeleeRange", "not Demoralizing Roar", "Form:Druid_Bear"], "Form": "Druid_Bear" }, { @@ -82,36 +91,29 @@ "Key": "6", "MinRage": 20, "WhenUsable": true, - "Requirements": ["InMeleeRange", "MobCount>2"], + "Requirements": ["InMeleeRange", "MobCount>2", "Form:Druid_Bear"], "Form": "Druid_Bear" }, { "Name": "Maul", "Key": "2", "MinRage": 15, - "Requirements": ["InMeleeRange", "MobCount<1", "LastMainHandMs>2100"], // bear swing speed fixed at 2.5 + "Requirements": ["InMeleeRange", "MobCount<1", "LastMainHandMs>2100", "Form:Druid_Bear"], // bear swing speed fixed at 2.5 "AfterCastWaitNextSwing": true, "Form": "Druid_Bear" }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, "Adhoc": { "Sequence": [ - { - //macro: #showtooltip Small Barnacled Clam /use Small Barnacled Clam - "Name": "clam", - "Key": "F12", - "DelayAfterCast": 0, - "Requirement": "BagItem:5523" - }, { "Name": "Mark of the Wild", "Key": "4", @@ -131,11 +133,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Requirement": "Mana%<40", - "Cooldown": 10, "Form": "None" } ] diff --git a/Json/class/Druid_1_NightElf.json b/Json/class/Druid_1_NightElf.json deleted file mode 100644 index d8dfa6b2e..000000000 --- a/Json/class/Druid_1_NightElf.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "ClassName": "Druid", - "Loot": true, - "NPCMaxLevels_Below": 4, - "NPCMaxLevels_Above": 1, - - "PathFilename": "1_NightElf.json", - "SpiritPathFilename": "", - "PathThereAndBack": true, - "PathReduceSteps": false, - - "Blacklist": ["Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Form": [ - { - "Name": "/cancelform", - "Key": "F8", - "Form": "None" - }, - { - "Name": "Druid_Cat", - "Key": "2", - "Form": "Druid_Cat" - }, - { - "Name": "Druid_Travel", - "Key": "1", - "Form": "Druid_Travel" - } - ], - - "Pull": { - "Sequence": [ - { - "Name": "Wrath", - "Key": "2", - "StopBeforeCast": true, - "Form": "None", - "HasCastBar": true, - "MinMana": 20 - } - ] - }, - - "Combat": { - "Sequence": [ - { - "Name": "Approach", - "Cooldown": 10, - "Log": false, - "DelayAfterCast": "200" - }, - { - "Name": "Heal", - "Key": "3", - "Requirement": "Health%<50", - "Cooldown": 10, - "HasCastBar": true, - "Log": false, - "Form": "None", - "MinMana": 25 - }, - { - "Name": "Wrath", - "Key": "2", - "StopBeforeCast": true, - "Form": "None", - "HasCastBar": true, - "MinMana": 20 - } - ] - }, - "Adhoc": { - "Sequence": [ - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "-", - "Requirement": "Mana%<30", - "Cooldown": 10, - "Log": false, - "Form": "None" - } - ] - } -} diff --git a/Json/class/Druid_20_cat_bear.json b/Json/class/Druid_20_cat_bear.json new file mode 100644 index 000000000..39ddc0c28 --- /dev/null +++ b/Json/class/Druid_20_cat_bear.json @@ -0,0 +1,173 @@ +{ + "ClassName": "Druid", + "Loot": true, + "PathFilename": "\\_pack\\1-20\\Human\\15-18_Westfall_The Dagger Hills (defias).json", + "PathReduceSteps": true, + "CheckTargetGivesExp": true, + "Form": [ + { + //macro: /cancelform + "Name": "cancelform", + "Key": "F1", + "Form": "None" + }, + { + "Name": "Bear Form", + "Key": "F2", + "Form": "Druid_Bear", + "MinMana": 50 + }, + { + "Name": "Cat form", + "Key": "F3", + "Form": "Druid_Cat", + "MinMana": 123 + } + ], + "Pull": { + "Sequence": [ + { + "Name": "Rejuvenation", + "Key": "6", + "StopBeforeCast": true, + "AfterCastWaitBuff": true, + "Requirements": ["Health%<75", "not Rejuvenation"], + "Cooldown": 5000, + "Form": "None" + }, + { + "Name": "Moonfire", + "Key": "5", + "AfterCastWaitBuff": true, + "CastIfAddsVisible": true, + "Requirements": ["SpellInRange:0", "not InMeleeRange", "not Moonfire", "Mana%>40"], + "StopBeforeCast": true, + "Form": "None" + }, + { + "Name": "Cat Form", + "Key": "F3", + "WaitForWithinMeleeRange": true, + "Requirements": ["Moonfire", "not Form:Druid_Cat"] + }, + { + "Name": "Cat Form", + "Key": "F3", + "Requirements": ["not Form:Druid_Cat"] + } + ] + }, + "Combat": { + "Sequence": [ + { + "Name": "Healing Touch", + "Key": "3", + "HasCastBar": true, + "WhenUsable": true, + "Requirement": "Health%<30", + "Cooldown": 5000, + "Form": "None" + }, + { + "Name": "Rip", + "Key": "3", + "MinEnergy": 30, + "MinComboPoints": 1, + "WhenUsable": true, + "Requirements": ["SpellInRange:2", "not Rip", "MobCount<1", "Form:Druid_Cat"], + "Form": "Druid_Cat" + }, + { + "Name": "Claw", + "Key": "2", + "MinEnergy": 40, + "WhenUsable": true, + "Requirements": ["SpellInRange:2", "MobCount<1", "Form:Druid_Cat"], + "Form": "Druid_Cat" + }, + { + "Name": "Bear Form", + "Key": "F2", + "Requirements": ["not Form:Druid_Bear", "Health%<50||MobCount>2"] + }, + { + "Name": "Bash", + "Key": "5", + "Requirements": ["SpellInRange:1", "TargetCastingSpell||Health%<38"], + "WhenUsable": true, + "MinRage": 10, + "Form": "Druid_Bear" + }, + { + "Name": "Enrage", + "Key": "4", + "WhenUsable": true, + "Requirement": "Form:Druid_Bear", + "Form": "Druid_Bear" + }, + { + "Name": "Demoralizing Roar", + "Key": "3", + "MinRage": 10, + "WhenUsable": true, + "Requirements": ["InMeleeRange", "not Demoralizing Roar", "MobCount>2", "Form:Druid_Bear"], + "Form": "Druid_Bear" + }, + { + "Name": "Swipe", + "Key": "6", + "MinRage": 20, + "WhenUsable": true, + "Requirements": ["InMeleeRange", "MobCount>2", "Form:Druid_Bear"], + "Form": "Druid_Bear" + }, + { + "Name": "Maul", + "Key": "2", + "MinRage": 15, + "Requirements": ["InMeleeRange", "MobCount<1", "LastMainHandMs>2100", "Form:Druid_Bear"], // bear swing speed fixed at 2.5 + "AfterCastWaitNextSwing": true, + "Form": "Druid_Bear" + }, + { + "Name": "Cat Form", + "Key": "F3", + "Requirements": ["not Form:Druid_Cat", "Health%>60", "MobCount<1"] + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false + } + ] + }, + "Adhoc": { + "Sequence": [ + { + "Name": "Mark of the Wild", + "Key": "4", + "AfterCastWaitBuff": true, + "DelayAfterCast": 0, + "Requirement": "not Mark of the Wild", + "Form": "None" + }, + { + "Name": "Thorns", + "Key": "7", + "AfterCastWaitBuff": true, + "DelayAfterCast": 0, + "Requirement": "not Thorns", + "Form": "None" + }, + { + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<30", + "Form": "None" + } + ] + } +} \ No newline at end of file diff --git a/Json/class/Druid_4.json b/Json/class/Druid_4.json index a9bbbe1eb..53e84e79e 100644 --- a/Json/class/Druid_4.json +++ b/Json/class/Druid_4.json @@ -8,7 +8,6 @@ { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true } ] @@ -18,20 +17,18 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<50", - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true }, { "Name": "Approach", - "Cooldown": 5 + "Log": false } ] }, @@ -40,17 +37,13 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" }, { "Name": "Mark of the Wild", "Key": "4", "Requirement": "not Mark of the Wild", - "Cooldown": 10 + "Cooldown": 10000 } ] }, diff --git a/Json/class/Druid_6.json b/Json/class/Druid_6.json index 802b8f43a..40b8b642b 100644 --- a/Json/class/Druid_6.json +++ b/Json/class/Druid_6.json @@ -9,7 +9,6 @@ { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true } ] @@ -19,17 +18,16 @@ { "Name": "Healing Touch", "Key": "3", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "Health%<25", - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Rejuvenation", "Key": "6", "AfterCastWaitBuff": true, "Requirements": ["Health%<55", "not Rejuvenation"], - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Moonfire", @@ -39,17 +37,16 @@ { "Name": "Wrath", "Key": "2", - "StopBeforeCast": true, "Requirement": "TargetHealth%>50", "HasCastBar": true }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -72,11 +69,7 @@ { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Druid_bear.json b/Json/class/Druid_bear.json index 417e1f80b..5d6581bc4 100644 --- a/Json/class/Druid_bear.json +++ b/Json/class/Druid_bear.json @@ -2,14 +2,25 @@ "ClassName": "Druid", "Loot": true, "NPCMaxLevels_Below": 8, - "PathFilename": "52_Ongoro.json", - "SpiritPathFilename": "52_Ongoro_SpiritHealer.json", "PathThereAndBack": true, "PathReduceSteps": true, - - "Blacklist": ["BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - + "Blacklist": [ + "BLUEGI", + "Tunnel", + "OL' SO", + "HAREN S", + "THRAGO", + "Elder Razormaw", + "Highland Razormaw", + "Boulderfist", + "witherbark", + "venomhide", + "tar beast", + "toxic horror", + "hive", + "hazzali" + ], "Form": [ { "Name": "/cancelform", @@ -17,30 +28,29 @@ "Form": "None" }, { - "Name": "Druid_Bear", - "Key": "2", + "Name": "Bear Form", + "Key": "F2", "Form": "Druid_Bear" }, { - "Name": "Druid_Travel", - "Key": "1", + "Name": "Travel Form", + "Key": "F1", "Form": "Druid_Travel" } ], - "Pull": { "Sequence": [ { "Name": "Rejuvenation", "Key": "1", - "Requirement": "Health%<70", + "AfterCastWaitBuff": true, + "Requirements": ["Health%<70", "not Rejuvenation"], "Form": "None" }, { "Name": "Wrath", "Key": "7", "Requirement": "OutOfCombatRange", - "StopBeforeCast": true, "Form": "None", "HasCastBar": true }, @@ -48,8 +58,8 @@ "Name": "Moonfire", "Key": "8", "Form": "None", - "MinMana": 235, - "DelayBeforeCast": 300 + "Requirements": ["not Moonfire", "SpellInRange:0"], + "MinMana": 235 }, { "Name": "Wrath", @@ -60,37 +70,27 @@ "WaitForWithinMeleeRange": true }, { - "Name": "Bear form", - "Key": "2", + "Name": "Bear Form", + "Key": "F2", "Form": "None", "WaitForWithinMeleeRange": true } ] }, - "Combat": { "Sequence": [ { - "Name": "Approach", - "Cooldown": 10, - "Log": false, - "DelayAfterCast": "200" - }, - { - "Name": "Heal", + "Name": "Healing Touch", "Key": "6", "Requirement": "Health%<50", - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, - "Log": false, "Form": "None" }, { "Name": "Enrage", "Key": "3", - "Cooldown": 15, - "DelayAfterCast": "200", - "Log": false, + "WhenUsable": true, "Form": "Druid_Bear" }, { @@ -98,36 +98,48 @@ "Requirement": "not Faerie Fire", "Key": "7", "MinRage": 10, - "Cooldown": 10, + "Cooldown": 10000, "Form": "Druid_Bear", - "Log": false, "ResetOnNewTarget": true }, { "Name": "Roar", - "Requirement": "not Demoralizing Roar", + "Requirements": ["InMeleeRange", "not Demoralizing Roar"], "Key": "5", "MinRage": 6, - "Cooldown": 10, - "Log": false, + "Cooldown": 10000, "Form": "Druid_Bear" }, { "Name": "Bash", "Key": "4", "MinRage": 10, - "Cooldown": 31, - "Log": false, + "Cooldown": 31000, + "Form": "Druid_Bear" + }, + { + "Name": "Swipe", + "Key": "N1", + "MinRage": 20, + "WhenUsable": true, + "Requirements": ["InMeleeRange", "MobCount>2"], "Form": "Druid_Bear" }, { "Name": "Maul", "Key": "2", "MinRage": 10, - "Cooldown": 2, - "DelayAfterCast": "500", - "Log": false, + "AfterCastWaitNextSwing": true, + "Requirements": ["InMeleeRange", "MobCount<1", "LastMainHandMs>2100"], // bear swing speed fixed at 2.5 "Form": "Druid_Bear" + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -137,19 +149,17 @@ "Name": "Healing Potion", "Key": "-", "Requirement": "Health%<8", - "Cooldown": 60, + "Cooldown": 60000, "Form": "None", "InCombat": "true", - "Log": false, "Cost": 3 }, { "Name": "Heal", "Key": "6", "Requirement": "Health%<60", - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, - "Log": false, "Form": "None", "Cost": 3 }, @@ -158,45 +168,35 @@ "StopBeforeCast": false, "Key": "9", "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false, + "Cooldown": 120000, "Form": "None" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "0", "Requirement": "Mana%<40", - "Cooldown": 10, - "Log": false, "Form": "None", "Cost": 3 }, { "Name": "Thorns", - "StopBeforeCast": false, "Key": "3", - "Cooldown": 10, + "Cooldown": 10000, "Requirement": "not Thorns", - "Log": false, "Form": "None" }, { "Name": "Mark of the Wild", - "StopBeforeCast": false, "Key": "4", - "Cooldown": 10, + "Cooldown": 10000, "Requirement": "not Mark of the Wild", - "Log": false, "Form": "None" }, { "Name": "Del1", "Key": "F5", - "Cooldown": 120, - "Log": false + "Cooldown": 120000 } ] } -} +} \ No newline at end of file diff --git a/Json/class/Druid_cat.json b/Json/class/Druid_cat.json index cc88001bc..09eec2246 100644 --- a/Json/class/Druid_cat.json +++ b/Json/class/Druid_cat.json @@ -2,14 +2,32 @@ "ClassName": "Druid", "Loot": true, "NPCMaxLevels_Below": 20, - "PathFilename": "56_Azshara.json", - "SpiritPathFilename": "56_Azshara_SpiritHealer.json", "PathThereAndBack": true, "PathReduceSteps": false, - - "Blacklist": ["Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - + "Blacklist": [ + "Legashi", + "Blood Elf", + "Elf Reclaim", + "Elf Survey", + "Searing Roc", + "Living Storm", + "Land Rager", + "BLUEGI", + "Tunnel", + "OL' SO", + "HAREN S", + "THRAGO", + "Elder Razormaw", + "Highland Razormaw", + "Boulderfist", + "witherbark", + "venomhide", + "tar beast", + "toxic horror", + "hive", + "hazzali" + ], "Form": [ { "Name": "/cancelform", @@ -17,30 +35,29 @@ "Form": "None" }, { - "Name": "Druid_Cat", - "Key": "2", + "Name": "Cat Form", + "Key": "F2", "Form": "Druid_Cat" }, { - "Name": "Druid_Travel", - "Key": "1", + "Name": "Travel Form", + "Key": "F1", "Form": "Druid_Travel" } ], - "Pull": { "Sequence": [ { "Name": "Rejuvenation", "Key": "1", - "Requirement": "Health%<70", + "AfterCastWaitBuff": true, + "Requirements": ["Health%<70", "not Rejuvenation"], "Form": "None" }, { "Name": "Wrath", "Key": "7", "Requirement": "OutOfCombatRange", - "StopBeforeCast": true, "Form": "None", "HasCastBar": true }, @@ -48,8 +65,8 @@ "Name": "Moonfire", "Key": "8", "Form": "None", - "MinMana": 235, - "DelayBeforeCast": 300 + "Requirements": ["SpellInRange:0", "not Moonfire"], + "MinMana": 235 }, { "Name": "Wrath", @@ -57,41 +74,31 @@ "Requirement": "OutOfCombatRange", "Form": "None", "HasCastBar": true, - "WaitForWithinMelleRange": true + "WaitForWithinMeleeRange": true }, { - "Name": "Cat form", - "Key": "2", + "Name": "Cat Form", + "Key": "F2", "Form": "None", - "WaitForWithinMelleRange": true + "WaitForWithinMeleeRange": true }, { - "Name": "Heal", + "Name": "Healing Touch", "Key": "6", "Requirement": "Health%<40", - "Cooldown": 10, - "HasCastBar": false, - "Log": false, + "Cooldown": 10000, + "HasCastBar": true, "Form": "None" } ] }, - "Combat": { "Sequence": [ { - "Name": "Approach", - "Cooldown": 10, - "Log": false, - "DelayAfterCast": "200" - }, - { - "Name": "Heal", + "Name": "Healing Potion", "Key": "-", "Requirement": "Health%<50", - "Cooldown": 10, - "HasCastBar": true, - "Log": false, + "Cooldown": 10000, "Form": "None" }, { @@ -99,9 +106,8 @@ "Requirement": "not TigersFury", "Key": "3", "MinEnergy": 30, - "Cooldown": 6, + "Cooldown": 6000, "DelayAfterCast": "200", - "Log": false, "Form": "Druid_Cat" }, { @@ -109,9 +115,8 @@ "Requirement": "not Faerie Fire", "Key": "7", "MinRage": 10, - "Cooldown": 10, + "Cooldown": 10000, "Form": "Druid_Cat", - "Log": false, "ResetOnNewTarget": true }, { @@ -120,17 +125,23 @@ "Key": "2", "MinEnergy": 30, "MinComboPoints": 3, - "Cooldown": 10, - "Log": false, + "Cooldown": 10000, "Form": "Druid_Cat" }, { "Name": "Rake", "Key": "1", "MinRage": 35, - "Cooldown": 1, - "Log": false, + "Cooldown": 1000, "Form": "Druid_Cat" + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -140,67 +151,55 @@ "Name": "Healing Potion", "Key": "-", "Requirement": "Health%<8", - "Cooldown": 60, + "Cooldown": 60000, "Form": "None", "InCombat": "true", - "Log": false, "Cost": 3 }, { - "Name": "Heal", + "Name": "Healing Touch", "Key": "6", "Requirement": "Health%<80", - "StopBeforeCast": true, - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, - "Log": false, "Form": "None", "Cost": 3 }, { "Name": "Well Fed", - "StopBeforeCast": false, "Key": "9", "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false, + "Cooldown": 120000, "Form": "None" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "0", "Requirement": "Mana%<40", - "Cooldown": 10, - "Log": false, "Form": "None", "Cost": 3 }, { "Name": "Thorns", - "StopBeforeCast": false, "Key": "3", - "Cooldown": 10, + "AfterCastWaitBuff": true, + "DelayAfterCast": 0, "Requirement": "not Thorns", - "Log": false, "Form": "None" }, { "Name": "Mark of the Wild", - "StopBeforeCast": false, "Key": "4", - "Cooldown": 10, + "AfterCastWaitBuff": true, + "DelayAfterCast": 0, "Requirement": "not Mark of the Wild", - "Log": false, "Form": "None" }, { "Name": "Del1", "Key": "F5", - "Cooldown": 120, - "Log": false + "Cooldown": 120000 } ] } -} +} \ No newline at end of file diff --git a/Json/class/Dwarf1-5.json b/Json/class/Dwarf1-5.json deleted file mode 100644 index 6832f586a..000000000 --- a/Json/class/Dwarf1-5.json +++ /dev/null @@ -1 +0,0 @@ -[{"X":29.910999999999998,"Y":73.725},{"X":30.396,"Y":74.08200000000001},{"X":30.768,"Y":74.57300000000001},{"X":30.718,"Y":75.19},{"X":30.776999999999997,"Y":75.789},{"X":30.275000000000002,"Y":76.13499999999999},{"X":30.137999999999998,"Y":75.547},{"X":29.646,"Y":75.184},{"X":29.054999999999996,"Y":75.053},{"X":28.841,"Y":74.47200000000001}] \ No newline at end of file diff --git a/Json/class/Hunter_1.json b/Json/class/Hunter_1.json index dbdbbf683..8e2abbbdb 100644 --- a/Json/class/Hunter_1.json +++ b/Json/class/Hunter_1.json @@ -4,8 +4,8 @@ "Pull": { "Sequence": [ { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] }, @@ -15,6 +15,7 @@ "WhenUsable": true, "AfterCastWaitNextSwing": true, "StepBackAfterCast": 1000, + "MinMana": 15, "Requirement": "InMeleeRange" } ] @@ -22,8 +23,8 @@ "Combat": { "Sequence": [ { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] }, @@ -37,8 +38,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] diff --git a/Json/class/Hunter_10.json b/Json/class/Hunter_10.json index efd285eaf..b49fd6fbc 100644 --- a/Json/class/Hunter_10.json +++ b/Json/class/Hunter_10.json @@ -7,8 +7,8 @@ "Name": "Concussive Shot", "Key": "9", "MinMana": 15, - "Cooldown": 12, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "HasAmmo"] + "Cooldown": 12000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange"] }, { "Name": "Raptor Strike", @@ -25,16 +25,15 @@ { "Name": "Gift of the Naaru", "Key": "1", - "StopBeforeCast": true, "HasCastBar": true, "WhenUsable": true, - "Requirement": "Health%<45" + "Requirements": ["Race:Draenei", "Health%<45"] }, { "Name": "Mend Pet", "Key": "N7", "MinMana": 200, - "Cooldown": 15, + "Cooldown": 15000, "WhenUsable": true, "Requirements": ["Has Pet", "PetHealth%<40"] }, @@ -42,22 +41,22 @@ "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo"] + "Cooldown": 4000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Serpent Sting"] }, { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Arcane Shot", "Key": "8", "MinMana": 15, - "Cooldown": 6, + "Cooldown": 6000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>60", "not Rapid Fire", "not Quick Shots"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Rapid Fire", "not Quick Shots", "TargetHealth%>60"] }, { "Name": "Raptor Strike", @@ -70,8 +69,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -87,7 +84,7 @@ { "Name": "feedpet", "Key": "N5", - "Cooldown": 20, + "Cooldown": 20000, "Requirements": ["Has Pet", "not Pet Happy"] }, { @@ -95,7 +92,7 @@ "Key": "N6", "MinMana": 20, "HasCastBar": true, - "Cooldown": 4, + "Cooldown": 4000, "Requirement": "not Has Pet" } ] @@ -104,21 +101,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<40", - "Cooldown": 10 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<40", - "Cooldown": 10 + "Requirement": "Mana%<40" } ] }, diff --git a/Json/class/Hunter_18.json b/Json/class/Hunter_18.json index 17c93f230..2c9ba0ad4 100644 --- a/Json/class/Hunter_18.json +++ b/Json/class/Hunter_18.json @@ -7,8 +7,8 @@ "Name": "Concussive Shot", "Key": "9", "MinMana": 15, - "Cooldown": 12, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "HasAmmo"] + "Cooldown": 12000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange"] }, { "Name": "Raptor Strike", @@ -25,38 +25,37 @@ { "Name": "Gift of the Naaru", "Key": "1", - "StopBeforeCast": true, "HasCastBar": true, "WhenUsable": true, - "Requirement": "Health%<45" + "Requirements": ["Race:Draenei", "Health%<45"] }, { "Name": "Mend Pet", "Key": "N7", "MinMana": 200, - "Cooldown": 15, + "Cooldown": 15000, "Requirements": ["Has Pet", "PetHealth%<50"] }, { "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "Mana%>55", "not Serpent Sting", "HasAmmo"] + "Cooldown": 4000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "Mana%>55", "not Serpent Sting"] }, { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Arcane Shot", "Key": "8", "MinMana": 15, - "Cooldown": 6, + "Cooldown": 6000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>60", "Mana%>70", "not Rapid Fire", "not Quick Shots"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Rapid Fire", "not Quick Shots", "TargetHealth%>60", "Mana%>70"] }, { "Name": "Raptor Strike", @@ -69,8 +68,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -86,7 +83,7 @@ { "Name": "feedpet", "Key": "N5", - "Cooldown": 20, + "Cooldown": 20000, "Requirements": ["Has Pet", "not Pet Happy"] }, { @@ -94,7 +91,7 @@ "Key": "N6", "MinMana": 20, "HasCastBar": true, - "Cooldown": 4, + "Cooldown": 4000, "Requirement": "not Has Pet" } ] @@ -103,21 +100,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<40", - "Cooldown": 10 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<40", - "Cooldown": 10 + "Requirement": "Mana%<40" } ] }, diff --git a/Json/class/Hunter_26.json b/Json/class/Hunter_26.json index 6af4522f1..523c94d68 100644 --- a/Json/class/Hunter_26.json +++ b/Json/class/Hunter_26.json @@ -7,8 +7,8 @@ "Name": "Concussive Shot", "Key": "9", "MinMana": 15, - "Cooldown": 12, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "HasAmmo"] + "Cooldown": 12000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange"] }, { "Name": "Raptor Strike", @@ -26,46 +26,45 @@ { "Name": "Gift of the Naaru", "Key": "1", - "StopBeforeCast": true, "HasCastBar": true, "WhenUsable": true, - "Requirement": "Health%<45" + "Requirements": ["Race:Draenei", "Health%<45"] }, { "Name": "Mend Pet", "Key": "N7", "MinMana": 200, - "Cooldown": 15, + "Cooldown": 15000, "Requirements": ["Has Pet", "PetHealth%<50"] }, { "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "Mana%>55", "not Serpent Sting", "HasAmmo"] + "Cooldown": 4000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Serpent Sting", "Mana%>55"] }, { "Name": "Rapid Fire", "Key": "N3", "MinMana": 15, - "Cooldown": 8, + "Cooldown": 8000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>90"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "TargetHealth%>90"] }, { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Arcane Shot", "Key": "8", "MinMana": 15, - "Cooldown": 6, + "Cooldown": 6000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>60", "Mana%>70", "not Rapid Fire", "not Quick Shots"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Rapid Fire", "not Quick Shots", "TargetHealth%>60", "Mana%>70"] }, { "Name": "Raptor Strike", @@ -78,8 +77,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -95,7 +92,7 @@ { "Name": "feedpet", "Key": "N5", - "Cooldown": 20, + "Cooldown": 20000, "Requirements": ["Has Pet", "not Pet Happy"] }, { @@ -103,7 +100,7 @@ "Key": "N6", "MinMana": 20, "HasCastBar": true, - "Cooldown": 4, + "Cooldown": 4000, "Requirement": "not Has Pet" } ] @@ -112,21 +109,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<40", - "Cooldown": 10 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<40", - "Cooldown": 10 + "Requirement": "Mana%<40" } ] }, diff --git a/Json/class/Hunter_30.json b/Json/class/Hunter_30.json index ebb864e13..1f259c0d3 100644 --- a/Json/class/Hunter_30.json +++ b/Json/class/Hunter_30.json @@ -7,8 +7,8 @@ "Name": "Concussive Shot", "Key": "9", "MinMana": 15, - "Cooldown": 12, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "HasAmmo"] + "Cooldown": 12000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange"] }, { "Name": "Raptor Strike", @@ -25,23 +25,22 @@ { "Name": "Gift of the Naaru", "Key": "1", - "StopBeforeCast": true, "HasCastBar": true, "WhenUsable": true, - "Requirement": "Health%<45" + "Requirements": ["Race:Draenei", "Health%<45"] }, { "Name": "Mend Pet", "Key": "N7", "MinMana": 200, - "Cooldown": 15, + "Cooldown": 15000, "Requirements": ["Has Pet", "PetHealth%<50"] }, { "Name": "Intimidation", "Key": "N4", "MinMana": 15, - "Cooldown": 60, + "Cooldown": 60000, "WhenUsable": true, "Requirements": ["Has Pet"] }, @@ -49,30 +48,30 @@ "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "Mana%>55", "not Serpent Sting", "HasAmmo"] + "Cooldown": 4000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Serpent Sting", "Mana%>55"] }, { "Name": "Rapid Fire", "Key": "N3", "MinMana": 15, - "Cooldown": 8, + "Cooldown": 8000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>90"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "TargetHealth%>90"] }, { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Arcane Shot", "Key": "8", "MinMana": 15, - "Cooldown": 6, + "Cooldown": 6000, "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>60", "Mana%>70", "not Rapid Fire", "not Quick Shots"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Rapid Fire", "not Quick Shots", "TargetHealth%>60", "Mana%>70"] }, { "Name": "Raptor Strike", @@ -85,8 +84,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -102,7 +99,7 @@ { "Name": "feedpet", "Key": "N5", - "Cooldown": 20, + "Cooldown": 20000, "Requirements": ["Has Pet", "not Pet Happy"] }, { @@ -110,7 +107,7 @@ "Key": "N6", "MinMana": 20, "HasCastBar": true, - "Cooldown": 4, + "Cooldown": 4000, "Requirement": "not Has Pet" } ] @@ -119,21 +116,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<40", - "Cooldown": 10 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<40", - "Cooldown": 10 + "Requirement": "Mana%<40" } ] } diff --git a/Json/class/Hunter_4.json b/Json/class/Hunter_4.json index adff45f2c..3bddba868 100644 --- a/Json/class/Hunter_4.json +++ b/Json/class/Hunter_4.json @@ -7,8 +7,14 @@ "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo"] + "Cooldown": 2000, + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Serpent Sting"] + }, + { + "Name": "Auto Shot", + "HasCastBar": true, + "Key": "3", + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Raptor Strike", @@ -23,17 +29,10 @@ "Combat": { "Sequence": [ { - "Name": "Serpent Sting", - "Key": "2", - "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo"] - }, - { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Raptor Strike", @@ -45,8 +44,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -65,21 +62,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<30", - "Cooldown": 10 + "Requirement": "Health%<30" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Hunter_58.json b/Json/class/Hunter_58.json deleted file mode 100644 index 5fe459873..000000000 --- a/Json/class/Hunter_58.json +++ /dev/null @@ -1,181 +0,0 @@ -{ - "ClassName": "Hunter", - "PathFilename": "_pack\\60-70\\Hellfire Peninsula\\60-64 birds.json", - "Pull": { - "Sequence": [ - { - "Name": "Hunter's Mark", - "DelayAfterCast": 1500, - "Key": "0" - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Approach", - "Requirement": "MaxRange>30" - }, - { - "Name": "Mend Pet", - "Key": "N7", - "MinMana": 200, - "Cooldown": 15, - "WhenUsable": true, - "Requirements": ["Has Pet", "PetHealth%<40"] - }, - { - "Name": "Intimidation", - "Key": "8", - "MinMana": 15, - "Cooldown": 15, - "WhenUsable": true, - "Requirements": ["Has Pet"] - }, - { - "Name": "Bestial Wrath", - "Key": "9", - "MinMana": 15, - "Cooldown": 15, - "WhenUsable": true, - "Requirements": ["Has Pet", "TargetHealth%>50"] - }, - { - "Name": "Aimed Shot", - "Key": "6", - "HasCastBar": true, - "MinMana": 15, - "Cooldown": 8, - "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo", "TargetHealth%>35", "not Rapid Fire", "not Quick Shots"] - }, - { - "Name": "Rapid Fire", - "Key": "7", - "MinMana": 15, - "Cooldown": 8, - "WhenUsable": true, - "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "HasAmmo"] - }, - { - "Name": "Serpent Sting", - "Key": "2", - "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo", "TargetHealth%>35"] - }, - { - "Name": "autoshot", - "StopBeforeCast": true, - "Key": "3", - "Cooldown": 2, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] - }, - { - "Name": "Multi-Shot", - "Key": "N3", - "HasCastBar": true, - "MinMana": 15, - "Cooldown": 10, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo", "TargetHealth%>35", "not Rapid Fire", "not Quick Shots"] - }, - { - "Name": "Mongoose Bite", - "Key": "5", - "WhenUsable": true, - "Cooldown": 5, - "MinMana": 15, - "Requirement": "InMeleeRange" - }, - { - "Name": "Raptor Strike", - "Key": "4", - "WhenUsable": true, - "AfterCastWaitNextSwing": true, - "Cooldown": 6, - "MinMana": 15, - "Requirement": "InMeleeRange" - }, - { - "Name": "Disengage", - "Key": "1", - "WhenUsable": true, - "Cooldown": 5, - "MinMana": 15, - "StepBackAfterCast": 1000, - "Requirement": "InMeleeRange" - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, - "Requirements": ["InMeleeRange", "not AutoAttacking"] - } - ] - }, - "Adhoc": { - "Sequence": [ - { - "Name": "Aspect of the Hawk", - "Key": "N4", - "MinMana": 20, - "Cooldown": 20, - "Requirement": "not Aspect of the Hawk" - }, - { - "Name": "feedpet", - "Key": "N5", - "Cooldown": 20, - "Requirements": ["Has Pet", "not Pet Happy"] - }, - { - "Name": "sumpet", - "Key": "N6", - "MinMana": 20, - "HasCastBar": true, - "Cooldown": 4, - "Requirement": "not Has Pet" - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<45", - "Cooldown": 10 - }, - { - "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<45", - "Cooldown": 10 - } - ] - }, - "NPC": { - "Sequence": [ - { - "Name": "Repair", - "Key": "C", - "Requirement": "Items Broken", - "PathFilename": "60_Hellfire_Honor_Hold_Vendor.json", - "Cost": 6 - }, - { - "Name": "Sell", - "Key": "C", - "Requirement": "BagFull", - "PathFilename": "60_Hellfire_Honor_Hold_Vendor.json", - "Cost": 6 - } - ] - } -} diff --git a/Json/class/Hunter_6.json b/Json/class/Hunter_6.json index 17ddf5f0d..606b7b62b 100644 --- a/Json/class/Hunter_6.json +++ b/Json/class/Hunter_6.json @@ -7,8 +7,7 @@ "Name": "Serpent Sting", "Key": "2", "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not Serpent Sting"] }, { "Name": "Raptor Strike", @@ -23,17 +22,10 @@ "Combat": { "Sequence": [ { - "Name": "Serpent Sting", - "Key": "2", - "MinMana": 15, - "Cooldown": 15, - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not Serpent Sting", "HasAmmo"] - }, - { - "Name": "autoshot", - "StopBeforeCast": true, + "Name": "Auto Shot", + "HasCastBar": true, "Key": "3", - "Requirements": ["HasRangedWeapon", "not InMeleeRange", "not AutoShot", "HasAmmo"] + "Requirements": ["HasRangedWeapon", "HasAmmo", "not InMeleeRange", "not AutoShot"] }, { "Name": "Raptor Strike", @@ -45,8 +37,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -65,21 +55,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "6", - "Requirement": "Health%<30", - "Cooldown": 10 + "Requirement": "Health%<30" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Hunter_62.json b/Json/class/Hunter_62.json index e9a30e9ee..2d45b4555 100644 --- a/Json/class/Hunter_62.json +++ b/Json/class/Hunter_62.json @@ -30,23 +30,21 @@ { "Name": "Gift of the Naaru", "Key": "1", - "StopBeforeCast": true, "HasCastBar": true, "WhenUsable": true, - "Requirement": "Health%<45" + "Requirements": ["Race:Draenei", "Health%<45"] }, { "Name": "Mend Pet", "Key": "N7", "MinMana": 200, - "Cooldown": 15, + "Cooldown": 15000, "Requirements": ["Has Pet", "PetHealth%<50"] }, { "Name": "Intimidation", "Key": "N4", "MinMana": 15, - "Cooldown": 60, "WhenUsable": true, "Requirements": ["Has Pet", "TargetHealth%<70||TargetCastingSpell"] }, @@ -54,7 +52,6 @@ "Name": "Bestial Wrath", "Key": "N2", "MinMana": 15, - "Cooldown": 8, "WhenUsable": true, "Requirements": ["not InMeleeRange", "HasRangedWeapon", "HasAmmo", "Has Pet", "TargetHealth%>85"] }, @@ -62,13 +59,13 @@ "Name": "Rapid Fire", "Key": "N3", "MinMana": 15, - "Cooldown": 8, "WhenUsable": true, "Requirements": ["not InMeleeRange", "HasRangedWeapon", "HasAmmo", "TargetHealth%>75"] }, { "Name": "Auto Shot", - "StopBeforeCast": true, + "HasCastBar": true, + "WhenUsable": true, "Key": "3", "Requirements": ["not InMeleeRange", "HasRangedWeapon", "not AutoShot", "HasAmmo"] }, @@ -78,14 +75,14 @@ "WhenUsable": true, "HasCastBar": true, "Charge": 2, - "Cooldown": 5, + "Cooldown": 5000, "Requirements": ["not InMeleeRange", "HasRangedWeapon", "HasAmmo", "LastAutoShotMs<500"] }, { "Name": "Disengage", "Key": "N8", "WhenUsable": true, - "Cooldown": 5, + "Cooldown": 5000, "MinMana": 15, "Requirement": "InMeleeRange" }, @@ -100,8 +97,6 @@ }, { "Name": "AutoAttack", - "Cooldown": 3, - "DelayAfterCast": 0, "Requirements": ["InMeleeRange", "not AutoAttacking"] } ] @@ -117,7 +112,7 @@ { "Name": "feedpet", "Key": "N5", - "Cooldown": 20, + "Cooldown": 20000, "Requirements": ["Has Pet", "not Pet Happy"] }, { @@ -125,7 +120,7 @@ "Key": "N6", "MinMana": 20, "HasCastBar": true, - "Cooldown": 4, + "Cooldown": 4000, "Requirement": "not Has Pet" } ] @@ -134,21 +129,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "-", - "Requirement": "Health%<40", - "Cooldown": 10 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", - "Requirement": "Mana%<40", - "Cooldown": 10 + "Requirement": "Mana%<40" } ] } diff --git a/Json/class/Mage.json b/Json/class/Mage.json index 3215db5fd..95a7c2548 100644 --- a/Json/class/Mage.json +++ b/Json/class/Mage.json @@ -11,18 +11,11 @@ "Blacklist": ["Kolkar","Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - "Pull": { "Sequence": [ { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", "MinMana": 35 } @@ -34,34 +27,39 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { - "Name": "Fireblast", + "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, - "Requirements": ["Health%<80", "SpellInRange:4"] + "WhenUsable": true, + "Requirements": ["TargetHealth%<45", "SpellInRange:4"] + }, + { + "Name": "Frost Nova", + "Key": "6", + "MinMana": 55, + "WhenUsable": true, + "Requirement": "InMeleeRange", + "StepBackAfterCast": 1000, + "DelayAfterCast": 0 }, { "Name": "Fireball", "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", "MinMana": 65 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -69,22 +67,14 @@ "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Name": "Food", + "Key": "=", + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<70", - "Cooldown": 10, - "Log": false + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<70" } ] }, @@ -93,44 +83,29 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:8077:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:1487:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false + "Cooldown": 30000 } ]} } diff --git a/Json/class/Mage1to4.json b/Json/class/Mage1to4.json deleted file mode 100644 index 6e9a96cea..000000000 --- a/Json/class/Mage1to4.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": false, - - "PathFilename": "1_Gnome.json", - "SpiritPathFilename": "1_Gnome.json", - "PathThereAndBack": true, - "PathReduceSteps": false, - - "Pull": { - "Sequence": [ - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 30 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 30 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Eat", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "=", - "Requirement": "Health%<50", - "Cooldown": 60 - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "-", - "Requirement": "Mana%<50", - "Cooldown": 60 - } - ] - } -} diff --git a/Json/class/Mage42.json b/Json/class/Mage42.json deleted file mode 100644 index 3215db5fd..000000000 --- a/Json/class/Mage42.json +++ /dev/null @@ -1,136 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": true, - - "NPCMaxLevels_Below": 6, - "NPCMaxLevels_Above": 2, - - "PathFilename": "38_Arathi.json", - "PathThereAndBack": true, - "PathReduceSteps": true, - - "Blacklist": ["Kolkar","Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - - "Pull": { - "Sequence": [ - { - "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "1", - "MinMana": 35 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Healing Potion", - "Key": "F4", - "Requirement": "Health%<10", - "Cooldown": 60, - "Log": false - }, - { - "Name": "Fireblast", - "Key": "5", - "MinMana": 40, - "Cooldown": 8, - "Requirements": ["Health%<80", "SpellInRange:4"] - }, - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 65 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<70", - "Cooldown": 10, - "Log": false - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:8077:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:1487:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - } - ]} -} diff --git a/Json/class/Mage44.json b/Json/class/Mage44.json deleted file mode 100644 index a51b5a182..000000000 --- a/Json/class/Mage44.json +++ /dev/null @@ -1,157 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": true, - - "PathFilename": "44_Tanaris.json", - "SpiritPathFilename": "44_Tanaris_SpiritHealer.json", - "PathThereAndBack": false, - "PathReduceSteps": false, - - "NPCMaxLevels_Below": 7, - "NPCMaxLevels_Above": 3, - - "Blacklist": ["Loch Crocolisk","Stonesplinter","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - - "Pull": { - "Sequence": [ - { - "Name": "Interact", - "Cooldown": 12, - "DelayAfterCast": 0 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "Key": "2", - "MinMana": 65, - "DelayUntilCombat": true, - "DelayAfterCast": 2000 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "Key": "2", - "MinMana": 65 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Healing Potion", - "Key": "F4", - "Requirement": "Health%<10", - "Cooldown": 60, - "Log": false - }, - { - "Name": "Fireblast", - "HasCastBar": false, - "StopBeforeCast": false, - "Key": "0", - "MinMana": 75, - "Cooldown": 8 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "Key": "2", - "MinMana": 65 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<70", - "Cooldown": 10, - "Log": false - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<55", - "Cooldown": 10, - "Log": false - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:8077:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:1487:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - }, - { - "Name": "Fire Power Potion", - "StopBeforeCast": true, - "Key": "=", - "Requirement": "not Fire Power", - "Cooldown": 18000, - "Log": false - } - ] - } -} diff --git a/Json/class/Mage54.json b/Json/class/Mage54.json deleted file mode 100644 index b500ed48d..000000000 --- a/Json/class/Mage54.json +++ /dev/null @@ -1,140 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": true, - "NPCMaxLevels_Below": 10, - "NPCMaxLevels_Above": 2, - - "PathFilename": "56_Azshara.json", - "PathThereAndBack": false, - "PathReduceSteps": false, - - "Blacklist": ["Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Pull": { - "Sequence": [ - { - "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "1", - "MinMana": 25 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Ice Barrier", - "Key": "7", - "MinMana": 60, - "Cooldown": 30, - "WhenUsable": true, - "Requirement": "not Ice Barrier" - }, - { - "Name": "Fire Blast", - "Key": "5", - "MinMana": 40, - "Cooldown": 8, - "Requirements": ["TargetHealth%<45", "SpellInRange:4"] - }, - { - "Name": "Frost Nova", - "Key": 6, - "MinMana": 55, - "Cooldown": 25, - "Requirement": "InMeleeRange", - "StepBackAfterCast": 1000, - "DelayAfterCast": 0 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 30, - "Requirements": ["TargetHealth%>35"] - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<60", - "Cooldown": 10 - }, - { - "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<60", - "Cooldown": 10 - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Ice Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Ice Barrier", - "Key": "7", - "MinMana": 60, - "Cooldown": 30, - "Requirement": "not Ice Barrier" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:8078:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:8076:4", - "Cooldown": 30, - "Log": false - } - ] - } -} diff --git a/Json/class/MageAttendedGrind.json b/Json/class/MageAttendedGrind.json index 239aa7d03..024faf487 100644 --- a/Json/class/MageAttendedGrind.json +++ b/Json/class/MageAttendedGrind.json @@ -13,26 +13,20 @@ "Blacklist": ["hive","tortured"], - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - "Pull": { "Sequence": [ { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 90, - "Cooldown": 0 + "MinMana": 90 }, { "Name": "Arcane Missiles", "HasCastBar": true, "Key": "-", "MinMana": 235, - "Cooldown": 60, + "Cooldown": 60000, "DelaybeforeCast": 1000 } ] @@ -43,14 +37,14 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Ice Barrier", "Key": "L", "Requirements": [ "not Ice Barrier","not npcID:8257"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -58,7 +52,7 @@ "Name": "Fire Ward", "Key": "=", "Requirements": [ "not Ward"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -67,8 +61,7 @@ "HasCastBar": true, "Key": "5", "Requirement": "not npcID:8257", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, @@ -76,22 +69,14 @@ "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Food", "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<90" } ] }, @@ -100,7 +85,6 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 110, "Requirement": "not Frost Armor", @@ -108,7 +92,6 @@ }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -117,19 +100,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8079:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false } ] diff --git a/Json/class/MageGrind.json b/Json/class/MageGrind.json index 0ab67a0d0..a63166ee4 100644 --- a/Json/class/MageGrind.json +++ b/Json/class/MageGrind.json @@ -11,26 +11,20 @@ "Blacklist": ["hive","tortured"], - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - "Pull": { "Sequence": [ { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 90, - "Cooldown": 0 + "MinMana": 90 }, { "Name": "Arcane Missiles", "HasCastBar": true, "Key": "-", "MinMana": 235, - "Cooldown": 60, + "Cooldown": 60000, "DelaybeforeCast": 1000 } ] @@ -41,14 +35,14 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Ice Barrier", "Key": "L", "Requirements": [ "not Ice Barrier","Health%<100"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 40, "Log": false }, @@ -57,36 +51,27 @@ "Key": "1", "Requirements": ["Health%<50"], "MinMana": 340, - "Cooldown": 8 + "Cooldown": 8000 }, { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Food", "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<90" } ] }, @@ -95,7 +80,6 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 110, "Requirement": "not Frost Armor", @@ -103,7 +87,6 @@ }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -112,19 +95,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8079:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { @@ -138,7 +119,7 @@ { "Name": "Del1", "Key": "F5", - "Cooldown": 120, + "Cooldown": 120000, "Log": false } ] diff --git a/Json/class/MageRaid.json b/Json/class/MageRaid.json index 17a600b1d..f87bd6881 100644 --- a/Json/class/MageRaid.json +++ b/Json/class/MageRaid.json @@ -12,12 +12,7 @@ "Mode": "AttendedGrind", "Blacklist": ["hive","tortured"], - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - + "Pull": { "Sequence": [ { @@ -25,8 +20,7 @@ "HasCastBar": true, "Key": "5", "Requirement": "not npcID:8257", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, @@ -36,14 +30,14 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Ice Barrier", "Key": "L", "Requirements": [ "not Ice Barrier","not npcID:8257"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -51,7 +45,7 @@ "Name": "Fire Ward", "Key": "=", "Requirements": [ "not Ward"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -60,8 +54,7 @@ "HasCastBar": true, "Key": "5", "Requirement": "not npcID:8257", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, @@ -69,22 +62,14 @@ "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Food", "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<90" } ] }, @@ -93,7 +78,6 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 110, "Requirement": "not Frost Armor", @@ -101,7 +85,6 @@ }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -110,19 +93,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8079:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false } ] diff --git a/Json/class/Mage_1.json b/Json/class/Mage_1.json index 1b7868c13..beac981fb 100644 --- a/Json/class/Mage_1.json +++ b/Json/class/Mage_1.json @@ -10,9 +10,8 @@ "Sequence": [ { "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 65 } ] @@ -21,24 +20,18 @@ "Sequence": [ { "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 30, - "Requirement": "TargetHealth%>10" + "Requirement": "TargetHealth%>20" }, { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" }, { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] + "Name": "Approach", + "Log": false } ] }, @@ -46,28 +39,19 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", - "Requirement": "Health%<30", - "Cooldown": 15 + "Requirement": "Health%<30" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "-", - "Requirement": "Mana%<30", - "Cooldown": 15 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Mage_10.json b/Json/class/Mage_10.json index 459ff38ab..81275f4a4 100644 --- a/Json/class/Mage_10.json +++ b/Json/class/Mage_10.json @@ -9,9 +9,9 @@ "Sequence": [ { "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", + "HasCastBar": true, + "Requirement": "SpellInRange:3", "MinMana": 25 } ] @@ -22,37 +22,32 @@ "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, + "WhenUsable": true, "Requirements": ["TargetHealth%<45", "SpellInRange:4"] }, { "Name": "Frost Nova", - "Key": 6, + "Key": "6", "MinMana": 55, - "Cooldown": 25, + "WhenUsable": true, "Requirement": "InMeleeRange", "StepBackAfterCast": 1000, "DelayAfterCast": 0 }, { "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", - "MinMana": 30, - "Requirements": ["TargetHealth%>35"] + "HasCastBar": true, + "MinMana": 30 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -61,21 +56,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<60", - "Cooldown": 10 + "Key": "=", + "Requirement": "Health%<60" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<60", - "Cooldown": 10 + "Key": "-", + "Requirement": "Mana%<60" } ] }, @@ -84,36 +71,29 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:5349:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 } ]}, "NPC": { diff --git a/Json/class/Mage12.json b/Json/class/Mage_12_Arcane.json similarity index 50% rename from Json/class/Mage12.json rename to Json/class/Mage_12_Arcane.json index 7de38d9f7..b857c8d81 100644 --- a/Json/class/Mage12.json +++ b/Json/class/Mage_12_Arcane.json @@ -11,78 +11,61 @@ "Sequence": [ { "Name": "Frostbolt", + "Key": "1", "HasCastBar": true, - "StopBeforeCast": true, - "Key": "5", + "Requirement": "SpellInRange:3", "MinMana": 35 - }, - { - "Name": "Arcane Missiles", - "HasCastBar": true, - "Key": "=", - "MinMana": 140, - "Cooldown": 60, - "DelaybeforeCast": 1000 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] }, "Combat": { "Sequence": [ { - "Name": "Interact", - "Cooldown": 12, + "Name": "Fire Blast", + "Key": "5", + "MinMana": 40, + "WhenUsable": true, + "Requirements": ["TargetHealth%<45", "SpellInRange:4"] + }, + { + "Name": "Frost Nova", + "Key": "6", + "MinMana": 55, + "WhenUsable": true, + "Requirement": "InMeleeRange", + "StepBackAfterCast": 1000, "DelayAfterCast": 0 }, { - "Name": "Fireblast", - "HasCastBar": false, - "StopBeforeCast": false, - "Key": "0", - "MinMana": 75, - "Requirements": ["Health%<80", "SpellInRange:4"], - "Cooldown": 8 + "Name": "Arcane Missiles", + "Key": "7", + "HasCastBar": true, + "MinMana": 140, + "Requirement": "SpellInRange:3" }, { - "Name": "Fireball", + "Name": "Shoot", + "Key": "0", "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 65 + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] + }, + { + "Name": "AutoAttack", + "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] }, "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Name": "Food", + "Key": "=", + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<90" } ] }, @@ -91,44 +74,29 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:1113:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false + "Cooldown": 30000 } ] } diff --git a/Json/class/Mage_12.json b/Json/class/Mage_12_Fire.json similarity index 68% rename from Json/class/Mage_12.json rename to Json/class/Mage_12_Fire.json index de9617ad0..e21776b8c 100644 --- a/Json/class/Mage_12.json +++ b/Json/class/Mage_12_Fire.json @@ -9,9 +9,9 @@ "Sequence": [ { "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", + "HasCastBar": true, + "Requirement": "SpellInRange:3", "MinMana": 25 } ] @@ -22,14 +22,14 @@ "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, + "WhenUsable": true, "Requirements": ["TargetHealth%<45", "SpellInRange:4"] }, { "Name": "Frost Nova", - "Key": 6, + "Key": "6", "MinMana": 55, - "Cooldown": 25, + "WhenUsable": true, "Requirement": "InMeleeRange", "StepBackAfterCast": 1000, "DelayAfterCast": 0 @@ -37,22 +37,18 @@ { "Name": "Fireball", "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", "MinMana": 30, "Requirements": ["TargetHealth%>35"] }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -61,21 +57,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<60", - "Cooldown": 10 + "Key": "=", + "Requirement": "Health%<60" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<60", - "Cooldown": 10 + "Key": "-", + "Requirement": "Mana%<60" } ] }, @@ -84,36 +72,29 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:1113:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 } ]}, "NPC": { diff --git a/Json/class/Mage_14_Arcane_Frost.json b/Json/class/Mage_14_Arcane_Frost.json index 0518539d2..1a8adf7cf 100644 --- a/Json/class/Mage_14_Arcane_Frost.json +++ b/Json/class/Mage_14_Arcane_Frost.json @@ -9,9 +9,8 @@ "Sequence": [ { "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", + "HasCastBar": true, "MinMana": 25, "Requirement": "SpellInRange:3" } @@ -23,14 +22,13 @@ "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, + "WhenUsable": true, "Requirements": ["TargetHealth%<45", "SpellInRange:4"] }, { "Name": "Frost Nova", - "Key": 6, + "Key": "6", "MinMana": 55, - "Cooldown": 25, "WhenUsable": true, "Requirement": "InMeleeRange", "StepBackAfterCast": 1000, @@ -39,22 +37,17 @@ { "Name": "Arcane Missiles", "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 30, - "Requirements": ["TargetHealth%>35"] + "Key": "7", + "MinMana": 30 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "Cooldown": 3, - "StopBeforeCast": true, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -63,21 +56,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<60", - "Cooldown": 10 + "Key": "=", + "Requirement": "Health%<60" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<60", - "Cooldown": 10 + "Key": "-", + "Requirement": "Mana%<60" } ] }, @@ -86,36 +71,29 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:1113:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 } ]}, "NPC": { diff --git a/Json/class/Mage16.json b/Json/class/Mage_16_Arcane_Fire.json similarity index 55% rename from Json/class/Mage16.json rename to Json/class/Mage_16_Arcane_Fire.json index 0fe25613f..a63a0b160 100644 --- a/Json/class/Mage16.json +++ b/Json/class/Mage_16_Arcane_Fire.json @@ -9,71 +9,70 @@ "Pull": { "Sequence": [ - { - "Name": "Interact", - "Cooldown": 12, - "DelayAfterCast": 0 - }, { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, - "Key": "5", + "Key": "1", + "Requirement": "SpellInRange:3", "MinMana": 35 - }, - { - "Name": "Arcane Missiles", - "HasCastBar": true, - "Key": "=", - "MinMana": 140, - "Cooldown": 60, - "DelaybeforeCast": 1000 } ] }, "Combat": { "Sequence": [ { - "Name": "Interact", - "Cooldown": 12, - "DelayAfterCast": 0 + "Name": "Fire Blast", + "Key": "5", + "MinMana": 40, + "WhenUsable": true, + "Requirements": ["TargetHealth%<45", "SpellInRange:4"] }, { - "Name": "Fireblast", - "HasCastBar": false, - "StopBeforeCast": false, - "Key": "0", - "MinMana": 75, - "Cooldown": 8 + "Name": "Frost Nova", + "Key": "6", + "MinMana": 55, + "WhenUsable": true, + "Requirement": "InMeleeRange", + "StepBackAfterCast": 1000, + "DelayAfterCast": 0 }, { "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, + "Requirement": "not InMeleeRange", "MinMana": 65 + }, + { + "Name": "Arcane Missiles", + "Key": "7", + "HasCastBar": true, + "MinMana": 140, + "Requirements": ["SpellInRange:3", "InMeleeRange"] + }, + { + "Name": "Shoot", + "Key": "0", + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] + }, + { + "Name": "AutoAttack", + "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] }, "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Name": "Food", + "Key": "=", + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<90" } ] }, @@ -82,45 +81,30 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:1113:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - }, + "Cooldown": 30000 + } ] } } diff --git a/Json/class/Mage_19.json b/Json/class/Mage_19.json deleted file mode 100644 index e427c5eb3..000000000 --- a/Json/class/Mage_19.json +++ /dev/null @@ -1,160 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": false, - - "PathFilename": "19_LochModan.json", - "SpiritPathFilename": "19_LochModan_SpiritHealer.json", - "PathThereAndBack": false, - "PathReduceSteps": false, - - "Blacklist": ["Loch Crocolisk","Stonesplinter","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - "Pull": { - "Sequence": [ - { - "Name": "Interact", - "Cooldown": 12, - "DelayAfterCast": 0 - }, - { - "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": false, - "Key": "5", - "MinMana": 35 - }, - { - "Name": "Fireball", - "DelayBeforeCast": 1500, - "HasCastBar": true, - "StopBeforeCast": false, - "Key": "2", - "MinMana": 65 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Healing Potion", - "Key": "F4", - "Requirement": "Health%<10", - "Cooldown": 60, - "Log": false - }, - { - "Name": "Fireblast", - "HasCastBar": false, - "StopBeforeCast": false, - "Key": "0", - "MinMana": 75, - "Cooldown": 6 - }, - { - "Name": "Frost Nova", - "Key": 6, - "MinMana": 55, - "Cooldown": 25, - "Requirement": "InMeleeRange", - "StepBackAfterCast": 1000, - "DelayAfterCast": 0 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 65 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:2288:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:1113:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - }, - { - "Name": "Fire Power", - "StopBeforeCast": false, - "Key": "1", - "Requirement": "not Fire Power", - "Cooldown": 120, - "Log": false - } - ] - } -} diff --git a/Json/class/Mage_25.json b/Json/class/Mage_25.json deleted file mode 100644 index 31e54d882..000000000 --- a/Json/class/Mage_25.json +++ /dev/null @@ -1,146 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": true, - - "NPCMaxLevels_Below": 6, - "NPCMaxLevels_Above": 2, - - "PathFilename": "25_wetlands.json", - "SpiritPathFilename": "25_wetlands_spirithealer.json", - "PathThereAndBack": true, - "PathReduceSteps": true, - - "Blacklist": ["Kolkar","Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - - "Pull": { - "Sequence": [ - { - "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "1", - "MinMana": 35 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Healing Potion", - "Key": "F4", - "Requirement": "Health%<10", - "Cooldown": 60, - "Log": false - }, - { - "Name": "Fireblast", - "Key": "5", - "MinMana": 40, - "Cooldown": 8, - "Requirements": ["Health%<80", "SpellInRange:4"] - }, - { - "Name": "Frost Nova", - "Key": 6, - "MinMana": 55, - "Cooldown": 25, - "Requirement": "InMeleeRange", - "StepBackAfterCast": 1000, - "DelayAfterCast": 0 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 65 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<70", - "Cooldown": 10, - "Log": false - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:2136:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:1114:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - } - ]} -} diff --git a/Json/class/Mage_30.json b/Json/class/Mage_30.json deleted file mode 100644 index 3048212ba..000000000 --- a/Json/class/Mage_30.json +++ /dev/null @@ -1,146 +0,0 @@ -{ - "ClassName": "Mage", - "Loot": true, - - "NPCMaxLevels_Below": 6, - "NPCMaxLevels_Above": 2, - - "PathFilename": "33_Arathi.json", - "SpiritPathFilename": "33_Arathi_SpiritHealer.json", - "PathThereAndBack": true, - "PathReduceSteps": true, - - "Blacklist": ["Kolkar","Legashi","Blood Elf","Elf Reclaim","Elf Survey","Searing Roc","Living Storm","Land Rager","BLUEGI","Tunnel","OL' SO","HAREN S","THRAGO", "Elder Razormaw","Highland Razormaw","Boulderfist","witherbark","venomhide","tar beast","toxic horror","hive","hazzali"], - - - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - - "Pull": { - "Sequence": [ - { - "Name": "Frostbolt", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "1", - "MinMana": 35 - } - ] - }, - "Combat": { - "Sequence": [ - { - "Name": "Healing Potion", - "Key": "F4", - "Requirement": "Health%<10", - "Cooldown": 60, - "Log": false - }, - { - "Name": "Fireblast", - "Key": "5", - "MinMana": 40, - "Cooldown": 8, - "Requirements": ["Health%<80", "SpellInRange:4"] - }, - { - "Name": "Frost Nova", - "Key": 6, - "MinMana": 55, - "Cooldown": 25, - "Requirement": "InMeleeRange", - "StepBackAfterCast": 1000, - "DelayAfterCast": 0 - }, - { - "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "2", - "MinMana": 65 - }, - { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - }, - { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - } - ] - }, - "Parallel": { - "Sequence": [ - { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false - }, - { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "7", - "Requirement": "Mana%<70", - "Cooldown": 10, - "Log": false - } - ] - }, - - "Adhoc": { - "Sequence": [ - { - "Name": "Frost Armor", - "StopBeforeCast": false, - "Key": "3", - "MinMana": 60, - "Requirement": "not Frost Armor" - }, - { - "Name": "Arcane Intellect", - "StopBeforeCast": false, - "Key": "4", - "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false - }, - { - "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "9", - "Requirement": "not BagItem:3772:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, - "Key": "8", - "Requirement": "not BagItem:1114:4", - "Cooldown": 30, - "Log": false - }, - { - "Name": "Well Fed", - "StopBeforeCast": true, - "Key": "-", - "Requirement": "not Well Fed", - "Cooldown": 120, - "Log": false - } - ]} -} diff --git a/Json/class/Mage_4.json b/Json/class/Mage_4.json index 782ec8ec8..66b3a39d1 100644 --- a/Json/class/Mage_4.json +++ b/Json/class/Mage_4.json @@ -11,8 +11,8 @@ { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", + "Requirement": "SpellInRange:3", "MinMana": 25 } ] @@ -22,23 +22,17 @@ { "Name": "Fireball", "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", "MinMana": 30, "Requirement": "TargetHealth%>10" }, { - "Name": "shoot", - "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" }, { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] + "Name": "Approach", + "Log": false } ] }, @@ -46,21 +40,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "6", - "Requirement": "Health%<30", - "Cooldown": 10 + "Key": "=", + "Requirement": "Health%<30" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "7", - "Requirement": "Mana%<30", - "Cooldown": 10 + "Key": "-", + "Requirement": "Mana%<30" } ] }, @@ -69,27 +55,22 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, - "Requirement": "not Arcane Intellect", - "Log": false + "Requirement": "not Arcane Intellect" }, { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:5350:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 } ]}, "NPC": { diff --git a/Json/class/Mage_54_Frost_Arcane.json b/Json/class/Mage_54_Frost_Arcane.json index 4c0cda692..87cf68bb7 100644 --- a/Json/class/Mage_54_Frost_Arcane.json +++ b/Json/class/Mage_54_Frost_Arcane.json @@ -19,7 +19,6 @@ { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", "MinMana": 25, "Requirement": "MaxRange<36" @@ -32,7 +31,7 @@ "Name": "Ice Barrier", "Key": "7", "MinMana": 420, - "Cooldown": 30, + "Cooldown": 30000, "WhenUsable": true, "Requirement": "not Ice Barrier" }, @@ -40,21 +39,21 @@ "Name": "Cone of Cold", "Key": "N8", "MinMana": 40, - "Cooldown": 10, + "Cooldown": 10000, "Requirements": ["TargetHealth%>2", "TargetHealth%<20", "InMeleeRange"] }, { "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, + "Cooldown": 8000, "Requirements": ["TargetHealth%>2", "TargetHealth%<20", "SpellInRange:4"] }, { "Name": "Frost Nova", "Key": 6, "MinMana": 55, - "Cooldown": 25, + "Cooldown": 25000, "WhenUsable": true, "Requirements": ["InMeleeRange", "MobCount>1"], "StepBackAfterCast": 1000, @@ -63,7 +62,6 @@ { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", "MinMana": 25, "Requirements": [ "MaxRange>31", "MaxRange<36"] @@ -71,40 +69,29 @@ { "Name": "Arcane Missiles", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["MaxRange<30", "TargetHealth%>30"], "Key": "2", "MinMana": 500 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "Cooldown": 1, - "StopBeforeCast": true, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false - } + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] + }, ] }, "Parallel": { "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 5 + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "N2", - "Requirement": "Mana%<50", - "Cooldown": 5 + "Requirement": "Mana%<50" } ] }, @@ -114,22 +101,19 @@ { "Name": "Evocation", "Key": "N9", - "StopBeforeCast": true, "HasCastBar": true, - "Cooldown": 600, + "Cooldown": 600000, "Cost": 2, "Requirements": ["Mana%<50"] }, { "Name": "Ice Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -138,19 +122,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8078:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false } ] diff --git a/Json/class/Mage_6.json b/Json/class/Mage_6.json index 34a877266..d86a2ddfd 100644 --- a/Json/class/Mage_6.json +++ b/Json/class/Mage_6.json @@ -11,8 +11,8 @@ { "Name": "Frostbolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "1", + "Requirement": "SpellInRange:3", "MinMana": 25 } ] @@ -23,28 +23,23 @@ "Name": "Fire Blast", "Key": "5", "MinMana": 40, - "Cooldown": 8, - "Requirements": ["TargetHealth%<45", "SpellInRange:4"], - "DelayAfterCast": 0 + "WhenUsable": true, + "Requirements": ["TargetHealth%<45", "SpellInRange:4"] }, { "Name": "Fireball", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 45 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -53,21 +48,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "6", - "Requirement": "Health%<50", - "Cooldown": 10 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "7", - "Requirement": "Mana%<50", - "Cooldown": 10 + "Key": "-", + "Requirement": "Mana%<50" } ] }, @@ -76,14 +63,12 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 60, "Requirement": "not Frost Armor" }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -91,21 +76,17 @@ }, { "Name": "Conjure Water", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", + "HasCastBar": true, "Requirement": "not BagItem:5350:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 }, { "Name": "Conjure Food", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", + "HasCastBar": true, "Requirement": "not BagItem:5349:4", - "Cooldown": 30, - "Log": false + "Cooldown": 30000 } ]}, "NPC": { diff --git a/Json/class/Mage_herb.json b/Json/class/Mage_herb.json index fef5f3dd9..6062d4de2 100644 --- a/Json/class/Mage_herb.json +++ b/Json/class/Mage_herb.json @@ -13,26 +13,20 @@ "Blacklist": ["hive","tortured"], - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - "Pull": { "Sequence": [ { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 90, - "Cooldown": 0 + "MinMana": 90 }, { "Name": "Arcane Missiles", "HasCastBar": true, "Key": "-", "MinMana": 235, - "Cooldown": 60, + "Cooldown": 60000, "DelaybeforeCast": 1000 } ] @@ -40,25 +34,24 @@ "Combat": { "Sequence": [ { - "Name": "Hero Charm", + "Name": "Trinket Hero Charm", "Key": "F8", - "Cooldown": 120, + "Cooldown": 120000, "Log": false, - "Requirement": "Health%<80", - "HasCastBar": false + "Requirement": "Health%<80" }, { "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Ice Barrier", "Key": "L", "Requirements": [ "not Ice Barrier","Health%<100"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 40, "Log": false }, @@ -67,36 +60,27 @@ "Key": "1", "Requirements": ["Health%<50"], "MinMana": 340, - "Cooldown": 8 + "Cooldown": 8000 }, { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Food", "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<90" } ] }, @@ -105,7 +89,6 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 110, "Requirement": "not Frost Armor", @@ -113,7 +96,6 @@ }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -122,19 +104,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8079:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { @@ -148,7 +128,7 @@ { "Name": "Del1", "Key": "F5", - "Cooldown": 120, + "Cooldown": 120000, "Log": false } ] diff --git a/Json/class/Mage_weeping.json b/Json/class/Mage_weeping.json index f56748a67..3acb88f1e 100644 --- a/Json/class/Mage_weeping.json +++ b/Json/class/Mage_weeping.json @@ -13,26 +13,20 @@ "Blacklist": ["hive","tortured"], - "Blink":{ - "Name": "Blink", - "Key": "T" - }, - "Pull": { "Sequence": [ { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", - "MinMana": 90, - "Cooldown": 0 + "MinMana": 90 }, { "Name": "Arcane Missiles", "HasCastBar": true, "Key": "-", "MinMana": 235, - "Cooldown": 60, + "Cooldown": 60000, "DelaybeforeCast": 1000 } ] @@ -44,21 +38,20 @@ // "Name": "Arcane Explosion", // "Key": "0", // "Requirement": "npcID:8257", -// "Cooldown": 0, // "Log": false // }, { "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Ice Barrier", "Key": "L", "Requirements": [ "not Ice Barrier","not npcID:8257"], //"Health%<100", - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -66,7 +59,7 @@ "Name": "Fire Ward", "Key": "=", "Requirements": [ "not Ward"], - "Cooldown": 30, + "Cooldown": 30000, "MinMana": 400, "Log": false }, @@ -75,15 +68,14 @@ // "Key": "1", // "Requirements": ["Health%<50","not npcID:8257"], // "MinMana": 333340, -// "Cooldown": 8 +// "Cooldown": 8000 // }, { "Name": "Frost Bolt", "HasCastBar": true, "Key": "5", "Requirement": "not npcID:8257", - "MinMana": 221, - "Cooldown": 0 + "MinMana": 221 } ] }, @@ -91,22 +83,14 @@ "Parallel": { "Sequence": [ { - "Name": "Low Health", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Food", "Key": "6", - "Requirement": "Health%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Health%<90" }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "7", - "Requirement": "Mana%<90", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<90" } ] }, @@ -115,7 +99,6 @@ "Sequence": [ { "Name": "Frost Armor", - "StopBeforeCast": false, "Key": "3", "MinMana": 110, "Requirement": "not Frost Armor", @@ -123,7 +106,6 @@ }, { "Name": "Arcane Intellect", - "StopBeforeCast": false, "Key": "4", "MinMana": 60, "Requirement": "not Arcane Intellect", @@ -132,19 +114,17 @@ { "Name": "Conjure Water", "HasCastBar": true, - "StopBeforeCast": true, "Key": "9", "Requirement": "not BagItem:8079:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { "Name": "Conjure Food", "HasCastBar": true, - "StopBeforeCast": true, "Key": "8", "Requirement": "not BagItem:8076:4", - "Cooldown": 30, + "Cooldown": 30000, "Log": false }, { @@ -158,7 +138,7 @@ { "Name": "Del1", "Key": "F5", - "Cooldown": 120, + "Cooldown": 120000, "Log": false } ] diff --git a/Json/class/Paladin.json b/Json/class/Paladin.json index 284cbea07..3fc4c95b7 100644 --- a/Json/class/Paladin.json +++ b/Json/class/Paladin.json @@ -18,33 +18,33 @@ "Sequence": [ { "Name": "Approach", - "Cooldown": 3 + "Cooldown": 3000 }, { "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<10", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Seal of Righteousness", "Key": "2", - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 82, "Requirements": [ "not Seal"] }, { "Name": "Judgement", "Key": "3", - "Cooldown": 12, + "Cooldown": 12000, "Requirement": "Mana%>40", "MinMana": 77 }, { "Name": "Hammer of Justice", "Key": "9", - "Cooldown": 60, + "Cooldown": 60000, "MinMana": 50 } ] @@ -54,24 +54,21 @@ { "Name": "Holy Light", "HasCastBar": true, - "StopBeforeCast": true, "Key": "6", "Requirement": "Health%<50", - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 580, "Cost": 2, "InCombat": "any" }, { "Name": "Devotion Aura", - "StopBeforeCast": false, "Key": "5", "Requirement": "not Aura", "Log": false }, { "Name": "Blessing of Might", - "StopBeforeCast": false, "Key": "4", "MinMana": 45, "Requirement": "not Blessing", @@ -79,26 +76,20 @@ }, { "Name": "Well Fed", - "StopBeforeCast": false, "Key": "7", "Requirement": "not Well Fed", - "Cooldown": 120, + "Cooldown": 120000, "Log": false }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "8", "Requirement": "Mana%<80", - "Cooldown": 60, - "Cost": 3, - "Log": false + "Cost": 3 }, { "Name": "Sharpen Weapon", "HasCastBar": true, - "StopBeforeCast": true, "Key": "F1", "Cooldown": 1800, "Log": false @@ -106,7 +97,7 @@ { "Name": "Del1", "Key": "F5", - "Cooldown": 120, + "Cooldown": 120000, "Log": false } ] diff --git a/Json/class/Paladin_1.json b/Json/class/Paladin_1.json index 3802c04d4..4be838b15 100644 --- a/Json/class/Paladin_1.json +++ b/Json/class/Paladin_1.json @@ -7,17 +7,16 @@ { "Name": "Seal of Righteousness", "Key": "2", - "Cooldown": 2, + "Cooldown": 2000, "Requirement": "not Seal" }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -26,10 +25,9 @@ { "Name": "Holy Light", "HasCastBar": true, - "StopBeforeCast": true, "Key": "3", "Requirement": "Health%<50", - "Cooldown": 2 + "Cooldown": 2000 } ] } diff --git a/Json/class/Paladin_10.json b/Json/class/Paladin_10.json index f80440464..26e08b06a 100644 --- a/Json/class/Paladin_10.json +++ b/Json/class/Paladin_10.json @@ -17,10 +17,9 @@ { "Name": "Holy Light", "HasCastBar": true, - "StopBeforeCast": true, "Key": "6", "Requirements": ["Health%<60", "TargetHealth%>20"], - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Judgement", @@ -40,13 +39,13 @@ "WaitBuffAfterCast": true, "Requirement": "not Seal" }, - { - "Name": "Approach", - "Log": false - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -56,14 +55,14 @@ "Name": "Retribution Aura", "Key": "8", "Requirement": "not Aura", - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Blessing of Might", "Key": "4", "WaitBuffAfterCast": true, "Requirement": "not Blessing", - "Cooldown": 5 + "Cooldown": 5000 } ] }, @@ -71,23 +70,14 @@ "Sequence": [ { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "-", - "Requirement": "Mana%<50", - "Cooldown": 5 + "Requirement": "Mana%<50" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", - "Requirement": "Health%<50", - "Cooldown": 5 + "Requirement": "Health%<50" } - ] } } diff --git a/Json/class/Paladin_66.json b/Json/class/Paladin_66.json index b87459c99..705cd6197 100644 --- a/Json/class/Paladin_66.json +++ b/Json/class/Paladin_66.json @@ -13,32 +13,31 @@ "Name": "Divine Shield", "Key": "5", "Requirement": "Health%<20", - "Cooldown": 60, + "Cooldown": 60000, "Log": false }, { "Name": "Healing Potion", "Key": "N2", "Requirement": "Health%<10", - "Cooldown": 120, + "Cooldown": 120000, "Log": false }, { "Name": "Holy Light", "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", "Requirements": [ "Health%<35", "TargetHealth%>20" ], - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 460 }, { "Name": "Hammer of Justice", "Key": "N3", - "Cooldown": 6, + "Cooldown": 6000, "MinMana": 300, "Requirements": [ "TargetHealth%<20" @@ -47,7 +46,7 @@ { "Name": "Seal of Wisdom", "Key": "N6", - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 82, "Requirements": [ "Mana%<50", @@ -57,7 +56,7 @@ { "Name": "Seal of Command", "Key": "2", - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 82, "Requirements": [ "Mana%>50", @@ -67,7 +66,7 @@ { "Name": "Judgement", "Key": "3", - "Cooldown": 8, + "Cooldown": 8000, "Requirements": [ "Mana%>60", "TargetHealth%>30" @@ -77,7 +76,7 @@ { "Name": "Hammer of Justice", "Key": "6", - "Cooldown": 60, + "Cooldown": 60000, "MinMana": 100, "Requirements": [ "Health%<50" @@ -86,7 +85,7 @@ { "Name": "Consecreation", "Key": "F4", - "Cooldown": 8, + "Cooldown": 8000, "MinMana": 100, "Requirements": [ "MobCount>2", @@ -96,20 +95,19 @@ { "Name": "Crusader Strike", "Key": "1", - "Cooldown": 6, + "Cooldown": 6000, "MinMana": 300, "Requirements": [ "Mana%>60" ] }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -117,14 +115,12 @@ "Sequence": [ { "Name": "Devotion Aura", - "StopBeforeCast": false, "Key": "F8", "Requirement": "not Aura", "Log": false }, { "Name": "Blessing of Might", - "StopBeforeCast": false, "Key": "0", "MinMana": 45, "Requirement": "not Blessing", @@ -137,33 +133,24 @@ { "Name": "Holy Light", "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", "Requirements": [ "Health%<40", "Mana%>50" ], - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 710, "Cost": 10 }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "8", - "Requirement": "Mana%<50", - "Cooldown": 6 + "Requirement": "Mana%<50" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "7", - "Requirement": "Health%<50", - "Cooldown": 6 + "Requirement": "Health%<50" } ] } diff --git a/Json/class/Priest.json b/Json/class/Priest.json index 38ca18f24..53fbb9513 100644 --- a/Json/class/Priest.json +++ b/Json/class/Priest.json @@ -14,7 +14,6 @@ "Name": "Mind Blast", "Key": "5", "DelayBeforeCast": 500, - "StopBeforeCast": true, "HasCastBar": true }, { @@ -24,8 +23,9 @@ }, { "Name": "Shoot", - "StopBeforeCast": true, - "Key": "0" + "Key": "0", + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] } ] }, @@ -35,7 +35,7 @@ "Name": "Power Infusion", "Key": "F11", "MinMana": 229, - "Cooldown": 180, + "Cooldown": 180000, "Log": false }, { @@ -43,7 +43,7 @@ "Key": "9", "Requirement": "Health%<60", "MinMana": 455, - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, "Log": false }, @@ -51,7 +51,7 @@ "Name": "Shadow Word Pain", "Key": "6", "Requirements": ["not Shadow Word: Pain","TargetHealth%>10","Health%>40"], - "Cooldown": 10, + "Cooldown": 10000, "MinMana": 274, "ResetOnNewTarget": true, "Log": false @@ -59,8 +59,7 @@ { "Name": "Mind Blast", "Key": "5", - "Cooldown": 10, - "StopBeforeCast": true, + "Cooldown": 10000, "Requirements": ["Health%>40"], "HasCastBar": true, "MinMana": 2500, @@ -70,20 +69,20 @@ "Name": "Shield", "Key": "3", "Requirements": ["Health%<75","not Shield","TargetHealth%>15"], - "Cooldown": 10, + "Cooldown": 10000, "MinMana": 270, "Log": false }, { - "Name": "Shooting", + "Name": "Shoot", "Key": "0", - "Requirement": "not Shooting", - "Cooldown": 2, + "HasCastBar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"], "Log": false }, { "Name": "Approach", - "Cooldown": 10, + "Cooldown": 10000, "Log": false, "DelayAfterCast": "200" } @@ -95,7 +94,7 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<7", - "Cooldown": 60, + "Cooldown": 60000, "InCombat": "true", "Log": false, "Cost": 3 @@ -104,8 +103,7 @@ "Name": "Heal", "Key": "9", "Requirement": "Health%<60", - "StopBeforeCast": true, - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, "Log": false }, @@ -114,43 +112,39 @@ "StopBeforeCast": true, "Key": "=", "Requirement": "not Well Fed", - "Cooldown": 120, + "Cooldown": 120000, "Log": false }, { - "Name": "Drink", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Water", "Key": "8", - "Requirement": "Mana%<40", - "Cooldown": 10, - "Log": false + "Requirement": "Mana%<40" }, { "Name": "Fortitude", "Key": "1", - "Cooldown": 10, + "Cooldown": 10000, "Requirement": "not Fortitude", "Log": false }, { "Name": "InnerFire", "Key": "2", - "Cooldown": 10, + "Cooldown": 10000, "Requirement": "not InnerFire", "Log": false }, { "Name": "Divine Spirit", "Key": "7", - "Cooldown": 10, + "Cooldown": 10000, "Requirement": "not Divine Spirit", "Log": false }//, //{ //"Name": "Open Clam", //"Key": "-", - //"Cooldown": 30, + //"Cooldown": 30000, //"Log": false //} ] diff --git a/Json/class/Priest_1.json b/Json/class/Priest_1.json new file mode 100644 index 000000000..9c79e87f5 --- /dev/null +++ b/Json/class/Priest_1.json @@ -0,0 +1,66 @@ +{ + "ClassName": "Priest", + "Loot": true, + "PathFilename": "_pack\\1-20\\Draenei\\1-5_Azuremyst Isle.json", + "PathThereAndBack": true, + "PathReduceSteps": true, + "Pull": { + "Sequence": [ + { + "Name": "Smite", + "Key": "2", + "HasCastBar": true, + "MinMana": 15, + "Requirement": "Mana%>50" + } + ] + }, + "Combat": { + "Sequence": [ + { + "Name": "Gift of the Naaru", + "Key": "4", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Race:Draenei", "Health%<50"] + }, + { + "Name": "Lesser Heal", + "Key": "3", + "Requirement": "Health%<40", + "Cooldown": 10000, + "HasCastBar": true, + "MinMana": 25 + }, + { + "Name": "Smite", + "Key": "2", + "HasCastBar": true, + "MinMana": 15, + "Requirements": ["not InMeleeRange", "Mana%>50"] + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false + } + ] + }, + "Parallel": { + "Sequence": [ + { + "Name": "Food", + "Key": "=", + "Requirement": "Health%<30" + }, + { + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<30" + } + ] + } +} diff --git a/Json/class/Rogue.json b/Json/class/Rogue.json index 221f03072..81c3efc01 100644 --- a/Json/class/Rogue.json +++ b/Json/class/Rogue.json @@ -42,27 +42,27 @@ { "Name": "Cold Blood", "Key": "1", - "Cooldown": 180 + "Cooldown": 180000 }, { "Name": "Vanish", "Key": "8", "Requirement": "Health%<10", "DelayAfterCast": 10000, - "Cooldown": 300 + "Cooldown": 300000 }, { "Name": "Evasion", "Key": "5", "Requirement": "Health%<50", - "Cooldown": 210 + "Cooldown": 210000 }, { "Name": "Slice And Dice", "Key": "3", "MinEnergy": 25, "MinComboPoints": 2, - "Cooldown": 11, + "Cooldown": 11000, "Requirement": "not Slice And Dice" }, { @@ -70,21 +70,20 @@ "Key": "4", "MinEnergy": 35, "MinComboPoints": 3, - "Cooldown": 10 + "Cooldown": 10000 }, { "Name": "Sinister Strike", "Key": "2", "MinEnergy": 40 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -94,24 +93,20 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<5", - "Cooldown": 60, + "Cooldown": 60000, "InCombat": "true", "Log": false, "Cost": 3 }, { - "Name": "Eat", - "StopBeforeCast": false, + "Name": "Food", "Key": "=", "Requirement": "Health%<60", - "Cooldown": 0, - "DelayAfterCast": 1000, - "Log": false, "Cost": 3 }, { "Name": "Well Fed", - "StopBeforeCast": false, + "StopBeforeCast": true, "Key": "7", "Requirement": "not Well Fed", "Cooldown": 1200, @@ -120,7 +115,6 @@ { "Name": "Sharpen Weapon 1", "HasCastBar": true, - "StopBeforeCast": true, "Key": "F1", "Cooldown": 1800, "Log": false @@ -128,7 +122,6 @@ { "Name": "Sharpen Weapon 2", "HasCastBar": true, - "StopBeforeCast": true, "Key": "F2", "Cooldown": 1800, "Log": false @@ -136,13 +129,13 @@ { "Name": "Equip Dagger", "Key": "F6", - "Cooldown": 600, + "Cooldown": 600000, "Log": false }, { "Name": "Open Clam", "Key": "-", - "Cooldown": 30, + "Cooldown": 30000, "Requirements": ["BagItem:7973:1"], "Log": false } diff --git a/Json/class/Rogue_1.json b/Json/class/Rogue_1.json index 4d9b7f47f..737e9a5b4 100644 --- a/Json/class/Rogue_1.json +++ b/Json/class/Rogue_1.json @@ -14,14 +14,13 @@ "Key": "2", "MinEnergy": 45 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -29,12 +28,8 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "N1", - "Requirement": "Health%<30", - "Cooldown": 15 + "Requirement": "Health%<30" } ] }, diff --git a/Json/class/Rogue_10.json b/Json/class/Rogue_10.json index 277f07a59..7c3ece6ab 100644 --- a/Json/class/Rogue_10.json +++ b/Json/class/Rogue_10.json @@ -50,13 +50,12 @@ "Requirement": "LastMainHandMs<500" }, { - "Name": "Approach", - "Log": false + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" }, { - "Name": "AutoAttack", - "Requirement": "not AutoAttacking", - "Cooldown": 1 + "Name": "Approach", + "Log": false } ] }, @@ -64,12 +63,8 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "N1", - "Requirement": "Health%<30", - "Cooldown": 15 + "Requirement": "Health%<30" } ] }, diff --git a/Json/class/Rogue_12.json b/Json/class/Rogue_12.json new file mode 100644 index 000000000..50205c3ee --- /dev/null +++ b/Json/class/Rogue_12.json @@ -0,0 +1,85 @@ +{ + "ClassName": "Rogue", + "Skin": true, + "PathFilename": "10_Gnome.json", + "Pull": { + "Sequence": [ + { + "Name": "Throw", + "Key": "6", + "HasCastbar": true, + "WhenUsable": true, + "WaitForWithinMeleeRange": true, + "CastIfAddsVisible": true, + "Requirements": ["HasRangedWeapon", "not InMeleeRange", "SpellInRange:1", "not Items Broken"] + } + ] + }, + "Combat": { + "Sequence": [ + { + "Name": "Evasion", + "Key": 5, + "WhenUsable": true, + "WaitBuffAfterCast": true, + "Requirement": "Health%<40" + }, + { + "Name": "Slice and Dice", + "Key": "4", + "WaitBuffAfterCast": true, + "MinEnergy": 25, + "MinComboPoints": 1, + "Requirements": ["not Slice and Dice"] + }, + { + "Name": "Eviscerate", + "Key": "3", + "MinEnergy": 35, + "MinComboPoints": 2, + "Requirements": ["TargetHealth%>20", "LastMainHandMs<500"] + }, + { + "Name": "Sinister Strike", + "Key": "2", + "MinEnergy": 42, + "Requirement": "LastMainHandMs<500" + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false + } + ] + }, + "Adhoc": { + "Sequence": [ + { + "Name": "Food", + "Key": "N1", + "Requirement": "Health%<30" + } + ] + }, + "NPC": { + "Sequence": [ + { + "Name": "Repair", + "Key": "C", + "Requirement": "Items Broken", + "PathFilename": "5_Gnome_Vendor.json", + "Cost": 6 + }, + { + "Name": "Sell", + "Key": "C", + "Requirement": "BagFull", + "PathFilename": "5_Gnome_Vendor.json", + "Cost": 6 + } + ] + } +} diff --git a/Json/class/Rogue_20.json b/Json/class/Rogue_20.json index e2485a2dd..920c215ec 100644 --- a/Json/class/Rogue_20.json +++ b/Json/class/Rogue_20.json @@ -48,7 +48,11 @@ }, { "Name": "AutoAttack", - "Cooldown": 1 + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -58,38 +62,32 @@ "Name": "potionhp", "Key": "N4", "Requirement": "Health%<5", - "Cooldown": 60, + "Cooldown": 60000, "InCombat": "true", "Log": false, "Cost": 3 }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 15 + "Requirement": "Health%<50" }, { "Name": "poisonmh", - "StopBeforeCast": true, - "DelayAfterCast": 500, + "HasCastbar": true, "Key": "N2", "Requirement": "not HasMainHandEnchant" }, { "Name": "poisonoh", - "StopBeforeCast": true, - "DelayAfterCast": 500, + "HasCastbar": true, "Key": "N3", "Requirement": "not HasOffHandEnchant" }, { "Name": "openstuff", "Key": "N5", - "Cooldown": 30, + "Cooldown": 30000, "Requirements": ["BagItem:20768:1"], "Log": false } diff --git a/Json/class/Shaman_1.json b/Json/class/Shaman_1.json index 5daaa9a98..00ce24c6a 100644 --- a/Json/class/Shaman_1.json +++ b/Json/class/Shaman_1.json @@ -9,7 +9,6 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, "MinMana": 15 } @@ -18,29 +17,34 @@ "Combat": { "Sequence": [ { - "Name": "Lightning Bolt", - "Key": "2", - "StopBeforeCast": true, + "Name": "Gift of the Naaru", + "Key": "4", "HasCastBar": true, - "MinMana": 15, - "Requirement": "not InMeleeRange" + "WhenUsable": true, + "Requirements": ["Race:Draenei", "Health%<50"] }, { "Name": "Healing Wave", "Key": "3", "Requirement": "Health%<40", - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, "MinMana": 25 }, { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 + "Name": "Lightning Bolt", + "Key": "2", + "HasCastBar": true, + "MinMana": 15, + "Requirement": "not InMeleeRange" }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -48,21 +52,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", - "Requirement": "Health%<30", - "Cooldown": 10 + "Requirement": "Health%<30" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "-", - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] } diff --git a/Json/class/Shaman_15.json b/Json/class/Shaman_15.json index aac9051b4..14f131dbe 100644 --- a/Json/class/Shaman_15.json +++ b/Json/class/Shaman_15.json @@ -15,18 +15,25 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, - "MinMana": 30, + "MinMana": 30 } ] }, "Combat": { "Sequence": [ + { + "Name": "Healing Wave", + "Key": "3", + "Requirement": "Health%<45", + "Cooldown": 5000, + "HasCastBar": true, + "Log": false, + "MinMana": 80 + }, { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, "MinMana": 30, "Requirements": [ @@ -38,23 +45,13 @@ "Name": "War Stomp", "Key": "0", "Requirements": [ + "Race:Tauren", "Health%<49", "MobCount>2" ], - "Cooldown": 120, - "Log": false, + "WhenUsable": true, "MinMana": 10 }, - { - "Name": "Healing Wave", - "Key": "3", - "StopBeforeCast": true, - "Requirement": "Health%<45", - "Cooldown": 5, - "HasCastBar": true, - "Log": false, - "MinMana": 80 - }, { "Name": "Fire shock", "Key": "4", @@ -62,7 +59,7 @@ "Mana%>40", "InMeleeRange" ], - "Cooldown": 6, + "WhenUsable": true, "Log": false, "MinMana": 80 }, @@ -70,18 +67,17 @@ "Name": "Stoneskin Totem", "Key": "7", "Requirement": "MobCount>2", - "Cooldown": 30, + "Cooldown": 30000, "Log": false, "MinMana": 30 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -89,14 +85,12 @@ "Sequence": [ { "Name": "Rockbiter Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 25, "Requirement": "not HasMainHandEnchant" }, { "Name": "Lightning Shield", - "StopBeforeCast": false, "Key": "6", "MinMana": 45, "Requirement": "not Lightning Shield" @@ -107,21 +101,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "8", - "Requirement": "Health%<40", - "Cooldown": 6 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "9", - "Requirement": "Mana%<40", - "Cooldown": 6 + "Requirement": "Mana%<40" } ] }, diff --git a/Json/class/Shaman_2.json b/Json/class/Shaman_2.json index 757545749..9a61e1db8 100644 --- a/Json/class/Shaman_2.json +++ b/Json/class/Shaman_2.json @@ -9,7 +9,6 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, "MinMana": 15 } @@ -18,26 +17,35 @@ "Combat": { "Sequence": [ { - "Name": "Lightning Bolt", - "Key": "2", - "StopBeforeCast": true, + "Name": "Gift of the Naaru", + "Key": "4", "HasCastBar": true, - "MinMana": 15, - "Requirement": "not InMeleeRange" + "WhenUsable": true, + "Requirements": ["Race:Draenei", "Health%<50"] }, { "Name": "Healing Wave", "Key": "3", "Requirement": "Health%<40", - "Cooldown": 10, + "Cooldown": 10000, "HasCastBar": true, "Log": false, "MinMana": 25 }, + { + "Name": "Lightning Bolt", + "Key": "2", + "HasCastBar": true, + "MinMana": 15, + "Requirement": "not InMeleeRange" + }, { "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not AutoAttacking"] + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -45,7 +53,6 @@ "Sequence": [ { "Name": "Rockbiter Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 15, "Requirement": "not HasMainHandEnchant" @@ -57,20 +64,12 @@ { "Name": "Food", "Key": "=", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Health%<30", - "Cooldown": 10 + "Requirement": "Health%<30" }, { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] } diff --git a/Json/class/Shaman_22.json b/Json/class/Shaman_22.json index 78ad50576..007e6fca7 100644 --- a/Json/class/Shaman_22.json +++ b/Json/class/Shaman_22.json @@ -15,19 +15,30 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, - "MinMana": 75, + "MinMana": 75 } ] }, "Combat": { "Sequence": [ + { + "Name": "Healing Wave", + "Key": "3", + "Requirements": [ + "Health%<45", + "TargetHealth%>20" + ], + "Cooldown": 5000, + "HasCastBar": true, + "Log": false, + "MinMana": 80 + }, { "Name": "Stoneclaw Totem", "Key": "7", "Requirement": "MobCount>2", - "Cooldown": 30, + "Cooldown": 30000, "Log": false, "MinMana": 30 }, @@ -35,7 +46,7 @@ "Name": "Searing Totem", "Key": "F7", "Requirement": "MobCount>2", - "Cooldown": 15, + "Cooldown": 15000, "Log": false, "MinMana": 95 }, @@ -43,17 +54,16 @@ "Name": "War Stomp", "Key": "0", "Requirements": [ + "Race:Tauren", "Health%<49", "MobCount>2" ], - "Cooldown": 120, - "Log": false, + "WhenUsable": true, "MinMana": 10 }, { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, "MinMana": 75, "Requirements": [ @@ -61,19 +71,6 @@ "Mana%>30" ] }, - { - "Name": "Healing Wave", - "Key": "3", - "StopBeforeCast": true, - "Requirements": [ - "Health%<45", - "TargetHealth%>20" - ], - "Cooldown": 5, - "HasCastBar": true, - "Log": false, - "MinMana": 80 - }, { "Name": "Fire shock", "Key": "4", @@ -81,18 +78,17 @@ "Mana%>40", "InMeleeRange" ], - "Cooldown": 6, + "WhenUsable": true, "Log": false, "MinMana": 80 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -100,14 +96,12 @@ "Sequence": [ { "Name": "Rockbiter Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 25, "Requirement": "not HasMainHandEnchant" }, { "Name": "Lightning Shield", - "StopBeforeCast": false, "Key": "6", "MinMana": 45, "Requirement": "not Lightning Shield" @@ -118,31 +112,22 @@ "Sequence": [ { "Name": "Healing Wave", - "StopBeforeCast": true, "Key": "3", "Requirement": "Health%<50", - "Cooldown": 5, + "Cooldown": 5000, "HasCastBar": true, "Log": false, "MinMana": 80 }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "8", - "Requirement": "Health%<40", - "Cooldown": 6 + "Requirement": "Health%<40" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "9", - "Requirement": "Mana%<40", - "Cooldown": 6 + "Requirement": "Mana%<40" } ] }, diff --git a/Json/class/Shaman_4.json b/Json/class/Shaman_4.json index 47695668f..f00c9430e 100644 --- a/Json/class/Shaman_4.json +++ b/Json/class/Shaman_4.json @@ -8,8 +8,16 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, + "Requirements": ["not InMeleeRange", "SpellInRange:0", "Stoneskin", "Mana%>50"], + "WaitForWithinMeleeRange": true, + "MinMana": 15 + }, + { + "Name": "Lightning Bolt", + "Key": "2", + "HasCastBar": true, + "Requirements": ["not InMeleeRange", "SpellInRange:0", "not Stoneskin", "Mana%>70"], "MinMana": 15 } ] @@ -17,28 +25,43 @@ "Combat": { "Sequence": [ { - "Name": "Earth Shock", - "Key": "6", - "Requirements": ["TargetHealth%>10", "SpellInRange:1"], - "Cooldown": 6, - "MinMana": 30 + "Name": "Gift of the Naaru", + "Key": "4", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Race:Draenei", "Health%<50"] }, { "Name": "Healing Wave", "Key": "3", - "Requirement": "Health%<40", - "Cooldown": 10, "HasCastBar": true, - "Log": false, + "WhenUsable": true, + "Requirement": "Health%<40", + "Cooldown": 5000, "MinMana": 25 }, { - "Name": "Approach", - "Log": false + "Name": "Earth Shock", + "Key": "6", + "WhenUsable": true, + "Requirements": ["TargetHealth%>10", "SpellInRange:1", "Mana%>50", "TargetHealth%>20"], + "MinMana": 30 + }, + { + "Name": "Stoneskin Totem", + "Key": "F2", + "WhenUsable": true, + "Cooldown": 30000, + "Requirements": ["InMeleeRange", "TargetHealth%>50", "Mana%>50", "BagItem:5175", "not Stoneskin"], + "MinMana": 30 }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -46,7 +69,6 @@ "Sequence": [ { "Name": "Rockbiter Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 15, "Requirement": "not HasMainHandEnchant" @@ -58,20 +80,12 @@ { "Name": "Food", "Key": "=", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Health%<30", - "Cooldown": 10 + "Requirement": "Health%<30" }, { "Name": "Water", "Key": "-", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Requirement": "Mana%<30", - "Cooldown": 10 + "Requirement": "Mana%<30" } ] }, diff --git a/Json/class/Shaman_44.json b/Json/class/Shaman_44.json index ca6ef84f5..1e59f3a15 100644 --- a/Json/class/Shaman_44.json +++ b/Json/class/Shaman_44.json @@ -13,27 +13,37 @@ { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, - "MinMana": 95, + "MinMana": 95 } ] }, "Combat": { "Sequence": [ + { + "Name": "Healing Wave", + "Key": "3", + "Requirements": [ + "Health%<40", + "TargetHealth%>15" + ], + "Cooldown": 5000, + "HasCastBar": true, + "Log": false, + "MinMana": 200 + }, { "Name": "Lightning Bolt", "Key": "2", - "StopBeforeCast": true, "HasCastBar": true, "Requirement": "not InMeleeRange", - "MinMana": 95, + "MinMana": 95 }, { "Name": "Stoneclaw Totem", "Key": "F9", "Requirement": "MobCount>2", - "Cooldown": 30, + "Cooldown": 30000, "Log": false, "MinMana": 30 }, @@ -41,7 +51,7 @@ "Name": "Searing Totem", "Key": "F7", "Requirement": "MobCount>2", - "Cooldown": 15, + "Cooldown": 15000, "Log": false, "MinMana": 95 }, @@ -49,26 +59,13 @@ "Name": "War Stomp", "Key": "0", "Requirements": [ - "Health%<45", + "Race:Tauren", + "Health%<49", "MobCount>2" ], - "Cooldown": 120, - "Log": false, + "WhenUsable": true, "MinMana": 10 }, - { - "Name": "Healing Wave", - "Key": "3", - "StopBeforeCast": true, - "Requirements": [ - "Health%<40", - "TargetHealth%>15" - ], - "Cooldown": 5, - "HasCastBar": true, - "Log": false, - "MinMana": 200 - }, { "Name": "Stormstrike", "Key": "1", @@ -77,7 +74,7 @@ "InMeleeRange" ], "Log": false, - "Cooldown": 5, + "Cooldown": 5000, "MinMana": 87 }, { @@ -88,17 +85,16 @@ "TargetHealth%>30" ], "Log": false, - "Cooldown": 12, + "WhenUsable": true, "MinMana": 80 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -106,21 +102,18 @@ "Sequence": [ { "Name": "Windfury Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 90, "Requirement": "not HasMainHandEnchant" }, { "Name": "Windfury/Falme Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 90, "Requirement": "not HasOffHandEnchant" }, { "Name": "Lightning Shield", - "StopBeforeCast": false, "Key": "7", "MinMana": 45, "Requirement": "not Lightning Shield", @@ -132,21 +125,13 @@ "Sequence": [ { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "9", - "Requirement": "Mana%<35", - "Cooldown": 6 + "Requirement": "Mana%<35" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "8", - "Requirement": "Health%<35", - "Cooldown": 6 + "Requirement": "Health%<35" } ] } diff --git a/Json/class/Shaman_55.json b/Json/class/Shaman_55.json index 1c49c1505..eabdbe320 100644 --- a/Json/class/Shaman_55.json +++ b/Json/class/Shaman_55.json @@ -13,19 +13,29 @@ }, "Combat": { "Sequence": [ + { + "Name": "Healing Wave", + "Key": "3", + "Requirements": [ + "Health%<40", + "TargetHealth%>15" + ], + "Cooldown": 5000, + "HasCastBar": true, + "Log": false, + "MinMana": 200 + }, { "Name": "Shaman Ferry", "Key": "F3", - "StopBeforeCast": false, - "HasCastBar": false, "Requirement": "Mana%<50", - "Cooldown": 120, + "Cooldown": 120000, }, { "Name": "Stoneclaw Totem", "Key": "F9", "Requirement": "MobCount>2", - "Cooldown": 30, + "Cooldown": 30000, "Log": false, "MinMana": 30 }, @@ -33,30 +43,19 @@ "Name": "Searing Totem", "Key": "F7", "Requirement": "MobCount>2", - "Cooldown": 20, + "Cooldown": 20000, "Log": false, "MinMana": 95 }, { "Name": "War Stomp", "Key": "0", - "Requirement": "Health%<50", - "Cooldown": 120, - "Log": false, - "MinMana": 10 - }, - { - "Name": "Healing Wave", - "Key": "3", - "StopBeforeCast": true, "Requirements": [ - "Health%<40", - "TargetHealth%>15" + "Race:Tauren", + "Health%<49" ], - "Cooldown": 5, - "HasCastBar": true, - "Log": false, - "MinMana": 200 + "WhenUsable": true, + "MinMana": 10 }, { "Name": "Stormstrike", @@ -66,8 +65,7 @@ "InMeleeRange" ], "Log": false, - "StopBeforeCast": true, - "Cooldown": 5, + "Cooldown": 5000, "MinMana": 87 }, { @@ -78,17 +76,16 @@ "TargetHealth%>10" ], "Log": false, - "Cooldown": 12, + "WhenUsable": true, "MinMana": 80 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -96,21 +93,18 @@ "Sequence": [ { "Name": "Windfury Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 90, "Requirement": "not HasMainHandEnchant" }, { "Name": "Windfury/Falme Weapon", - "StopBeforeCast": false, "Key": "5", "MinMana": 90, "Requirement": "not HasOffHandEnchant" }, { "Name": "Lightning Shield", - "StopBeforeCast": false, "Key": "7", "MinMana": 45, "Requirement": "not Lightning Shield", @@ -122,33 +116,24 @@ { "Name": "Healing Wave", "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", "Requirements": [ "Health%<40", "Mana%>65" ], - "Cooldown": 3, + "Cooldown": 3000, "MinMana": 310, "Cost": 6 }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "9", - "Requirement": "Mana%<45", - "Cooldown": 6 + "Requirement": "Mana%<45" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "8", - "Requirement": "Health%<45", - "Cooldown": 6 + "Requirement": "Health%<45" } ] } diff --git a/Json/class/Shaman_8.json b/Json/class/Shaman_8.json new file mode 100644 index 000000000..ebf6672b4 --- /dev/null +++ b/Json/class/Shaman_8.json @@ -0,0 +1,117 @@ +{ + "ClassName": "Shaman", + "Loot": true, + "PathFilename": "_pack\\1-20\\Draenei\\5-9_Azuremyst Isle.json", + "KillIfGivesExp": true, + "Pull": { + "Sequence": [ + { + "Name": "Lightning Bolt", + "Key": "2", + "HasCastBar": true, + "Requirements": ["not InMeleeRange", "SpellInRange:0", "Stoneskin", "Mana%>60"], + "WaitForWithinMeleeRange": true, + "MinMana": 15 + }, + { + "Name": "Lightning Bolt", + "Key": "2", + "HasCastBar": true, + "Requirements": ["not InMeleeRange", "SpellInRange:0", "not Stoneskin", "Mana%>70"], + "MinMana": 15 + } + ] + }, + "Combat": { + "Sequence": [ + { + "Name": "Gift of the Naaru", + "Key": "4", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Race:Draenei", "Health%<50"] + }, + { + "Name": "Healing Wave", + "Key": "3", + "HasCastBar": true, + "WhenUsable": true, + "Requirement": "Health%<40", + "Cooldown": 5000, + "MinMana": 25 + }, + { + "Name": "Earth Shock", + "Key": "6", + "WhenUsable": true, + "Requirements": ["TargetHealth%>10", "SpellInRange:1", "Mana%>55", "TargetHealth%>20"], + "MinMana": 30 + }, + { + "Name": "Stoneskin Totem", + "Key": "F2", + "WhenUsable": true, + "Cooldown": 30000, + "Requirements": ["InMeleeRange", "TargetHealth%>50", "Mana%>55", "BagItem:5175", "not Stoneskin"], + "MinMana": 30 + }, + { + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false + } + ] + }, + "Adhoc": { + "Sequence": [ + { + "Name": "Rockbiter Weapon", + "Key": "5", + "MinMana": 15, + "Requirement": "not HasMainHandEnchant" + }, + { + "Name": "Lightning Shield", + "Key": "7", + "MinMana": 25, + "Cooldown": 10000, + "Requirements": ["not Lightning Shield", "Mana%>50"] + } + ] + }, + "Parallel": { + "Sequence": [ + { + "Name": "Food", + "Key": "=", + "Requirement": "Health%<30" + }, + { + "Name": "Water", + "Key": "-", + "Requirement": "Mana%<30" + } + ] + }, + "NPC": { + "Sequence": [ + { + "Name": "Repair", + "Key": "C", + "Requirement": "Items Broken", + "PathFilename": "1_Draenei_Vendor.json", + "Cost": 6 + }, + { + "Name": "Sell", + "Key": "C", + "Requirement": "BagFull", + "PathFilename": "1_Draenei_Vendor.json", + "Cost": 6 + } + ] + } +} diff --git a/Json/class/Warlock.json b/Json/class/Warlock.json index b2d9daf07..41331762e 100644 --- a/Json/class/Warlock.json +++ b/Json/class/Warlock.json @@ -13,14 +13,12 @@ "Pull": { "Sequence": [ { - "Name": "pull", + "Name": "Immolate", "Key": "5", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 289, - "School": "Fire", - "Log": false + "School": "Fire" } ] }, @@ -30,15 +28,13 @@ "Name": "heal", "Key": "N3", "Requirements": ["Health%<50", "BagItem:19005:1"], - "Cooldown": 120, - "InCombat": "true", - "Log": false + "Cooldown": 120000, + "InCombat": "true" }, { "Name": "Drain Soul", "Key": "9", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["TargetHealth%<25", "not BagItem:6265:3", "TargetYieldXP"], "School": "Shadow", "MinMana": 290 @@ -47,7 +43,6 @@ "Name": "Drain Life", "Key": "N4", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["Health%<30"], "MinMana": 240 }, @@ -56,11 +51,9 @@ "Key": "5", "Requirements": ["TargetHealth%>35", "not Immolate"], "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 289, - "School": "Fire", - "Log": false + "School": "Fire" }, { "Name": "Curse of Agony", @@ -68,8 +61,7 @@ "School": "Shadow", "ResetOnNewTarget": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], - "MinMana": 50, - "Log": false + "MinMana": 50 }, { "Name": "Corruption", @@ -77,42 +69,35 @@ "Requirements": ["TargetHealth%>35", "not Corruption"], "ResetOnNewTarget": true, "MinMana": 225, - "School": "Shadow", - "Log": false + "School": "Shadow" }, { "Name": "Shadow Bolt", "Key": "2", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 309, "Requirement": "TargetHealth%>35", "School": "Shadow", - "Log": false, - "Cooldown": 8 + "Cooldown": 8000 }, { "Name": "Death Coil", "Key": "N5", "ResetOnNewTarget": true, "MinMana": 495, - "Cooldown": 120, + "Cooldown": 120000, "School": "Shadow", - "Requirements": ["Health%<80"], - "Log": false + "Requirements": ["Health%<80"] }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -121,21 +106,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<50", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<50" } ] }, @@ -145,32 +122,21 @@ "Name": "Demon Armor", "Key": "3", "MinMana": 800, - "Requirement": "not Demon Armor", - "Log": false + "Requirement": "not Demon Armor" }, { "Name": "Summon Voidwalker", "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", "MinMana": 736, "Requirements": ["BagItem:6265:1", "not Has Pet"], - "Log": false, - "Cooldown": 60 + "Cooldown": 60000 }, { "Name": "Life Tap", "Key": "8", - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false - }, - { - "Name": "Life Tap 2", - "Key": "8", - "Requirements": ["Health%>80","Mana%<80"], - "Cooldown": 0, - "Log": false + "Chage": 2, + "Requirements": ["Health%>70","Mana%<60"] }, { "Name": "heal", diff --git a/Json/class/Warlock_1.json b/Json/class/Warlock_1.json index 62c9a2c19..46eac84be 100644 --- a/Json/class/Warlock_1.json +++ b/Json/class/Warlock_1.json @@ -1,7 +1,6 @@ { "ClassName": "Warlock", "Loot": true, - "NPCMaxLevels_Below": 3, "PathFilename": "1_Gnome.json", "PathThereAndBack": true, "PathReduceSteps": false, @@ -10,9 +9,8 @@ "Sequence": [ { "Name": "Shadow Bolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 25 } ] @@ -22,22 +20,16 @@ { "Name": "Shadow Bolt", "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", "MinMana": 25 }, { - "Name": "shoot", - "StopBeforeCast": true, - "Key": "0", - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" }, { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] + "Name": "Approach", + "Log": false } ] }, @@ -45,28 +37,19 @@ "Sequence": [ { "Name": "Demon Skin", - "StopBeforeCast": false, "Key": "3", "MinMana": 50, "Requirement": "not Demon Skin" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 60 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<50", - "Cooldown": 60 + "Key": "-", + "Requirement": "Mana%<50" } ] }, diff --git a/Json/class/Warlock_10.json b/Json/class/Warlock_10.json index 1914a0e0e..db684916e 100644 --- a/Json/class/Warlock_10.json +++ b/Json/class/Warlock_10.json @@ -9,10 +9,9 @@ "Pull": { "Sequence": [ { - "Name": "pull", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Immolate", "Key": "5", + "HasCastBar": true, "MinMana": 25 } ] @@ -23,61 +22,45 @@ "Name": "Drain Soul", "Key": "9", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["TargetHealth%<25", "not BagItem:6265:3", "TargetYieldXP"], "MinMana": 55 }, { "Name": "Immolate", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "5", + "HasCastBar": true, "Requirements": ["TargetHealth%>35", "not Immolate"], - "ResetOnNewTarget": true, - "DelayAfterCast": 200, "MinMana": 25 }, { "Name": "Curse of Agony", "Key": "1", - "ResetOnNewTarget": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], - "MinMana": 25, - "StepBackAfterCast": 50, - "Log": false + "MinMana": 25 }, { "Name": "Corruption", - "HasCastBar": true, - "StopBeforeCast": true, - "DelayAfterCast": 200, "Key": "7", - "Requirements": ["TargetHealth%>35", "not Corruption"], - "ResetOnNewTarget": true, + "HasCastBar": true, + "Requirements": ["TargetHealth%>35", "not Corruption"], "MinMana": 25 }, { "Name": "Shadow Bolt", + "Key": "2", "HasCastBar": true, - "StopBeforeCast": true, "Requirement": "TargetHealth%>35", - "DelayAfterCast": 0, - "Key": "2", "MinMana": 25, - "Cooldown": 8, - "Log": false + "Cooldown": 8000 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -86,21 +69,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<40", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<40" } ] }, @@ -110,26 +85,20 @@ "Name": "Demon Skin", "Key": "3", "MinMana": 50, - "Requirement": "not Demon Skin", - "Log": false + "Requirement": "not Demon Skin" }, { "Name": "Summon Voidwalker", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", + "HasCastBar": true, "MinMana": 122, - "Requirements": ["BagItem:6265:1", "not Has Pet"], - "Log": false, - "Cooldown": 60 + "Requirements": ["BagItem:6265:1", "not Has Pet"] }, { "Name": "Life Tap", "Key": "8", "Charge": 2, - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false + "Requirements": ["Health%>70","Mana%<60"] } ] }, diff --git a/Json/class/Warlock_20.json b/Json/class/Warlock_20.json index 983151d6f..fefb5ec2c 100644 --- a/Json/class/Warlock_20.json +++ b/Json/class/Warlock_20.json @@ -12,13 +12,11 @@ "Pull": { "Sequence": [ { - "Name": "pull", + "Name": "Immolate", "Key": "5", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, - "MinMana": 90, - "Log": false + "MinMana": 90 } ] }, @@ -28,15 +26,13 @@ "Name": "heal", "Key": "N3", "Requirements": ["Health%<50", "BagItem:19005:1"], - "Cooldown": 120, - "InCombat": "true", - "Log": false + "Cooldown": 120000, + "InCombat": "true" }, { "Name": "Drain Soul", "Key": "9", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["TargetHealth%<25", "not BagItem:6265:3", "TargetYieldXP"], "MinMana": 55 }, @@ -44,7 +40,6 @@ "Name": "Drain Life", "Key": "N4", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["Health%<30"], "MinMana": 55 }, @@ -53,57 +48,48 @@ "Key": "5", "Requirements": ["TargetHealth%>35", "not Immolate"], "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, - "MinMana": 90, - "Log": false + "MinMana": 90 }, { "Name": "Curse of Agony", "Key": "1", "ResetOnNewTarget": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], - "MinMana": 50, - "Log": false + "MinMana": 50 }, { "Name": "Corruption", "Key": "7", "Requirements": ["TargetHealth%>35", "not Corruption"], "ResetOnNewTarget": true, - "MinMana": 55, - "Log": false + "MinMana": 55 }, { "Name": "Shadow Bolt", "Key": "2", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 110, "Requirement": "TargetHealth%>35", - "Log": false, - "Cooldown": 8 + "Cooldown": 8000 + }, + { + "Name": "Health Funnel", + "Key": "N6", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - }, - { - "Name": "Health Funnel", - "Key": "N6", - "HasCastBar": true, - "StopBeforeCast": true, - "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] } ] }, @@ -111,21 +97,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<40", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<40" } ] }, @@ -135,31 +113,24 @@ "Name": "Demon Armor", "Key": "3", "MinMana": 50, - "Requirement": "not Demon Armor", - "Log": false + "Requirement": "not Demon Armor" }, { "Name": "Summon Voidwalker", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", + "HasCastBar": true, "MinMana": 122, - "Requirements": ["BagItem:6265:1", "not Has Pet"], - "Log": false, - "Cooldown": 60 + "Requirements": ["BagItem:6265:1", "not Has Pet"] }, { "Name": "Life Tap", "Key": "8", "Charge": 2, - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false + "Requirements": ["Health%>70","Mana%<60"] }, { "Name": "heal", "Key": "N3", - "StopBeforeCast": true, "HasCastBar": true, "Requirements": ["BagItem:6265:1", "not BagItem:19005:1"] } diff --git a/Json/class/Warlock_20_shard_farm.json b/Json/class/Warlock_20_shard_farm.json index aaf1e69e9..bce6192a5 100644 --- a/Json/class/Warlock_20_shard_farm.json +++ b/Json/class/Warlock_20_shard_farm.json @@ -18,13 +18,10 @@ "Pull": { "Sequence": [ { - "Name": "pull", + "Name": "Immolate", "Key": "5", "HasCastBar": true, - "StopBeforeCast": true, - "ResetOnNewTarget": true, - "MinMana": 90, - "Log": false + "MinMana": 90 } ] }, @@ -35,7 +32,6 @@ "Key": "9", "School": "Shadow", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["TargetHealth%<40", "not BagItem:6265:72", "TargetYieldXP"], "MinMana": 55 }, @@ -44,7 +40,6 @@ "Key": "N4", "School": "Shadow", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["Health%<30"], "MinMana": 55 }, @@ -53,10 +48,8 @@ "Key": "5", "Requirements": ["TargetHealth%>35", "not Immolate"], "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, - "MinMana": 90, - "Log": false + "MinMana": 90 }, { "Name": "Curse of Agony", @@ -64,8 +57,7 @@ "School": "Shadow", "ResetOnNewTarget": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], - "MinMana": 50, - "Log": false + "MinMana": 50 }, { "Name": "Corruption", @@ -81,32 +73,27 @@ "Key": "2", "School": "Shadow", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 110, "Requirement": "TargetHealth%>35", - "Log": false, - "Cooldown": 8 + "Cooldown": 8000 + }, + { + "Name": "Health Funnel", + "Key": "N6", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - }, - { - "Name": "Health Funnel", - "Key": "N6", - "HasCastBar": true, - "StopBeforeCast": true, - "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] } ] }, @@ -114,21 +101,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<40", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<40" } ] }, @@ -138,26 +117,20 @@ "Name": "Demon Armor", "Key": "3", "MinMana": 50, - "Requirement": "not Demon Armor", - "Log": false + "Requirement": "not Demon Armor" }, { "Name": "Summon Voidwalker", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", + "HasCastBar": true, "MinMana": 122, - "Requirements": ["BagItem:6265:1", "not Has Pet"], - "Log": false, - "Cooldown": 60 + "Requirements": ["BagItem:6265:1", "not Has Pet"] }, { "Name": "Life Tap", "Key": "8", "Charge": 2, - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false + "Requirements": ["Health%>70","Mana%<60"] } ] } diff --git a/Json/class/Warlock_26_Immunity.json b/Json/class/Warlock_26_Immunity.json index c8606f3fc..4588d9f51 100644 --- a/Json/class/Warlock_26_Immunity.json +++ b/Json/class/Warlock_26_Immunity.json @@ -17,14 +17,12 @@ { "Name": "Immolate", "Key": "5", + "HasCastBar": true, "DelayBeforeCast": 1500, "Requirements": ["TargetHealth%>35", "not Immolate"], - "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 90, - "School": "Fire", - "Log": false + "School": "Fire" } ] }, @@ -34,15 +32,13 @@ "Name": "heal", "Key": "N3", "Requirements": ["Health%<50", "BagItem:19005:1"], - "Cooldown": 120, - "InCombat": "true", - "Log": false + "Cooldown": 120000, + "InCombat": "true" }, { "Name": "Drain Soul", "Key": "9", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["TargetHealth%<25", "not BagItem:6265:3", "TargetYieldXP"], "School": "Shadow", "MinMana": 55 @@ -51,72 +47,60 @@ "Name": "Drain Life", "Key": "N4", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["Health%<30"], "MinMana": 55 }, { "Name": "Immolate", "Key": "5", - "Requirements": ["TargetHealth%>35", "not Immolate", "not InMeleeRange"], "HasCastBar": true, - "StopBeforeCast": true, + "Requirements": ["TargetHealth%>35", "not Immolate", "not InMeleeRange"], "ResetOnNewTarget": true, "MinMana": 90, - "School": "Fire", - "Log": false + "School": "Fire" }, { "Name": "Curse of Agony", "Key": "1", "ResetOnNewTarget": true, - "StopBeforeCast": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], "MinMana": 50, - "School": "Shadow", - "Log": false + "School": "Shadow" }, { "Name": "Corruption", "Key": "7", "Requirements": ["TargetHealth%>35", "not Corruption"], "ResetOnNewTarget": true, - "StopBeforeCast": true, "MinMana": 55, - "School": "Shadow", - "Log": false + "School": "Shadow" }, { "Name": "Shadow Bolt", "Key": "2", "HasCastBar": true, - "StopBeforeCast": true, "ResetOnNewTarget": true, "MinMana": 110, "Requirements": ["TargetHealth%>35", "not InMeleeRange"], "School": "Shadow", - "Log": false, - "Cooldown": 8 + "Cooldown": 8000 + }, + { + "Name": "Health Funnel", + "Key": "N6", + "HasCastBar": true, + "WhenUsable": true, + "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] - }, - { - "Name": "Health Funnel", - "Key": "N6", - "HasCastBar": true, - "StopBeforeCast": true, - "Requirements": ["Has Pet", "Health%>70", "PetHealth%<30"] } ] }, @@ -124,21 +108,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<40", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<40" } ] }, @@ -148,32 +124,25 @@ "Name": "Demon Armor", "Key": "3", "MinMana": 275, - "Requirement": "not Demon Armor", - "Log": false + "Requirement": "not Demon Armor" }, { "Name": "Summon Voidwalker", "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", "MinMana": 122, - "Requirements": ["BagItem:6265:1", "not Has Pet"], - "Log": false, - "Cooldown": 60 + "Requirements": ["BagItem:6265:1", "not Has Pet"] }, { "Name": "Life Tap", "Key": "8", "Charge": 2, - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false + "Requirements": ["Health%>70","Mana%<60"] }, { "Name": "heal", "Key": "N3", "HasCastBar": true, - "StopBeforeCast": true, "Requirements": ["BagItem:6265:1", "not BagItem:19007:1"] } ] diff --git a/Json/class/Warlock_4.json b/Json/class/Warlock_4.json index 4eff73834..ac7345ec2 100644 --- a/Json/class/Warlock_4.json +++ b/Json/class/Warlock_4.json @@ -9,10 +9,9 @@ "Pull": { "Sequence": [ { - "Name": "pull", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Immolate", "Key": "5", + "HasCastBar": true, "MinMana": 25 } ] @@ -21,42 +20,32 @@ "Sequence": [ { "Name": "Immolate", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "5", + "HasCastBar": true, "Requirements": ["TargetHealth%>35", "not Immolate"], - "ResetOnNewTarget": true, "MinMana": 25 }, { "Name": "Corruption", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "7", + "HasCastBar": true, "Requirements": ["TargetHealth%>35", "not Corruption"], - "ResetOnNewTarget": true, "MinMana": 25 }, { "Name": "Shadow Bolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 25, - "Cooldown": 8 + "Cooldown": 8000 }, { - "Name": "shoot", - "StopBeforeCast": true, - "Key": "0", - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "Name": "AutoAttack", + "Requirement": "not AutoAttacking" }, { - "Name": "AutoAttack", - "Cooldown": 3, - "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] + "Name": "Approach", + "Log": false } ] }, @@ -66,35 +55,24 @@ "Name": "Demon Skin", "Key": "3", "MinMana": 50, - "Requirement": "not Demon Skin", - "Log": false + "Requirement": "not Demon Skin" }, { "Name": "Summon Imp", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", + "HasCastBar": true, "MinMana": 122, - "Requirement": "not Has Pet", - "Log": false + "Requirement": "not Has Pet" }, { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 60 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<50", - "Cooldown": 60 + "Key": "-", + "Requirement": "Mana%<50" } ] }, diff --git a/Json/class/Warlock_8.json b/Json/class/Warlock_8.json index 5d477b227..55486d517 100644 --- a/Json/class/Warlock_8.json +++ b/Json/class/Warlock_8.json @@ -9,10 +9,9 @@ "Pull": { "Sequence": [ { - "Name": "pull", - "HasCastBar": true, - "StopBeforeCast": true, + "Name": "Immolate", "Key": "5", + "HasCastBar": true, "MinMana": 25 } ] @@ -21,49 +20,40 @@ "Sequence": [ { "Name": "Immolate", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "5", + "HasCastBar": true, "Requirements": ["TargetHealth%>35", "not Immolate"], - "ResetOnNewTarget": true, "MinMana": 25 }, { "Name": "Curse of Agony", "Key": "1", - "ResetOnNewTarget": true, "Requirements": [ "TargetHealth%>35", "not Curse of Agony"], "MinMana": 25, "Log": false }, { "Name": "Corruption", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "7", - "Requirements": ["TargetHealth%>35", "not Corruption"], - "ResetOnNewTarget": true, + "HasCastBar": true, + "Requirements": ["TargetHealth%>35", "not Corruption"], "MinMana": 25 }, { "Name": "Shadow Bolt", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "2", + "HasCastBar": true, "MinMana": 25, - "Cooldown": 8 + "Cooldown": 8000 }, { - "Name": "shoot", + "Name": "Shoot", "Key": "0", - "StopBeforeCast": true, - "Cooldown": 3, - "Requirements": ["HasRangedWeapon", "not Shooting"], - "Log": false + "HasCastbar": true, + "Requirements": ["HasRangedWeapon", "not Shooting", "SpellInRange:1"] }, { "Name": "AutoAttack", - "Cooldown": 3, "Requirements": ["not HasRangedWeapon", "not AutoAttacking"] } ] @@ -72,21 +62,13 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N1", - "Requirement": "Health%<50", - "Cooldown": 20 + "Key": "=", + "Requirement": "Health%<50" }, { "Name": "Water", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, - "Key": "N2", - "Requirement": "Mana%<40", - "Cooldown": 20 + "Key": "-", + "Requirement": "Mana%<40" } ] }, @@ -96,26 +78,20 @@ "Name": "Demon Skin", "Key": "3", "MinMana": 50, - "Requirement": "not Demon Skin", - "Log": false + "Requirement": "not Demon Skin" }, { "Name": "Summon Imp", - "HasCastBar": true, - "StopBeforeCast": true, "Key": "4", + "HasCastBar": true, "MinMana": 122, - "Requirement": "not Has Pet", - "Log": false + "Requirement": "not Has Pet" }, { "Name": "Life Tap", - "StopBeforeCast": true, "Key": "8", "Charge": 2, - "Requirements": ["Health%>70","Mana%<60"], - "Cooldown": 0, - "Log": false + "Requirements": ["Health%>70","Mana%<60"] } ] }, diff --git a/Json/class/Warrior.json b/Json/class/Warrior.json index c943f1978..e38c83ece 100644 --- a/Json/class/Warrior.json +++ b/Json/class/Warrior.json @@ -24,7 +24,7 @@ { "Name": "Bloodrage", "Key": "2", - "Cooldown": 60 + "Cooldown": 60000 }, { "Name": "Battle Shout", @@ -36,14 +36,14 @@ "Name": "Overpower", "Key": "5", "MinRage": 5, - "Cooldown": 10 + "Cooldown": 10000 }, { "Name": "Rend", "Key": "3", "MinRage": 10, "Requirement": "not Rend", - "Cooldown": 5 + "Cooldown": 5000 }, { "Name": "Heroic Strike", @@ -51,14 +51,13 @@ "AfterCastWaitNextSwing": true, "MinRage": 10 }, - { - "Name": "Approach", - "Requirement": "not InMeleeRange", - "Cooldown": 1 - }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -68,24 +67,20 @@ "Name": "Healing Potion", "Key": "F4", "Requirement": "Health%<5", - "Cooldown": 60, + "Cooldown": 60000, "InCombat": "true", "Log": false, "Cost": 3 }, { - "Name": "Eat", - "StopBeforeCast": false, + "Name": "Food", "Key": "=", "Requirement": "Health%<60", - "Cooldown": 0, - "DelayAfterCast": 1000, - "Log": false, "Cost": 3 }, { "Name": "Well Fed", - "StopBeforeCast": false, + "StopBeforeCast": true, "Key": "7", "Requirement": "not Well Fed", "Cooldown": 1200, @@ -94,7 +89,6 @@ { "Name": "Sharpen Weapon 1", "HasCastBar": true, - "StopBeforeCast": true, "Key": "F1", "Cooldown": 1800, "Log": false diff --git a/Json/class/Warrior_1.json b/Json/class/Warrior_1.json index 912e0eafe..3f0ec32a3 100644 --- a/Json/class/Warrior_1.json +++ b/Json/class/Warrior_1.json @@ -8,15 +8,15 @@ "Key": "2", "AfterCastWaitNextSwing": true, "WhenUsable": true, - "MinRage": 10 - }, - { - "Name": "Approach", - "Log": false + "MinRage": 15 }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -24,12 +24,8 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", "Requirement": "Health%<60", - "Cooldown": 5, "Cost": 3 } ] diff --git a/Json/class/Warrior_4.json b/Json/class/Warrior_4.json index 97876e8a1..cebbfb3cd 100644 --- a/Json/class/Warrior_4.json +++ b/Json/class/Warrior_4.json @@ -7,8 +7,12 @@ "Name": "Charge", "Key": "3", "Form": "Warrior_BattleStance", - "WhenUsable": true, - "Cooldown": 15 + "Requirement": "not InMeleeRange", + "WhenUsable": true + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -27,7 +31,7 @@ "Key": "5", "WhenUsable": true, "Requirement": "TargetHealth%>90", - "Cooldown": 60, + "Form": "Warrior_BattleStance", "MinRage": 10 }, { @@ -35,15 +39,15 @@ "Key": "2", "AfterCastWaitNextSwing": true, "WhenUsable": true, - "MinRage": 10 - }, - { - "Name": "Approach", - "Log": false + "MinRage": 15 }, { "Name": "AutoAttack", "Requirement": "not AutoAttacking" + }, + { + "Name": "Approach", + "Log": false } ] }, @@ -51,12 +55,8 @@ "Sequence": [ { "Name": "Food", - "StopBeforeCast": true, - "AfterCastWaitBuff": true, - "DelayAfterCast": 0, "Key": "=", "Requirement": "Health%<60", - "Cooldown": 5, "Cost": 3 } ] diff --git a/Json/path/1_NightElf_Vendor.json b/Json/path/1_NightElf_Vendor.json index eb63ebe55..d4dd95eee 100644 --- a/Json/path/1_NightElf_Vendor.json +++ b/Json/path/1_NightElf_Vendor.json @@ -1 +1 @@ -[{"X":60.184000000000005,"Y":42.74},{"X":60.106,"Y":42.564},{"X":60.021,"Y":42.38},{"X":59.940000000000005,"Y":42.197},{"X":59.855000000000004,"Y":42.015},{"X":59.763999999999996,"Y":41.835},{"X":59.675,"Y":41.657},{"X":59.582,"Y":41.478},{"X":59.487,"Y":41.313},{"X":59.378,"Y":41.163}] \ No newline at end of file +[{"X":60.184000000000005,"Y":42.74},{"X":59.487,"Y":41.313},{"X":59.378,"Y":41.163}] \ No newline at end of file diff --git a/README.md b/README.md index 0f4d465d6..cd4cb33fb 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,16 @@ and copy next to the common-2.MPQ file. 1. Nvidia Control panel settings * Make sure the `Image Sharpening` under the `Manage 3D Settings`-> Global settings or Program Settings(for WoW) is set to `Sharpening Off, Scaling disabled`! +## 3.2 Optional - Replace default game Font + +I would highly suggest to replace the default World of Warcraft font with a much **Bolder** one. + +Follow this guide (https://classic.wowhead.com/guides/changing-wow-text-font) + +Should be only concerned about `Friz Quadrata: the "Everything Else" Font` which is the `FRIZQT__.ttf` named file. + +By replacing the default with for example - `Robot-Medium` https://fonts.google.com/specimen/Roboto?thickness=5) - you can highly increase the success rate of the `NpcNameFinder` compontent which is responsible to find - friendly, enemy, corpse - names above NPCs head. + ## 4. Build the bot You will probably already have Visual Studio or Visual Studio Code installed. You need to build the bot using either one of them, or use powershell. @@ -190,14 +200,14 @@ From the main menu (ESC) set the following: ## 7.1. Actionbar Key Bindings: The default class profiles assumes the following `Keybinds` setup and using English Keyboard layout. -In total, `32` key supported. +In total, `34` key supported. Highly recommended to use the default setup, in order to get properly working the `ActionBarSlotCost` and `ActionBarSlotUsable` features! https://wowwiki-archive.fandom.com/wiki/ActionSlot | ActionSlot | Key | Description | | --- | --- | --- | -| 1-10 | 1,2,3 .. 9,0 | 0 is the 10th key | +| 1-10 | 1,2,3 .. 9,0,-,= | 0 is the 10th key. | | Bottom Right ActionBar | - | - | | 49-58 | N1,N2,N3 .. N9,N0 | N means Numpad - 0 is the 10th key | | Bottom Left ActionBar | - | - | @@ -256,7 +266,7 @@ e.g. "Key": "3", "MinEnergy": 25, "MinComboPoints": 2, - "Cooldown": 3, + "Cooldown": 3000, "Requirement": "Slice And Dice" }, @@ -272,12 +282,12 @@ Commands have the following parameters, only a subset will be used by each comma | ShapeShiftForm | For druids the shapeshift form to be in to cast this spell | None | | CastIfAddsVisible | If the bot can "See" any adds | false | | Charge | How many times shoud this Command be used in sequence and ignore its Cooldown | 1 | -| Cooldown | The cooldown in seconds until the command can be done again | 0 | +| Cooldown | The cooldown in milliseconds until the command can be done again | 0 | | MinMana | (Optional) The minimum Mana required to cast the spell | 0 | | MinRage | (Optional) The minimum Rage required to cast the spell | 0 | | MinEnergy | (Optional) The minimum Energy required to cast the spell | 0 | | MinComboPoints | The minimum combo points required to cast the spell | 0 | -| WhenUsable | When not in cooldown and have the min resource(mana,rage,energy) to use it. | false | +| WhenUsable | When not in cooldown(GCD included) and have the min resource(mana,rage,energy) to use it. | false | | Requirement | A single "Requirement" (See below) which must be true | | | Requirements | A list of "Requirements" which must be true | | | WaitForWithinMelleRange| Wait after casting for the mob to be in melee range | false | @@ -335,27 +345,17 @@ The "Key" is a key that is bound to a macro. The macro needs to target the NPC, Sell macro example bound to the "C" key using BindPad or Key bindings. /tar Jannos Ironwill - /run DataToColor:sell({"Light Leather","Cheese","Light Feather"}); + /run DataToColor[1]:sell({"Light Leather","Cheese","Light Feather"}); Repair macro example: /tar Vargus /script SelectGossipOption(1) -Spammable wand macro `shoot` in many profiles - - /#showtooltip - /cast !shoot - -Warlock `pull` macro used in warlock profiles - - #showtooltip - /cast Immolate - Warlock `heal` macro used in warlock profiles. #showtooltip - /cast Create Healthstone + /cast [nocombat] Create Healthstone /use Minor Healthstone /use Lesser Healthstone /use Healthstone @@ -363,10 +363,6 @@ Warlock `heal` macro used in warlock profiles. /use Major Healthstone /use Master Healthstone -Hunter `autoshot` spammable Auto Shoot macro - - #showtooltip - /cast !Auto Shot Hunter `feedpet` macro replace `Roasted Quail` with the proper diet @@ -422,11 +418,10 @@ e.g. { "Name": "Curse of Weakness", "Key": "6", - "Cooldown": 10, + "WhenUsable": true, "ResetOnNewTarget": true, "Requirement": "not Curse of Weakness", <--- Single Requirement - "MinMana": 20, - "Log": false + "MinMana": 20 }, #### Value base requirements @@ -494,6 +489,66 @@ e.g. * "not BagItem:19007:1" - Must have a lesser Healthstone in the bag https://classic.wowhead.com/item=19007 * "not BagItem:6265:3"- Must not have 3 soulshards in the bag. +#### Form requirements + +If the character must be - in or not - the specified `Form` use this requirement. Useful to determine when to switch Form for the given situation. + +It has the format `Form:Form` + +e.g. +* "Form:Druid_Bear" - Must be in `Druid_Bear` form +* "not Form:Druid_Cat" - Shoudn't be in `Druid_Cat` form + +| Form | +| --- | +| None +| Druid_Bear | +| Druid_Aquatic | +| Druid_Cat | +| Druid_Travel | +| Druid_Moonkin | +| Druid_Flight | +| Druid_Cat_Prowl | +| Priest_Shadowform | +| Rogue_Stealth | +| Rogue_Vanish | +| Shaman_GhostWolf | +| Warrior_BattleStance | +| Warrior_DefensiveStance | +| Warrior_BerserkerStance | +| Paladin_Devotion_Aura | +| Paladin_Retribution_Aura | +| Paladin_Concentration_Aura | +| Paladin_Shadow_Resistance_Aura | +| Paladin_Frost_Resistance_Aura | +| Paladin_Fire_Resistance_Aura | +| Paladin_Crusader_Aura | + +#### Race requirements + +If the character must be - or not - the specified `Race` use this requirement. Useful to determine Racial abilities. + +It has the format `Race:Race` + +e.g. +* "Race:Orc" - Must be `Orc` race +* "not Race:Human" - Shoudn't be `Human` race + +| Race | +| --- | +| None | +| Human | +| Orc | +| Dwarf | +| NightElf | +| Undead | +| Tauren | +| Gnome | +| Troll | +| Goblin | +| BloodElf | +| Draenei | + #### Buff / Debuff Allow requirements about what buffs you have or the target has to be evaluated. @@ -571,6 +626,7 @@ e.g. | Shaman | "Lightning Shield" | | Shaman | "Water Shield" | | Shaman | "Shamanistic Focus" | +| Shaman | "Stoneskin" | | Hunter | "Aspect of the Cheetah" | | Hunter | "Aspect of the Pack" | | Hunter | "Aspect of the Beast" | @@ -606,7 +662,6 @@ Allow requirements about spell range to be used, the spell in question depends u e.g. "Requirement": "SpellInRange:4" e.g. "Requirements": ["Health%<80", "SpellInRange:4"] -In the Addon DataToColor.lua is function DataToColor:areSpellsInRange() this tries to get a list of spells unique to each class that are in range. This is read by Libs.SpellInRange.cs. | Class | Spell | id | | --- | --- | --- | @@ -624,9 +679,10 @@ In the Addon DataToColor.lua is function DataToColor:areSpellsInRange() this tri | WARRIOR | Shoot Gun | 2 | | --- | --- | --- | | PRIEST | Shadow Word: Pain | 0 | -| PRIEST | Mind Blast | 1 | +| PRIEST | Shoot | 1 | | PRIEST | Mind Flay | 2 | -| PRIEST | Shoot | 3 | +| PRIEST | Mind Blast | 3 | +| PRIEST | Smite | 4 | | --- | --- | --- | | PALADIN | Judgement | 0 | | --- | --- | --- | diff --git a/SharedLib/NpcFinder/NpcNameFinder.cs b/SharedLib/NpcFinder/NpcNameFinder.cs index 393fa1719..fbdc910fe 100644 --- a/SharedLib/NpcFinder/NpcNameFinder.cs +++ b/SharedLib/NpcFinder/NpcNameFinder.cs @@ -1,4 +1,4 @@ -using SharedLib.Extensions; +using SharedLib.Extensions; using Microsoft.Extensions.Logging; using System; using System.Collections.Generic; @@ -38,6 +38,8 @@ public class NpcNameFinder public List Npcs { get; private set; } = new List(); public int NpcCount => npcs.Count; + public int AddCount { private set; get; } + public int TargetCount { private set; get; } public bool MobsVisible => npcs.Count > 0; public bool PotentialAddsExist { get; private set; } public DateTime LastPotentialAddsSeen { get; private set; } = default; @@ -146,19 +148,20 @@ public void Update() public void UpdatePotentialAddsExist() { - var countAdds = Npcs.Where(c => c.IsAdd).Where(c => c.Height > ScaleHeight(2)).Count(); - var MobsVisible = Npcs.Where(c => c.Height > ScaleHeight(2)).Any(); + TargetCount = Npcs.Where(c => !c.IsAdd && Math.Abs(c.ClickPoint.X - c.screenMid) < c.screenTargetBuffer).Count(); + AddCount = Npcs.Where(c => c.IsAdd).Count(); - if (countAdds > 0) + if (AddCount > 0 || TargetCount > 1) { PotentialAddsExist = true; LastPotentialAddsSeen = DateTime.Now; } else { - if (PotentialAddsExist && (DateTime.Now - LastPotentialAddsSeen).TotalSeconds > 2) + if (PotentialAddsExist && (DateTime.Now - LastPotentialAddsSeen).TotalSeconds > 1) { PotentialAddsExist = false; + AddCount = 0; } } } @@ -262,10 +265,24 @@ public void ShowNames(Graphics gr) { return; } - using (var whitePen = new Pen(Color.White, 3)) + + using var whitePen = new Pen(Color.White, 3); + using var greyPen = new Pen(Color.Gray, 3); + + /* + if (Npcs.Any()) { - Npcs.ForEach(n => gr.DrawRectangle(whitePen, new Rectangle(n.Min, new Size(n.Width, n.Height)))); + // target area + gr.DrawLine(whitePen, new Point(Npcs[0].screenMid - Npcs[0].screenTargetBuffer, Area.Top), new Point(Npcs[0].screenMid - Npcs[0].screenTargetBuffer, Area.Bottom)); + gr.DrawLine(whitePen, new Point(Npcs[0].screenMid + Npcs[0].screenTargetBuffer, Area.Top), new Point(Npcs[0].screenMid + Npcs[0].screenTargetBuffer, Area.Bottom)); + + // adds area + gr.DrawLine(greyPen, new Point(Npcs[0].screenMid - Npcs[0].screenAddBuffer, Area.Top), new Point(Npcs[0].screenMid - Npcs[0].screenAddBuffer, Area.Bottom)); + gr.DrawLine(greyPen, new Point(Npcs[0].screenMid + Npcs[0].screenAddBuffer, Area.Top), new Point(Npcs[0].screenMid + Npcs[0].screenAddBuffer, Area.Bottom)); } + */ + + Npcs.ForEach(n => gr.DrawRectangle(n.IsAdd ? greyPen : whitePen, new Rectangle(n.Min, new Size(n.Width, n.Height)))); } public Point ToScreenCoordinates(int x, int y) diff --git a/SharedLib/NpcFinder/NpcPosition.cs b/SharedLib/NpcFinder/NpcPosition.cs index 6b1c178b8..628de5b07 100644 --- a/SharedLib/NpcFinder/NpcPosition.cs +++ b/SharedLib/NpcFinder/NpcPosition.cs @@ -12,22 +12,28 @@ public class NpcPosition public int Height => Max.Y - Min.Y; public int Width => Max.X - Min.X; - private readonly int screenMid; - private readonly int screenMidBuffer; + public readonly int screenMid; + public readonly int screenTargetBuffer; + public readonly int screenMidBuffer; + public readonly int screenAddBuffer; private readonly float yOffset; private readonly float heightMul; - public bool IsAdd => ClickPoint.X < screenMid - screenMidBuffer || ClickPoint.X > screenMid + screenMidBuffer; + public bool IsAdd => + (ClickPoint.X < screenMid - screenTargetBuffer && ClickPoint.X > screenMid - screenAddBuffer) || + (ClickPoint.X > screenMid + screenTargetBuffer && ClickPoint.X < screenMid + screenAddBuffer); public Point ClickPoint => new Point(Min.X + (Width / 2), (int)(Max.Y + yOffset + (Height * heightMul))); public NpcPosition(Point min, Point max, int screenWidth, float yOffset, float heightMul) { - this.Min = min; - this.Max = max; - this.screenMid = screenWidth / 2; - this.screenMidBuffer = screenWidth / 10; + Min = min; + Max = max; + screenMid = screenWidth / 2; + screenMidBuffer = screenWidth / 15; + screenTargetBuffer = screenMidBuffer / 2; + screenAddBuffer = screenMidBuffer * 3; this.yOffset = yOffset; this.heightMul = heightMul;