Files
RobustToolbox/SS14.Server/Interfaces/Player/IPlayerSession.cs
2018-11-28 09:38:44 +01:00

44 lines
1.3 KiB
C#

using System;
using SS14.Server.Player;
using SS14.Shared.GameObjects;
using SS14.Shared.Interfaces.GameObjects;
using SS14.Shared.Interfaces.Network;
using SS14.Shared.Players;
namespace SS14.Server.Interfaces.Player
{
public interface IPlayerSession : ICommonSession
{
IEntity AttachedEntity { get; }
EntityUid? AttachedEntityUid { get; }
INetChannel ConnectedClient { get; }
DateTime ConnectedTime { get; }
event EventHandler<SessionStatusEventArgs> PlayerStatusChanged;
void JoinGame();
/// <summary>
/// Attaches this player to an entity.
/// NOTE: The content pack almost certainly has an alternative for this.
/// Do not call this directly for most content code.
/// </summary>
/// <param name="a">The entity to attach to.</param>
void AttachToEntity(IEntity a);
/// <summary>
/// Detaches this player from an entity.
/// NOTE: The content pack almost certainly has an alternative for this.
/// Do not call this directly for most content code.
/// </summary>
void DetachFromEntity();
void OnConnect();
void OnDisconnect();
/// <summary>
/// Persistent data for this player.
/// </summary>
IPlayerData Data { get; }
}
}