* IPlayer - Connection and Buffer properties added along with SwitchState(IState) method
* Switched the ServerDirector over from using two List Collections to maintain Client Threads and Player instances into a single Dictionary. Required adjusting the majority of the existing Types, but should now be functional. Need to still add some safety checks for null references since we are now passing a reference Type around.
This commit is contained in:
parent
f977376ac3
commit
24c9fae4f5
7 changed files with 59 additions and 62 deletions
|
@ -1,9 +1,16 @@
|
|||
namespace WinPC.Engine.Abstract.Core
|
||||
using System.Net.Sockets;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace WinPC.Engine.Abstract.Core
|
||||
{
|
||||
public interface IPlayer
|
||||
{
|
||||
IState CurrentState { get; }
|
||||
Socket Connection { get; }
|
||||
List<byte> Buffer { get; set; }
|
||||
|
||||
string Name { get; set; }
|
||||
void Disconnect();
|
||||
void SwitchState(IState state);
|
||||
}
|
||||
}
|
|
@ -2,8 +2,7 @@
|
|||
{
|
||||
public interface IState
|
||||
{
|
||||
void Render(int index);
|
||||
void Render(IPlayer player);
|
||||
ICommand GetCommand();
|
||||
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue