// Update is called once per second void UpdateEverySecond() { if (currentStatus.Equals(status.QUEUE)) { if (lastVisitedAttraction.npcsWaiting.Count <= lastVisitedAttraction.npcAmount) { UpdateHappiness(game.penaltyInQueue); } else if (lastVisitedAttraction.npcsWaiting.Count > lastVisitedAttraction.npcAmount) { UpdateHappiness(Mathf.RoundToInt(game.penaltyInQueue * game.overfilledQueuePenaltyMultiplier)); } } if (currentStatus.Equals(status.ATTRACTION)) { UpdateHappiness(game.rewardInAttraction); } if (walkRandom && currentStatus == status.IDLE && remainingIdleTime > 0) { --remainingIdleTime; } UpdateShirtColor(); #if UNITY_EDITOR gameObject.name = "NPC [" + currentStatus.ToString() + "]"; #endif }
private void SettingOK_Click(object sender, EventArgs e) { settingOK.BackgroundImage = Resource1.button_ok; if (!enterSuccess.Equals(status.success)) { setting_win.Hide(); main_win.Show(); } else { this.Hide(); this.ShowInTaskbar = false; ni.Visible = true; } }