Hi,
I got the Serpent's Sparker wand which makes it possible to have 2 hydra's out at the same time.
Any way to change trinity to spawn 2?
// Hydra
if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) &&
(CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra &&
(TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) &&
Player.PrimaryResource >= 15)
{
// Hydra
int timeSinceHydra = SpellHistory.TimeSinceUse(SNOPower.Wizard_Hydra).Milliseconds;
if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) &&
(CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra &&
(TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) &&
Player.PrimaryResource >= 15 || SpellHistory.HistoryQueue.Count(i => i.TimeSinceHydra.TotalMilliseconds < 1200) <= 1)
{
Disclaimer: I did this quickly and without the ability to test it in any way. Just trying to help.
in Plugins/Trinity/Combat/Abilities/Wizard.cs find
Code:// Hydra if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) && (CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra && (TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) && Player.PrimaryResource >= 15) {
And replace it with
Code:// Hydra int timeSinceHydra = SpellHistory.TimeSinceUse(SNOPower.Wizard_Hydra).Milliseconds; if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) && (CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra && (TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) && Player.PrimaryResource >= 15 || SpellHistory.HistoryQueue.Count(i => i.TimeSinceHydra.TotalMilliseconds < 1200) <= 1) {
Disclaimer: I did this quickly and without the ability to test it in any way. Just trying to help.
in Plugins/Trinity/Combat/Abilities/Wizard.cs find
Code:// Hydra if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) && (CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra && (TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) && Player.PrimaryResource >= 15) {
And replace it with
Code:// Hydra int timeSinceHydra = SpellHistory.TimeSinceUse(SNOPower.Wizard_Hydra).Milliseconds; if (!useOocBuff && !Player.IsIncapacitated && CombatBase.CanCast(SNOPower.Wizard_Hydra, CombatBase.CanCastFlags.NoTimer) && (CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) && //LastPowerUsed != SNOPower.Wizard_Hydra && (TargetUtil.AnyElitesInRange(15, 1) || TargetUtil.AnyMobsInRange(15, 4) || (CurrentTarget.IsBossOrEliteRareUnique && CurrentTarget.RadiusDistance <= 15f)) && Player.PrimaryResource >= 15 || SpellHistory.HistoryQueue.Count(i => i.TimeSinceHydra.TotalMilliseconds < 1200) <= 1) {
public static bool hydraCastLast = false;
SpellHistory.hydraCastLast = true;
if (SpellHistory.hydraCastLast == true){//&& CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(1)){
SpellHistory.hydraCastLast = false;
float fExtraDistance = 0f;
if (CurrentTarget.Distance > 17f && !CurrentTarget.IsTreasureGoblin)
{
fExtraDistance = CurrentTarget.Distance - 17f;
if (fExtraDistance > 5f)
fExtraDistance = 5f;
if (CurrentTarget.Distance - fExtraDistance < 15f)
fExtraDistance -= 2;
}
Vector3 vNewTarget = MathEx.CalculatePointFrom(CurrentTarget.Position, Player.Position, CurrentTarget.Distance - fExtraDistance);
return new TrinityPower(SNOPower.Wizard_Hydra, 30f, vNewTarget, CurrentWorldDynamicId, -1, 1, 2);
}
Can you get me the "ActorSNO" of Serpent's Sparker?
Stop the bot and press this button ("Debug" tab)
Post the output here
![]()
I'll add some appropriate logic into the main release, but, I want it to be able to be backwards-compatible with those who don't have this item.
[Trinity]
############################################
Quick Dumping Items. This will hang your client. Please wait....
##########################
[Trinity]
should it be i.timeSinceHydra rather than i.TimeSinceHydra? I don't know a thing about this code.
What about just having the hydra spawn more then once during boss fight.
I do T6 ghom kills and it uses hydra at the start of the fight, after 12 seconds it does not recast..
Is there anyway I can make it so that hydra is casted again after the 12 seconds when im fighting ghom?
((CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) || serpentSparkerRecast) &&
((CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15)) || serpentSparkerRecast) &&
Go to line 187 in "Wizard.cs" and change it from:
Code:((CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15) && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f) || serpentSparkerRecast) &&
to
Code:((CombatBase.TimeSpanSincePowerUse(SNOPower.Wizard_Hydra) > TimeSpan.FromSeconds(15)) || serpentSparkerRecast) &&
EDIT: This is from Trinity 1.9.8..
You basicly just need to remove " && SpellHistory.DistanceFromLastTarget(SNOPower.Wizard_Hydra) > 30f " in Wizard.cs in the Hydra section.