Пример #1
0
        public LevelDescription Create(int width, int height)
        {
            if (width < MinFieldWidth)
            {
                width = MinFieldWidth;
            }

            if (height < MinFieldHeight)
            {
                height = MinFieldHeight;
            }

            var levelDescription = new LevelDescription
                                   {
                                       Field = new FieldDescription()
                                               {
                                                   Width = width,
                                                   Height = height,
                                               }
                                   };

            return levelDescription;
        }
Пример #2
0
 private void StartLevel(LevelDescription description)
 {
     CurrentLevel = description;
     Gamefield.StartGame(description);
 }
Пример #3
0
 public void StartGame(LevelDescription levelDescription)
 {
     LevelDescription = levelDescription;
     Debug.Log("Start level: "+LevelDescription);
     GameStartTime = DateTime.UtcNow;
     Init();
 }