What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

How to check skill buff and ground skill?

storm4820

New Member
Joined
Sep 8, 2014
Messages
8
Reaction score
0
i try to change some code in CrusaderCombat.cs. but not work.

i'm using Obsidian Ring of the Zodiac. so i don't wanna waste any cooltime to spam.

1. Provoke - Hit Me
trinity using provoke-hitMe just spam. not check provoke-hitMe buff.
i don't want use this while buff is active.

2. Consecration - BedOfNails
this skill is spam too.
i don't want use this while active on the ground or duration.


please help me.

sorry bad English. :p


--------------------------- EX. Code ------------------------------

// Provoke
if (CanCast(SNOPower.X1_Crusader_Provoke) && !GetBuff(SNOPower.X1_Crusader_Provoke)
{
return new TrinityPower(SNOPower.X1_Crusader_Provoke);
}


// Consecration
bool hasSGround = CacheData.Hotbar.ActiveSkills.Any(s => s.Power == SNOPower.X1_Crusader_Consecration);

if ((!hasSGround && CanCastConsecration())
{
return new TrinityPower(SNOPower.X1_Crusader_Consecration);
}
 
Code:
                // Consecration
                bool hasSGround = CacheData.Hotbar.ActiveSkills.Any(s => s.Power == SNOPower.X1_Crusader_Consecration && s.RuneIndex == 3);
                if ((!hasSGround && CanCastConsecration()) || TimeSincePowerUse(SNOPower.X1_Crusader_Consecration) >= 10000 &&
                   (hasSGround && CanCastConsecration() && (TargetUtil.AnyMobsInRange(15f, 5) || TargetUtil.IsEliteTargetInRange(15f))))
                {
                    return new TrinityPower(SNOPower.X1_Crusader_Consecration);
                }

and

Code:
                // Provoke
                if (CanCast(SNOPower.X1_Crusader_Provoke) && !GetHasBuff(SNOPower.X1_Crusader_Provoke) && ((TargetUtil.EliteOrTrashInRange(15f) ||
                    TargetUtil.AnyMobsInRange(15f, CrusaderSettings.ProvokeAoECount) || Sets.SeekerOfTheLight.IsFullyEquipped && Player.PrimaryResourcePct <= 0.25)))
                {
                    return new TrinityPower(SNOPower.X1_Crusader_Provoke);
                }

Have fun :)
 
Jubis, i have test your code.

provoke is works very well.

but consecration is still spam.

idk what's wrong.

my trinity setting is "Consecration Health Pct = 100.0"

and current code for consecration on the crusadercombat.cs is bottom.

-------------------------------------- bottom ------------------------------------
// Consecration by Jubisman

bool hasSGround = CacheData.Hotbar.ActiveSkills.Any(s => s.Power == SNOPower.X1_Crusader_Consecration && s.RuneIndex == 3);
if ((!hasSGround && CanCastConsecration()) || TimeSincePowerUse(SNOPower.X1_Crusader_Consecration) >= 10000 &&
(hasSGround && CanCastConsecration() && (TargetUtil.AnyMobsInRange(15f, 5) || TargetUtil.IsEliteTargetInRange(15f))))
{
return new TrinityPower(SNOPower.X1_Crusader_Consecration);


------------------------------------------------------------------------------
private static bool CanCastConsecration()
{
return CanCast(SNOPower.X1_Crusader_Consecration) && Player.CurrentHealthPct <= CrusaderSettings.ConsecrationHpPct;
}
 
Oh, sorry, I seem to have put the check in the wrong spot.

Should be like this

Code:
// Consecration by Jubisman

bool hasSGround = CacheData.Hotbar.ActiveSkills.Any(s => s.Power == SNOPower.X1_Crusader_Consecration && s.RuneIndex == 3);
if ((!hasSGround && CanCastConsecration() && TimeSincePowerUse(SNOPower.X1_Crusader_Consecration) >= 10000) ||
(hasSGround && CanCastConsecration() && (TargetUtil.AnyMobsInRange(15f, 5) || TargetUtil.IsEliteTargetInRange(15f))))
{
return new TrinityPower(SNOPower.X1_Crusader_Consecration);
 
thank's for the your kind :)

i'll try again.

and this is bug report.

steed charge is spam.

i'm not bombardment build. and i have edit my code to the bottom.

--------------- bottom ------------------
public static bool IsBombardmentBuild
{
get { return false; }
}
-------------------------------------------

trinity setting is 'Use Steed Charge OOC : true' / 'Use Steed Charge off CD : false'

but bot try steed charge in the combat and out of combat.

bot use steed charge and headbutt to enemy on the cooldown.

why just can't use steed charge to OOC?
 
Back
Top