ARKBreedingStats.ARKOverlay.setValues C# (CSharp) Метод

setValues() публичный Метод

public setValues ( float wildValues, float tamedValues, Color colors = null ) : void
wildValues float
tamedValues float
colors Color
Результат void
        public void setValues(float[] wildValues, float[] tamedValues, Color[] colors = null)
        {
            foreach (KeyValuePair<String, Point> kv in ArkOCR.OCR.statPositions)
            {
                if (kv.Key == "Torpor")
                    continue;

                int statIndex = -1;
                switch (kv.Key)
                {
                    case "NameAndLevel": statIndex = 0; break;
                    case "Health": statIndex = 1; break;
                    case "Stamina": statIndex = 2; break;
                    case "Oxygen": statIndex = 3; break;
                    case "Food": statIndex = 4; break;
                    case "Weight": statIndex = 5; break;
                    case "Melee Damage": statIndex = 6; break;
                    case "Movement Speed": statIndex = 7; break;
                    default:
                        break;
                }

                if (statIndex == -1)
                    continue;

                labels[statIndex].Text = "[w" + wildValues[statIndex];
                if (tamedValues[statIndex] != 0)
                    labels[statIndex].Text += " + d" + tamedValues[statIndex];
                labels[statIndex].Text += "]";
                labels[statIndex].Location = this.PointToClient(ArkOCR.OCR.lastLetterPositions[kv.Key]);

                if (kv.Key != "NameAndLevel")
                    labels[statIndex].ForeColor = colors[statIndex];

                lblStatus.Location = new Point(labels[0].Location.X - 100, 10);
                lblExtraText.Location = new Point(labels[0].Location.X - 100, 40);
            }
            txtBreedingProgress.Text = "";
        }