Пример #1
0
        public LevelEngine(GameEngine gameEngine, XLevelInfo levelInfo, XLevelScore levelScore)
			: base(gameEngine, levelInfo.File)
		{
            this.LevelInfo = levelInfo;
			this.LevelScore = levelScore;
			this.cps = new EventRateCounter(TimeSpan.FromSeconds(game.GameObject.CpsTimeSpan));
		}
Пример #2
0
        public void CopyTo(XLevelScore other)
        {
            other.availablePoints = this.availablePoints;
            other.score           = this.score;
            other.time            = this.time;
            other.health          = this.health;

            other.calculated = false;
        }
Пример #3
0
		public void SaveNewScore(XLevelScore newScore)
		{
			if (newScore.TotalScore < this.LevelScore.TotalScore)
				return;
			
			newScore.CopyTo(this.LevelScore);
			
			game.SaveScore();
		}
Пример #4
0
		public void CopyTo(XLevelScore other)
		{
			other.availablePoints = this.availablePoints;
			other.score = this.score;
			other.time = this.time;
			other.health = this.health;
			
			other.calculated = false;
		}