Jump to content

single and multi target and AOE


BishopXRay

Recommended Posts

Does the option AOE in Fight Class Editor literally mean AOE? I haven't found any examples yet where it is used. It wasn't even used for Whirling Blades in the examples I looked at. Is it possible to set abilities to trigger based on the number of attackers? How do we setup for multiple targets verses single target? 

Thank You

Link to comment
Share on other sites

6 hours ago, BishopXRay said:

Does the option AOE in Fight Class Editor literally mean AOE? I haven't found any examples yet where it is used. It wasn't even used for Whirling Blades in the examples I looked at. Is it possible to set abilities to trigger based on the number of attackers? How do we setup for multiple targets verses single target? 

Thank You

AOE means that the spell needs to be placed at the ground like Death and Decay from DK.
If i'm not wrong there is no option in the editor to get the result you want. What you can do is to use C# code as condition.

For example:

int range = 15;
int targetAmount = ObjectManager.GetObjectWoWUnit().Count(u => u.IsAlive && u.MaxHealth > 500 && ((ObjectManager.Me.TargetObject.Position.DistanceTo2D(u.Position) - ObjectManager.Me.TargetObject.CombatReach) <= range) && u.IsAttackable && !TraceLine.TraceLineGo(u.Position));

return targetAmount > 3;

[range] = range around the target
[targetAmount] = the targets we found around the target
[targetAmount > 3] = returns true (executes the spell) if there are more than 3 targets around the current target

hope that helps.

Edited by iMod
Link to comment
Share on other sites

  • 1 month later...
On 6/2/2018 at 11:15 AM, iMod said:

AOE means that the spell needs to be placed at the ground like Death and Decay from DK.
If i'm not wrong there is no option in the editor to get the result you want. What you can do is to use C# code as condition.

For example:


int range = 15;
int targetAmount = ObjectManager.GetObjectWoWUnit().Count(u => u.IsAlive && u.MaxHealth > 500 && ((ObjectManager.Me.TargetObject.Position.DistanceTo2D(u.Position) - ObjectManager.Me.TargetObject.CombatReach) <= range) && u.IsAttackable && !TraceLine.TraceLineGo(u.Position));

return targetAmount > 3;

[range] = range around the target
[targetAmount] = the targets we found around the target
[targetAmount > 3] = returns true (executes the spell) if there are more than 3 targets around the current target

hope that helps.

So just Copy/paste the code under condition setting?

Link to comment
Share on other sites

I'm not sure if you can use multi lines. 
If not just use 

return ObjectManager.GetObjectWoWUnit().Count(u => u.IsAlive && u.MaxHealth > 500 && ((ObjectManager.Me.TargetObject.Position.DistanceTo2D(u.Position) - ObjectManager.Me.TargetObject.CombatReach) <= 15) && u.IsAttackable && !TraceLine.TraceLineGo(u.Position)) > 3;

You need to select " Sharp Code" as condition and add the line into Value.

Link to comment
Share on other sites

  • 5 years later...
On 3/28/2018 at 5:58 AM, iMod said:

I'm not sure if you can use multi lines. 
If not just use 

return ObjectManager.GetObjectWoWUnit().Count(u => u.IsAlive && u.MaxHealth > 500 && ((ObjectManager.Me.TargetObject.Position.DistanceTo2D(u.Position) - ObjectManager.Me.TargetObject.CombatReach) <= 15) && u.IsAttackable && !TraceLine.TraceLineGo(u.Position)) > 3;

You need to select " Sharp Code" as condition and add the line into Value.

This is just throwing an error CS1525 and CS1002
Invalid expression term ','

Link to comment
Share on other sites

8 hours ago, Sjd6795 said:

This is just throwing an error CS1525 and CS1002
Invalid expression term ','

Use code without "return" and the ";"

ObjectManager.GetObjectWoWUnit().Count(u => u.IsAlive && u.MaxHealth > 500 && ((ObjectManager.Me.TargetObject.Position.DistanceTo2D(u.Position) - ObjectManager.Me.TargetObject.CombatReach) <= 15) && u.IsAttackable && !TraceLine.TraceLineGo(u.Position))

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...