private Board() { this.gameboard = new Abs_Box[40]; this.jailed_players = new Player[4]; this.dices = SingletonDice.GetInstance(); ObserveDice observer = new ObserveDice("1"); dices.Attach(observer); }
public static SingletonDice GetInstance() { if (instance == null) { lock (objlock) { if (instance == null) { instance = new SingletonDice(); } } } return(instance); }