Modify LobbyServer

This commit is contained in:
2019-05-04 17:51:19 +02:00
parent ed1771664b
commit 6c0e8a83a5
4 changed files with 24 additions and 3 deletions

View File

@@ -1,3 +1,5 @@
using Newtonsoft.Json;
namespace LobbyServer
{
public class ScoreEntry
@@ -5,12 +7,12 @@ namespace LobbyServer
public string Pseudo { get; }
public int Score { get; }
[JsonConstructor]
public ScoreEntry(string pseudo, int score)
{
Pseudo = pseudo;
Score = score;
}
public ScoreEntry(string serialized)
{
var split = serialized.Split(';');