Updates the Content EntitySystems with the changes to the event API.
Visual Studio wants to update the version of the solution, and change some GUIDs around.
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
using Content.Shared.GameObjects.EntitySystemMessages;
|
||||
using Content.Shared.GameObjects.EntitySystems;
|
||||
using Robust.Server.Interfaces.Player;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.Interfaces.GameObjects;
|
||||
using Robust.Shared.Interfaces.Network;
|
||||
using Robust.Shared.IoC;
|
||||
using Robust.Shared.Maths;
|
||||
using Robust.Shared.Utility;
|
||||
@@ -37,17 +35,12 @@ namespace Content.Server.GameObjects.EntitySystems
|
||||
{
|
||||
base.Initialize();
|
||||
|
||||
SubscribeEvent<ExamineSystemMessages.RequestExamineInfoMessage>((sender, ev) => ExamineInfoRequest(ev));
|
||||
|
||||
IoCManager.InjectDependencies(this);
|
||||
}
|
||||
|
||||
public override void RegisterMessageTypes()
|
||||
{
|
||||
base.RegisterMessageTypes();
|
||||
|
||||
RegisterMessageType<ExamineSystemMessages.RequestExamineInfoMessage>();
|
||||
}
|
||||
|
||||
private FormattedMessage GetExamineText(IEntity entity)
|
||||
private static FormattedMessage GetExamineText(IEntity entity)
|
||||
{
|
||||
var message = new FormattedMessage();
|
||||
|
||||
@@ -82,11 +75,10 @@ namespace Content.Server.GameObjects.EntitySystems
|
||||
return message;
|
||||
}
|
||||
|
||||
public override void HandleNetMessage(INetChannel channel, EntitySystemMessage message)
|
||||
private void ExamineInfoRequest(ExamineSystemMessages.RequestExamineInfoMessage request)
|
||||
{
|
||||
base.HandleNetMessage(channel, message);
|
||||
|
||||
if (!(message is ExamineSystemMessages.RequestExamineInfoMessage request))
|
||||
var channel = request.NetChannel;
|
||||
if(channel == null)
|
||||
return;
|
||||
|
||||
var session = _playerManager.GetSessionByChannel(channel);
|
||||
|
||||
Reference in New Issue
Block a user