Grid map detaching: content edition.

This commit is contained in:
Pieter-Jan Briers
2018-06-10 01:03:49 +02:00
parent 9b251d70e2
commit 10999dc905
9 changed files with 19 additions and 25 deletions

View File

@@ -10,7 +10,7 @@ namespace Content.Server.GameObjects.Components.Power
{
public class PowerDebugTool : SharedPowerDebugTool, IAfterAttack
{
void IAfterAttack.Afterattack(IEntity user, LocalCoordinates clicklocation, IEntity attacked)
void IAfterAttack.Afterattack(IEntity user, GridLocalCoordinates clicklocation, IEntity attacked)
{
if (attacked == null)
{

View File

@@ -31,7 +31,7 @@ namespace Content.Server.GameObjects.Components.Weapon.Melee
}
void IAfterAttack.Afterattack(IEntity user, LocalCoordinates clicklocation, IEntity attacked)
void IAfterAttack.Afterattack(IEntity user, GridLocalCoordinates clicklocation, IEntity attacked)
{
var location = user.GetComponent<TransformComponent>().LocalPosition;
var angle = new Angle(clicklocation.ToWorld().Position - location.ToWorld().Position);

View File

@@ -20,7 +20,7 @@ namespace Content.Server.GameObjects.Components.Weapon.Ranged.Hitscan
string spritename = "Objects/laser.png";
protected override void Fire(IEntity user, LocalCoordinates clicklocation)
protected override void Fire(IEntity user, GridLocalCoordinates clicklocation)
{
var userposition = user.GetComponent<TransformComponent>().WorldPosition; //Remember world positions are ephemeral and can only be used instantaneously
var angle = new Angle(clicklocation.Position - userposition);

View File

@@ -17,7 +17,7 @@ namespace Content.Server.GameObjects.Components.Weapon.Ranged.Projectile
private float _velocity = 20f;
protected override void Fire(IEntity user, LocalCoordinates clicklocation)
protected override void Fire(IEntity user, GridLocalCoordinates clicklocation)
{
var userposition = user.GetComponent<TransformComponent>().LocalPosition; //Remember world positions are ephemeral and can only be used instantaneously
var angle = new Angle(clicklocation.Position - userposition.Position);

View File

@@ -9,7 +9,7 @@ namespace Content.Server.GameObjects.Components.Weapon.Ranged
{
public override string Name => "RangedWeapon";
void IAfterAttack.Afterattack(IEntity user, LocalCoordinates clicklocation, IEntity attacked)
void IAfterAttack.Afterattack(IEntity user, GridLocalCoordinates clicklocation, IEntity attacked)
{
if (UserCanFire(user) && WeaponCanFire())
{
@@ -27,7 +27,7 @@ namespace Content.Server.GameObjects.Components.Weapon.Ranged
return true;
}
protected virtual void Fire(IEntity user, LocalCoordinates clicklocation)
protected virtual void Fire(IEntity user, GridLocalCoordinates clicklocation)
{
return;
}