/*------------------------------------ * GetScore(private版) * * summary:各スコアを取得 * param :なし(void) * return :なし(void) * ------------------------------------*/ void GetScore() { /* 赤スコア */ ScoreControl sc = GameObject.FindGameObjectWithTag("RedScore").GetComponent <ScoreControl>(); m_score[(int)COLOR.RED] = sc.GetScore(); /* 緑スコア */ sc = GameObject.FindGameObjectWithTag("GreenScore").GetComponent <ScoreControl>(); m_score[(int)COLOR.GREEN] = sc.GetScore(); /* 青スコア */ sc = GameObject.FindGameObjectWithTag("BlueScore").GetComponent <ScoreControl>(); m_score[(int)COLOR.BLUE] = sc.GetScore(); }
private void endSimulation() { StatsControl.GenerationStats gs = statsControl.CalculateStats(); decisionControl.EndGeneration(scoreControl.GetScore(gs)); resetSimulation(); }
// Update is called once per frame void Update() { PlayerPrefs.SetInt("Score", Score.GetScore()); }