Exemple #1
0
 public Game(Level level, Snake snake, Player player)
 {
     this.level           = level;
     this.snake           = snake;
     this.player          = player;
     this.speedController = SpeedController.GetInstance();
 }
Exemple #2
0
        public static SpeedController GetInstance()
        {
            if (instance == null)
            {
                instance = new SpeedController();
            }

            return(instance);
        }
Exemple #3
0
 private void InitializeGameSpeed()
 {
     this.gameSpeed    = SpeedController.GetInstance();
     gameSpeed.OnTick += gameTimer_OnTick;
 }