Remove compiler warnings.

This commit is contained in:
Pieter-Jan Briers
2018-07-26 23:55:34 +02:00
parent b34591ab59
commit cb439ba39a
2 changed files with 17 additions and 10 deletions

View File

@@ -10,6 +10,7 @@ using SS14.Shared.Maths;
using SS14.Shared.IoC;
using Content.Server.GameObjects.EntitySystems;
using SS14.Shared.Serialization;
using SS14.Shared.Interfaces.Network;
namespace Content.Server.GameObjects
{
@@ -39,15 +40,15 @@ namespace Content.Server.GameObjects
base.Initialize();
collidableComponent = Owner.GetComponent<CollidableComponent>();
collidableComponent.OnBump += OnBump;
spriteComponent = Owner.GetComponent<SpriteComponent>();
}
public override void OnRemove()
{
collidableComponent.OnBump -= OnBump;
collidableComponent = null;
spriteComponent = null;
base.OnRemove();
}
public bool Attackhand(IEntity user)
@@ -63,15 +64,21 @@ namespace Content.Server.GameObjects
return true;
}
private void OnBump(object sender, BumpEventArgs args)
public override void HandleMessage(ComponentMessage message, INetChannel netChannel = null, IComponent component = null)
{
Logger.Info("Bump!");
base.HandleMessage(message, netChannel, component);
switch (message)
{
case BumpedEntMsg msg:
if (Opened)
{
return;
}
Open();
break;
}
}
public void Open()

2
engine

Submodule engine updated: bceda76bf8...696bf486a6