code smelles
continuous-integration/drone/push Build is passing Details

test_old_branch
Jérémy Mouyon 12 months ago
parent 12da82978d
commit 7d4fb356fd

@ -5,8 +5,8 @@ namespace QwirkleClassLibrary;
public class Cell
{
private int x;
private int y;
private readonly int x;
private readonly int y;
private Tile? tile = null;
public Cell(int x, int y)

@ -11,7 +11,7 @@ namespace QwirkleClassLibrary
{
public class Game : IPlayer, IRules
{
private TileBag bag;
private readonly TileBag bag;
public bool GameRunning { get; private set; }
private Board board;
@ -48,7 +48,7 @@ namespace QwirkleClassLibrary
}
players.Add(CreatePlayer(playerTag));
scores.Add(new Score(players[players.Count]));
scores.Add(new Score(players[players.Count-1]));
return true;
}

@ -8,8 +8,8 @@ namespace QwirkleClassLibrary
{
public struct Score
{
private int score;
private string playerTag;
private int score { get; set; }
public string playerTag { get; }
public Score(Player p)
{
@ -23,11 +23,5 @@ namespace QwirkleClassLibrary
playerTag = p.NameTag;
}
}
public int GetScore
{
get { return score; }
}
}
}

@ -10,8 +10,8 @@ namespace QwirkleClassLibrary
{
public class Tile
{
private Shape shape;
private Color color;
private readonly Shape shape;
private readonly Color color;
public Tile(Shape sh, Color co)
{
shape = sh;

Loading…
Cancel
Save