示例#1
0
	void CalculateTimeForWhite()
	{
		// adding seconds
		secondsForWhite -= Time.deltaTime;
		// adding minutes
		if (Mathf.Floor (secondsForWhite) < 0) {
			secondsForWhite = 60;
			minutesForWhite--;
		}
		if (minutesForWhite < 0) {
			minutesForWhite = 59;
			hoursForWhite--;
		}
		if (hoursForWhite < 0) {
			clockState = StartClockState.WhiteFlags;

		}
	}
示例#2
0
	void ShowThatBlackHasFlagged() {
		TimeBlackText.color = Color.red;
		TimeBlackText.text = "Time";
		gameManager.BlackFlags ();
		clockState = StartClockState.Wait;
	}
示例#3
0
	public void StartClock(StartClockState clockState) {
		this.clockState = clockState;
	}
示例#4
0
	void ShowThatWhiteHasFlagged() {		
		TimeWhiteText.color = Color.red;
		TimeWhiteText.text = "Time";
		gameManager.WhiteFlags ();
		clockState = StartClockState.Wait;
	}
示例#5
0
	void CalculateTimeForBlack()
	{
		// adding seconds
		secondsForBlack -= Time.deltaTime;
		// adding minutes
		if (Mathf.Floor (secondsForBlack) < 0) {
			secondsForBlack = 60;
			minutesForBlack--;
		}
		if (minutesForBlack < 0) {
			minutesForBlack = 59;
			hoursForBlack--;
		}
		if (hoursForBlack < 0) {
			clockState = StartClockState.BlackFlags;
		}
	}