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

How to stop attack if reflection is active

kleinerMann

Member
Joined
May 27, 2013
Messages
64
Reaction score
1
hi,

how can i modify trinity to stop my attack if reflection is active?

Greetings
kleinerMann
 
You need to edit Weighting.cs in order to ignore mobs with reflech shield UP.
The only thing I see in weighting is cacheObject.HasAffixShielded && cacheObject.Unit.IsInvulnerable. Do we need to a new section for reflect shielded? And any idea what the cacheObject is for reflect?
 
The only thing I see in weighting is cacheObject.HasAffixShielded && cacheObject.Unit.IsInvulnerable. Do we need to a new section for reflect shielded? And any idea what the cacheObject is for reflect?

Just did check what members Zeta.Game.Internals.Actors.DiaUnit have. Seems that it is imposible to check Reflect Shield state, i found nothing that could bring the light on it. Only thing that you can check is the reflect shield affix: cacheObject.MonsterAffixes.HasFlag(MonsterAffixes.ReflectsDamage)
 
Last edited:
i found this two SNOPowers:
Zeta.Game.Internals.Actors.SNOPower.MonsterAffix_ReflectsDamageCast
and
Zeta.Game.Internals.Actors.SNOPower.SiegeBreaker_ReflectsDamageCast

Is it possible with this to check the reflect shield is active?
 
You may try somthing like that:

var DiaUnitBuffsList = DiaUnit.GetAllBuffs().ToList();
if (DiaUnitBuffsList.Any(u => u.SNOId == SNOPower.MonsterAffix_ReflectsDamage)) ...

But i think that GetAllBuffs not work for mobs.
 
Last edited:
But i think that GetAllBuffs not work for mobs.
not work with mobs.
Trinity has a function "HasDebuff" -> CurentTarget.HasDebuff(SNOPower debuffSNO)

Can someone modify or rewrite this to detect active damage reflect?
I try it but i dont know the correct ActorAttributeType.
Any idea to list all ActorAttributeType of npc with MonsterAffixes.ReflectsDamage

my actual code:
Code:
private void checkUnits()
{
	using (ZetaDia.Memory.SaveCacheState())
	{
		ZetaDia.Memory.DisableCache();
		ZetaDia.Actors.Update();
		var units = ZetaDia.Actors.GetActorsOfType<ACD>()
			.Where(o => o.IsValid && o.MonsterAffixes.HasFlag(MonsterAffixes.ReflectsDamage))
			.OrderBy(o => o.Distance);

		
		foreach (ACD o in units)
		{
			if (!o.IsValid)
				continue;
			foreach (var tmpVal in o.???)
			{
				writeToLog("ActorAttributeType: " + tmpVal.???);
			}
		}
	}
}
 
Last edited:
I had my own request about to fix Fire Chains affix one week ago and still no responce from devs, no fix in recent update, so i think they will ignore this too. Anyway reflect damage is not extremely dangerous.

Lack of communication from dev's of this project is making me sad.
 
Back
Top