local WHITE = "|cffffffff" local SILVER = "|cffc0c0c0" local GREEN = "|cff00ff00" local LTBLUE = "|cffa0a0ff" function DIYCE_DebugSkills(skillList) DEFAULT_CHAT_FRAME:AddMessage(GREEN.."Skill List:") for i,v in ipairs(skillList) do DEFAULT_CHAT_FRAME:AddMessage(SILVER.." ["..WHITE..i..SILVER.."]: "..LTBLUE.."\" "..WHITE..v.name..LTBLUE.."\" use = "..WHITE..(v.use and "true" or "false")) end DEFAULT_CHAT_FRAME:AddMessage(GREEN.."----------") end function DIYCE_DebugBuffList(buffList) DEFAULT_CHAT_FRAME:AddMessage(GREEN.."Buff List:") for k,v in pairs(buffList) do -- We ignore numbered entries because both the ID and name -- are stored in the list. This avoids doubling the output. if type(k) ~= "number" then DEFAULT_CHAT_FRAME:AddMessage(SILVER.." ["..WHITE..k..SILVER.."]: "..LTBLUE.."id: "..WHITE..v.id..LTBLUE.." stack: "..WHITE..v.stack..LTBLUE.." time: "..WHITE..v.time) end end DEFAULT_CHAT_FRAME:AddMessage(GREEN.."----------") end local silenceList = { ["Annihilation"] = true, ["King Bug Shock"] = true, ["Mana Rift"] = true, ["Dream of Gold"] = true, ["Flame"] = true, ["Flame Spell"] = true, ["Wave Bomb"] = true, ["Silence"] = true, ["Recover"] = true, ["Restore Life"] = true, ["Heal"] = true, ["Curing Shot"] = true, ["Leaves of Fire"] = true, ["Urgent Heal"] = true, ["Heavy Shelling"] = true, --Juggler Apprentice in Grafu ["Dark Healing"] = true, --Mini-boss in Sardo } function PriestFairySequence(arg1) local Skill = {} local Skill2 = {} local i = 0 local FairyExists = UnitExists("playerpet") local FairyBuffs = BuffList("playerpet") local combat = GetPlayerCombatState() --Determine Class-Combo mainClass, subClass = UnitClassToken( "player" ) --Summon Fairy if (not FairyExists) and (not combat) then if mainClass == "AUGUR" then if subClass == "THIEF" then Skill = { { name = "Shadow Fairy", use = true }, } elseif subClass == "RANGER" then Skill = { { name = "Water Fairy", use = true }, } elseif subClass == "MAGE" then Skill = { { name = "Wind Fairy", use = true }, } elseif subClass == "KNIGHT" then Skill = { { name = "Light Fairy", use = true }, } elseif subClass == "WARRIOR" then Skill = { { name = "Fire Fairy", use = true }, } end end end --Cast Halo if FairyExists then if mainClass == "AUGUR" then if subClass == "THIEF" then if (not FairyBuffs[503459]) then if (arg1 == "v1") then Msg("- Activating Halo", 0, 1, 1) end Skill = { { name = "Pet Skill: 6 (Wraith Halo)", use = true }, } end elseif subClass == "RANGER" then if (not FairyBuffs[503457]) then if (arg1 == "v1") then Msg("- Activating Halo", 0, 1, 1) end Skill = { { name = "Pet Skill: 6 (Frost Halo)", use = true }, } end elseif subClass == "MAGE" then if (not FairyBuffs[503461]) then if (arg1 == "v1") then Msg("- Activating Halo", 0, 1, 1) end Skill = { { name = "Pet Skill: 6 (Windrider Halo)", use = true }, } end elseif subClass == "KNIGHT" then if (not FairyBuffs[503507]) then if (arg1 == "v1") then Msg("- Activating Halo", 0, 1, 1) end Skill = { { name = "Pet Skill: 6 (Devotion Halo)", use = true }, } end elseif subClass == "WARRIOR" then if (not FairyBuffs[503455]) then if (arg1 == "v1") then Msg("- Activating Halo", 0, 1, 1) end Skill = { { name = "Pet Skill: 6 (Accuracy Halo)", use = true }, } end end --Cast Conceal if (not MyCombat(Skill, arg1)) then if (not FairyBuffs[503753]) then if (arg1 == "v1") then Msg("- Activating Conceal", 0, 1, 1) end Skill2 = { { name = "Pet Skill: 7 (Conceal)", use = true }, } end end end end if (not MyCombat(Skill, arg1)) then MyCombat(Skill2, arg1) end end function KillSequence(arg1, goat2, healthpot, manapot, foodslot) --arg1 = "v1" or "v2" for debugging --healthpot = # of actionbar slot for health potions --manapot = # of actionbar slot for mana potions --foodslot = # of actionbar slot for food (add more args for more foodslots if needed) local Skill = {} local Skill2 = {} local i = 0 -- Player and target status. local combat = GetPlayerCombatState() local enemy = UnitCanAttack("player","target") local EnergyBar1 = UnitMana("player") local EnergyBar2 = UnitSkill("player") local pctEB1 = PctM("player") local pctEB2 = PctS("player") local tbuffs = BuffList("target") local pbuffs = BuffList("player") local tDead = UnitIsDeadOrGhost("target") local behind = (not UnitIsUnit("player", "targettarget")) local melee = GetActionUsable(2) -- # is your melee range spell slot number local a1,a2,a3,a4,a5,ASon = GetActionInfo(14) -- # is your Autoshot slot number local phealth = PctH("player") local thealth = PctH("target") local LockedOn = UnitExists("target") local boss = UnitSex("target") > 2 local elite = UnitSex("target") == 2 local party = GetNumPartyMembers() >= 2 --Determine Class-Combo mainClass, subClass = UnitClassToken( "player" ) --Silence Logic local tSpell,tTime,tElapsed = UnitCastingTime("target") local silenceThis = tSpell and silenceList[tSpell] and ((tTime - tElapsed) > 0.1) --Potion Checks healthpot = healthpot or 0 manapot = manapot or 0 --Equipment and Pet Protection if phealth <= .03 then SwapEquipmentItem() --Note: Remove the first double dash to re-enable equipment protection. for i=1,6 do if (IsPetSummoned(i) == true) then ReturnPet(i); end end end --Check for level 1 mobs, if it is, drop target and acquire a new one. if (LockedOn and (UnitLevel("target") < 2)) then TargetUnit("") return end --Begin Player Skill Sequences --Priest = AUGUR, Druid = DRUID, Mage = MAGE, Knight = KNIGHT, --Scout = RANGER, Rogue = THIEF, Warden = WARDEN, Warrior = WARRIOR -- Class: Rogue/Scout if mainClass == "THIEF" and subClass == "RANGER" then --Timers for this class CreateDIYCETimer("SSBleed", 6.5) --Change the value between 6 -> 7.5 depending on your lag. CreateDIYCETimer("LBBleed", 8.5) --Change the value between 7 -> 8.5 depending on your lag. --goat2: 0 = Buffs, 1 = Melee, 2 = Ranged, 3 = Cooldowns & Potions, 4 = Longer Cooldowns if (goat2 == "0") then Skill = { { name = "Combat Master", use = ((not pbuffs["Combat Master"])) }, { name = "Action: 62 (Yawaka's Blessing)", use = ((not pbuffs["Yawaka's Blessing"])) }, { name = "Action: 69 (Unbridled Enthusiam)", use = ((not pbuffs["Unbridled Enthusiasm"])) }, -- Speed Potion } elseif (goat2 == "3") then Skill = { { name = "Informer", use = ((not pbuffs["Informer"])) }, { name = "Action: 64 (Unknown Choice)", use = ((EnergyBar1 > 20)) }, { name = "Action: 65 (Caviar Sandwich)", use = ((not pbuffs["Caviar Sandwich"])) }, } elseif (goat2 == "4") then Skill = { { name = "Action: 46 (Energy Potion)", use = ((EnergyBar1) <= 15 and (boss)) }, { name = "Action: 30 (Strong Stimulant)", use = ((boss) and (not pbuffs["Fervent Attack"])) }, { name = "Action: 34 (Extinction Potion)", use = ((boss) and (not pbuffs["Extinction Potion"])) }, { name = "Energy Thief", use = ((EnergyBar1 < 50) and (boss) and (not tDead)) }, { name = "Assassins Rage", use = ((boss) and (not tDead)) }, { name = "Fervent Attack", use = ((boss) and (not tDead) and (not pbuffs["Strong Stimulant"])) }, } end if ((enemy) and (goat2 == "1")) then Skill2 = { { name = "Wound Attack", use = ((EnergyBar1 >= 35) and ((tbuffs[500654]) and (tbuffs[500704]))) }, { name = "Blind Spot", use = (((EnergyBar1 >= 25) and (boss) and (behind)) and (pbuffs["Energy Thief"] or pbuffs["Premeditation"])) }, { name = "Shadowstab", use = (EnergyBar1 >= 20), timer = "SSBleed" }, { name = "Low Blow", use = (((EnergyBar1 >= 25) and (tbuffs[500654])) or (tbuffs["Energy Thief"])), timer = "LBBleed", ignoretimer = not tbuffs["Energy Thief"] }, { name = "Throat Attack", use = ((EnergyBar2 >= 50) and (boss or elite) and (silenceThis)) }, { name = "Vampire Arrows", use = (EnergyBar2 >= 20) }, { name = "Wrist Attack", use = ((EnergyBar2 >= 50) and (boss)) }, { name = "Shot", use = ((EnergyBar1 < 20 )) }, } elseif ((enemy) and (goat2 == "2")) then Skill2 = { { name = "Vampire Arrows", use = (EnergyBar2 >= 20) }, { name = "Shot", use = (true) }, } end --ADD MORE CLASS COMBOS HERE. --USE AN "ELSEIF" TO CONTINUE WITH MORE CLASS COMBOS. --THE NEXT "END" STATEMENT IS THE END OF THE CLASS COMBOS STATEMENTS. --DO NOT POST BELOW THE FOLLOWING "END" STATEMENT! end --End Player Skill Sequences if (arg1=="debugskills") then --Used for printing the skill table, and true/false usability DIYCE_DebugSkills(Skill) DIYCE_DebugSkills(Skill2) elseif (arg1=="debugpbuffs") then --Used for printing your buff names, and buffID DIYCE_DebugBuffList(pbuffs) elseif (arg1=="debugtbuffs") then --Used for printing target buff names, and buffID DIYCE_DebugBuffList(tbuffs) elseif (arg1=="debugall") then --Used for printing all of the above at the same time DIYCE_DebugSkills(Skill) DIYCE_DebugSkills(Skill2) DIYCE_DebugBuffList(pbuffs) DIYCE_DebugBuffList(tbuffs) end if (not MyCombat(Skill, arg1)) then MyCombat(Skill2, arg1) end --Select Next Enemy if (tDead) then TargetUnit("") return end if (mainClass == "RANGER" or subClass == "RANGER") and (not party) then --To keep scouts from pulling mobs without meaning to. if (not LockedOn) or (not enemy) then TargetNearestEnemy() return end elseif mainClass ~= "RANGER" then --Let all other classes auto target. if (not LockedOn) or (not enemy) then TargetNearestEnemy() return end end end