コード例 #1
0
        /// <summary>
        /// Add the judgement and the total of that judgement to the Result Screen.
        /// </summary>
        /// <param name="name">The name of the judgement.</param>
        private void AddJudgeInfo(string name)
        {
            string         configName = char.ToUpper(name[0]) + name.Substring(1);
            JudgementValue judgement  = Judgement.GetJudgementValueByName(name);

            // Judge
            Vector2 position = Skin.GetConfigStartPosition(Config, Sections[2], $"{configName}StartPos", scorecard);
            int     offsetX  = GetSkinnableJudgementInt($"{configName}X");
            int     offsetY  = GetSkinnableJudgementInt($"{configName}Y");
            float   scale    = GetSkinnableJudgementFloat($"{configName}Scale") * Pulsarc.HeightScale;

            Judge judge = new Judge(judgement.Score, position, scale);

            judge.Move(offsetX, offsetY);

            // JudgeCount
            TextDisplayElement text = MakeTextDisplayElement($"{configName}Count", Sections[2]);

            text.Name  = name;
            text.Color = judgement.Color;

            judgements.Add(new KeyValuePair <Judge, TextDisplayElement>(judge, text));
        }