|
|
Source code |
1 |
{ name = "The Final Battle", use = CD("The Final Battle") and (thealth < 30 ) }
|
Quoted from "eguner;519141"
im using the line below in my customfunctions.lua file, i want to use this skill when target health is below 30% , can anyone help me fix this code please?
![]()
Source code
1{ name = "The Final Battle", use = CD("The Final Battle") and (thealth < 30 ) }
this line works but no the target hp percentage check
|
|
Source code |
1 |
use = CD("The Final Battle")
|
|
|
Source code |
1 |
{ name = "The Final Battle", use = (EnergyBar1 >= 25) and (thealth < .30) }
|
Quoted from "BloodyArrow;520438"
Hey!
I am currently using diyce for my R/S combo which goes SS>LB/WA and spam LB when WA is under CD etc etc. Now I took my third class which is Knight. So my question here is, how should I set up my rotation now for max dps and dmg? Considering on Disarm got nerfed with the 3 secs CD I cant have it SS>Disarm>LB>Disarm>Disarm>Wound which once was great..
And please come with more suggestions for which skills to use in my rotation to even more improve my dps/dmg.
Thanks in advance ~ B
|
|
Source code |
1 |
local pbpot = GetBagItemCount(200762) >= 1 -- check if you have Poison Bottle |
|
|
Source code |
1 |
{ name = "Poison", use = ((not pbuffs['Poisonous']) and (pbpot)) },
|
|
|
Source code |
1 2 |
local uepot = GetBagItemCount(207200) >= 1 -- check if you have Unbridled Enthusiasm potion local ctpot = GetBagItemCount(207202) >= 1 -- check if you have Clear Thought potion |
|
|
Source code |
1 2 |
{ name = "Item: Potion: Unbridled Enthusiasm", use = ((not pbuffs['Unbridled Enthusiasm']) and (uepot)) },
{ name = "Item: Potion: Clear Thought", use = ((not pbuffs['Clear Thought']) and (ctpot)) },
|

|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
-- The potion list
local PotionList = {
['Unbridled Enthusiasm'] = 207200,
['Clear Thought'] = 207202,
}
-- The support function
function CheckPotions()
for potname,potid in pairs(PotionList) do
if GetBagItemCount(potid) >= 1 then
return potname,potid
end
end
-- no pots found, return nil
return "",nil
end
|
|
|
Source code |
1 2 3 4 5 |
-- At start of KillSequence, right after the local stuff
local potname, potid = CheckPotions()
-- in the skill
{ name = "Item: Potion: "..potname, use = potid and not pbuffs[potname] },
|
|
|
Source code |
1 |
[string '?']:32: bad argument #1 to 'pairs' (table expected, got nil) |
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 |
-- The support functionfunction CheckPotions()
for potname, potid in pairs(PotionList) do -- this is 32 line
if GetBagItemCount(potid) >= 1 then
return potname,potid
end
end
-- no pots found, return nil
return "",nil
end
|
Quoted from "krssrb;520517"
i tryed this, but it returs me an error
![]()
Source code
1 [string '?']:32: bad argument #1 to 'pairs' (table expected, got nil)
Quoted from "krssrb;520517"
![]()
Source code
1 2 3 4 5 6 7 8 9 10 11-- The support functionfunction CheckPotions() for potname, potid in pairs(PotionList) do -- this is 32 line if GetBagItemCount(potid) >= 1 then return potname,potid end end -- no pots found, return nil return "",nil end
|
|
Source code |
1 2 |
-- The support function function CheckPotions() |
|
|
Source code |
1 2 3 4 5 6 7 8 |
{ name = "Shadow Step", use = (EnergyBar1 >= 20) and (not behind) and (boss or pvp) },
{ name = "Blind Spot", use = (EnergyBar1 >= 25) and (behind) and (boss or pvp) },
{ name = "Wound Attack", use = ((EnergyBar1 >= 35) and ((tbuffs[500654]) and (tbuffs[500704]))) },
{ name = "Low Blow", use = (((EnergyBar1 >= 30) and (tbuffs[500654])) or (tbuffs['Energy Thief']))},
{ name = "Shadowstab", use = (EnergyBar1 >= 20) },
{ name = "Throat Attack", use = ((EnergyBar2 >= 50) and (boss or elite) and (silenceThis)) },
{ name = "Vampire Arrows", use = (EnergyBar2 >= 30) and (boss) },
{ name = "Shot", use = (EnergyBar1 < 20 ) },
|
|
|
Source code |
1 |
[LEFT][COLOR=#000000]{ name = "Shadow Step", use = (EnergyBar1 >= 20) and (not behind) and (boss or pvp) },[/COLOR][/LEFT]
|
|
|
Source code |
1 |
[LEFT][COLOR=#000000]{ name = "Blind Spot", use = (EnergyBar1 >= 25) and (behind) and (boss or pvp) },[/COLOR][/LEFT]
|
|
|
Source code |
1 |
[LEFT][COLOR=#000000]{ name = "Wound Attack", use = ((EnergyBar1 >= 35) and ((tbuffs[500654]) and (tbuffs[500704]))) },[/COLOR][/LEFT]
|
|
|
Source code |
1 |
[LEFT][COLOR=#000000]{ name = "Low Blow", use = (((EnergyBar1 >= 30) and (tbuffs[500654])) or (tbuffs['Energy Thief']))},[/COLOR][/LEFT]
|
|
|
Source code |
1 |
[LEFT][COLOR=#000000]{ name = "Shadowstab", use = (EnergyBar1 >= 20) },[/COLOR][/LEFT]
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 |
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(21) -- # 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
local race = UnitRace("target")
local Beamoid = race == "Humanoid" or race == "Beast"
--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: Warrior/Warden
if mainClass == "WARRIOR" and subClass == "WARDEN" then
--local SurpriseAttack = GetActionUsable(14)
--Potions and Buffs
Skill = {
{ name = "Survival Instinct", use = (phealth <= .49) },
{ name = "Action: "..healthpot, use = (phealth <= .60) },
{ name = "Action: "..manapot, use = (pctEB2 <= .40) },
{ name = "Briar Shield", use = (pctEB2 >= .05) and ((not pbuffs['Briar Shield']) or (pbuffs['Briar Shield'].time <= 45)) },
{ name = "Battle Creed", use = (pctEB2 >= .05) and ((not pbuffs['Battle Creed']) or (pbuffs['Battle Creed'].time <= 45)) },
}
--Combat
if enemy then
Skill2 = {
{ name = "Aggressiveness", use = boss },
{ name = "Savage Whirlwind", use = (pctEB2 >= .05) },
{ name = "Tactical Attack", use = ((tbuffs[500081]) and (EnergyBar1 >= 16)) },
{ name = "Attack Weakener", use = ((pctEB2 >= .05) and tbuffs['Vulnerable'] and (not pbuffs['Aggressiveness'])) },
{ name = "Open Flank", use = ((tbuffs['Vulnerable']) and (EnergyBar1 >=11)) },
{ name = "Probing Attack", use = ((EnergyBar1 >= 21) and (tbuffs[500081])) },
{ name = "Slash", use = (EnergyBar1 >= 26), timer = "SSBleed", ignoretimer = (pbuffs['Aggressiveness']) },
{ name = "Power of the Wood Spirit", use = (pctEB2 >= .05) },
{ name = "Attack", use = (thealth == 1) },
}
end
--Class: Priest/Warrior
elseif mainClass == "AUGUR" and subClass == "WARRIOR" then
--Potions and Buffs
Skill = {
{ name = "Regenerate", use = (phealth <= .90) and (pctEB2 >= .05) and (not pbuffs['Regenerate']) },
{ name = "Action: "..healthpot, use = (phealth <= .70) },
{ name = "Blessed Spring Water", use = (pctEB2 >= .05) and ((not pbuffs['Blessed Spring Water']) or (pbuffs['Blessed Spring Water'].time <= 45)) },
{ name = "Magic Barrier", use = (pctEB2 >= .05) and ((not pbuffs['Magic Barrier']) or (pbuffs['Magic Barrier'].time <= 45)) },
{ name = "Amplified Attack", use = (pctEB2 >= .05) and ((not pbuffs['Amplified Attack']) or (pbuffs['Amplified Attack'].time <= 45)) },
{ name = "Grace of Life", use = (pctEB2 >= .05) and ((not pbuffs['Grace of Life']) or (pbuffs['Grace of Life'].time <= 45)) },
}
--Combat
if enemy then
Skill2 = {
{ name = "Battle Monk Stance", use = ((combat) and (not string.find(pbuffs,"Battle Monk Stance"))) },
{ name = "Enraged", use = ((boss) and (combat)) },
{ name = "Ascending Dragon Strike", use = (EnergyBar2 >= 30) },
{ name = "Slash", use = (EnergyBar2 >= 26), timer = "SSBleed" },
{ name = "Explosion of Fighting Spirit", use = ((not friendly) and (combat)) }
{ name = "Power Build-Up", use = (friendly and (not string.find(pbuffs,"Power Build-Up")) and (not combat)) }
{ name = "Attack", use = (thealth == 1) },
}
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" 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
|
Quoted
{ name = "Explosion of Fighting Spirit", use = ((not friendly) and (combat)) }
{ name = "Power Build-Up", use = (friendly and (not string.find(pbuffs,"Power Build-Up")) and (not combat)) }
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
--Class: Warrior/Warden elseif mainClass == "WARRIOR" and subClass == "WARDEN" then
Skill = {
{ name = "Briar Shield", use = (pctEB2 >= .15) and ((not pbuffs['Briar Shield']) or (pbuffs['Briar Shield'].time <= 45)) },
{ name = "Battle Creed", use = (pctEB2 >= .15) and ((not pbuffs['Battle Creed']) or (pbuffs['Battle Creed'].time <= 45)) },
}
--Combat
if enemy then
Skill = {
{ name = "Survival Instinct", use = (phealth <= .49) },
{ name = "Elven Amulet", use = (EnergyBar2 >= 150) and (phealth <= .4) },
{ name = "Defensive Formation", use = (EnergyBar1 >= 25) and (phealth <= .30) },
{ name = "Savage Whirlwind", use = (EnergyBar2 >= 240) },
{ name = "Attack Weakener", use = (EnergyBar2 >= 280) and (tbuffs['Vulnerable']) },
{ name = "Action: 8", use = (EnergyBar1 >= 25) and (tbuffs['Vulnerable']) },
{ name = "Open Flank", use = (EnergyBar1 >= 10) and (tbuffs['Vulnerable']) },
{ name = "Probing Attack", use = (EnergyBar1 >= 15) },
{ name = "Tactical Attack", use = (EnergyBar1 >= 15) and (tbuffs[500081]) },
{ name = "Slash", use = (EnergyBar1 >= 25) },
{ name = "Power of the Wood Spirit", use = (EnergyBar2 >= 114) },
}
end
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
--Class: Warden/Warrior elseif mainClass == "WARDEN" and subClass == "WARRIOR" then
--Buffs
Skill = {
{ name = "Briar Shield", use = (pctEB2 >= .15) and ((not pbuffs['Briar Shield']) or (pbuffs['Briar Shield'].time <= 45)) },
}
--Combat
if enemy then
Skill = {
{ name = "Elven Amulet", use = (EnergyBar1 >= 150) and (phealth <= .4) },
{ name = "Defensive Formation", use = (EnergyBar2 >= 25) and (phealth <= .30) },
{ name = "Beast Chop", use = (EnergyBar2 >= 20) },
{ name = "Pulse Mastery", use = (EnergyBar2 >= 20) },
{ name = "Double Chop", use = (EnergyBar1 >= 54) },
{ name = "Will Attack", use = (EnergyBar1 >= 98) },
{ name = "Slash", use = (EnergyBar2 >= 25) },
{ name = "Cross Chop", use = (EnergyBar1 >= 245) },
{ name = "Power of the Wood Spirit", use = (EnergyBar2 >= 114) },
}
end
|
Quoted from "blitzclub06;524924"
Peryl,
I'm having a problem with my w/wd and my wd/w diyce. Here's the problem, I am getting a skill requirement error. At first my diyce is working perfectly, but once my rage is used up, and it tries to use the skill, I get the error and then all's i do is just stand there and white attack until i have enough rage to use the next attack. I thought that it was supposed to search to see if i had the rage to use the skill.