refactor and chat base
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using System.Net.WebSockets;
|
||||
using System.Text.Json;
|
||||
using MauMau_Server.Websockets;
|
||||
|
||||
namespace MauMau_Server.Mau;
|
||||
|
||||
@@ -17,9 +18,9 @@ public class Game
|
||||
Deck.AddCardToUsedDeck(CurrentCard);
|
||||
}
|
||||
|
||||
public void AddPlayerToGame(string playerId, WebSocket socket)
|
||||
public void AddPlayerToGame(ConnectionInstance connection)
|
||||
{
|
||||
var player = new Player("Koetje " + playerId.Split('-')[0], playerId, socket)
|
||||
var player = new Player(connection)
|
||||
{
|
||||
Hand = Deck.DrawCards(8)
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user