Moved dropping items over PlaceableSurfaces from AfterAttack to AttackBy (#209)

Added ClickLocation variable to AttackByEventArgs
This commit is contained in:
DamianX
2019-04-25 22:22:51 +01:00
committed by Pieter-Jan Briers
parent 8655dcaaf6
commit b16768fd0b
3 changed files with 16 additions and 19 deletions

View File

@@ -35,6 +35,7 @@ namespace Content.Server.GameObjects.EntitySystems
public class AttackByEventArgs : EventArgs
{
public IEntity User { get; set; }
public GridCoordinates ClickLocation { get; set; }
public IEntity AttackWith { get; set; }
}
@@ -321,7 +322,7 @@ namespace Content.Server.GameObjects.EntitySystems
for (var i = 0; i < interactables.Count; i++)
{
if (interactables[i].AttackBy(new AttackByEventArgs { User = user, AttackWith = weapon })) //If an attackby returns a status completion we finish our attack
if (interactables[i].AttackBy(new AttackByEventArgs { User = user, ClickLocation = clicklocation, AttackWith = weapon })) //If an attackby returns a status completion we finish our attack
{
return;
}