July 10, 201510 yr Hello, I'm trying to get Artillery Strike to work in my fight class. Here are my attempts - it doesn't work. Any suggestions? <FightClassSpell> <FightClassConditions> <FightClassCondition> <ContionType>LuaScript</ContionType> <Param xsi:type="FightClassConditionLua"> <LuaScript>count = GetItemCount(162077) ; if count > 0 then vRet = 1 else vRet = 0 end</LuaScript> <VarRet>vRet</VarRet> <ValueRet>1</ValueRet> </Param> </FightClassCondition> <FightClassCondition> <ContionType>HostileUnitNear</ContionType> <Param xsi:type="FightClassConditionUnitNear"> <Number>1</Number> <Type>BiggerOrEqual</Type> <Radius>10</Radius> </Param> </FightClassCondition> </FightClassConditions> <SpellName>RunMacroText("/use Artillery Strike")</SpellName> <Priority>15</Priority> <Timer>4000</Timer> <NotSpellIsLuaScript>true</NotSpellIsLuaScript> <AOESpellMePos>true</AOESpellMePos> </FightClassSpell> <FightClassSpell> <FightClassConditions> <FightClassCondition> <ContionType>LuaScript</ContionType> <Param xsi:type="FightClassConditionLua"> <LuaScript>count = GetItemCount(162077) ; if count > 0 then vRet = 1 else vRet = 0 end</LuaScript> <VarRet>vRet</VarRet> <ValueRet>1</ValueRet> </Param> </FightClassCondition> <FightClassCondition> <ContionType>CSharpCode</ContionType> <Param xsi:type="FightClassConditionString"> <Value>ObjectManager.GetWoWUnitHostile().Count(u => u.Position.DistanceTo(ObjectManager.Target.Position) <= 10 && u.Entry != 77405 && u.Guid != ObjectManager.Pet.Guid && wManager.Wow.Helpers.UnitCanAttack.CanAttack(u.GetBaseAddress, ObjectManager.Me.GetBaseAddress)) >= 2</Value> </Param> </FightClassCondition> </FightClassConditions> <SpellName>RunMacroText("/use Artillery Strike")</SpellName> <Priority>14</Priority> <Timer>6000</Timer> <NotSpellIsLuaScript>true</NotSpellIsLuaScript> <AOESpell>true</AOESpell> </FightClassSpell>
July 13, 201510 yr Hello, http://www.wowhead.com/spell=162077/artillery-strike is an spell (not an item) Remove condition lua with code GetItemCount(162077) and remplace RunMacroText("/use Artillery Strike") by RunMacroText("/cast Artillery Strike"). But why you use this spell with RunMacroText (this spell don't works with normal way)?
July 16, 201510 yr Author Hi, "/cast Artillery Strike" doesn't work, only "/use Artillery Strike" does. I've retested this and only "/use" works from the cmd line. The attempt at using the GetItemCount was to try and get it to not trigger when the number of artillery uses was zero. I have had situations in the past where the bot would loop on an item with charges and not progress to another condition test. I've taken the getitemcount out, as well as the c sharp code. Now back to: <FightClassSpell> <FightClassConditions> <FightClassCondition> <ContionType>HostileUnitNear</ContionType> <Param xsi:type="FightClassConditionUnitNear"> <Number>1</Number> <Type>BiggerOrEqual</Type> <Radius>10</Radius> </Param> </FightClassCondition> </FightClassConditions> <SpellName>RunMacroText("/use Artillery Strike")</SpellName> <Priority>14</Priority> <Timer>4000</Timer> <NotSpellIsLuaScript>true</NotSpellIsLuaScript> <AOESpellMePos>true</AOESpellMePos> </FightClassSpell> <FightClassSpell> <FightClassConditions> <FightClassCondition> <ContionType>HostileUnitNearTarget</ContionType> <Param xsi:type="FightClassConditionUnitNear"> <Number>2</Number> <Type>BiggerOrEqual</Type> <Radius>10</Radius> </Param> </FightClassCondition> </FightClassConditions> <SpellName>RunMacroText("/use Artillery Strike")</SpellName> <Priority>13</Priority> <Timer>6000</Timer> <NotSpellIsLuaScript>true</NotSpellIsLuaScript> <AOESpell>true</AOESpell> </FightClassSpell>
July 21, 201510 yr ps: try to run this code in wow chat to check if the result is good: /run local currentCharges, maxCharges, cooldownStart, cooldownDuration = GetSpellCharges(162077); print(currentCharges);
Create an account or sign in to comment