Пример #1
0
        public override string GetInspectString()
        {
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.AppendLine(Static.InspectQuarryPercent + ": " + QuarryPercent.ToStringDecimalIfSmall() + "%");
            if (PlayerCanSeeOwners)
            {
                //    stringBuilder.AppendLine("ForColonistUse".Translate());
                if (owners.Count == 0)
                {
                    stringBuilder.AppendLine("QRY_RestrictedTo".Translate() + ": " + "Nobody".Translate().ToLower());
                }
                else if (owners.Count == 1)
                {
                    stringBuilder.AppendLine("QRY_RestrictedTo".Translate() + ": " + owners[0].Label);
                }
                else
                {
                    stringBuilder.Append("QRY_RestrictedTo".Translate() + ": ");
                    bool conjugate = false;
                    for (int i = 0; i < OwnerInspectCount; i++)
                    {
                        if (conjugate)
                        {
                            stringBuilder.Append(", ");
                        }
                        conjugate = true;
                        stringBuilder.Append(owners[i].LabelShort);
                    }
                    if (owners.Count > 3)
                    {
                        stringBuilder.Append($" (+ {owners.Count - 3})");
                    }
                    stringBuilder.AppendLine();
                }
            }
            if (Prefs.DevMode)
            {
                List <string> report = new List <string>();
                for (int i = 0; i < rockTypesUnder.Count; i++)
                {
                    if (!report.Contains(rockTypesUnder[i]))
                    {
                        report.Add(rockTypesUnder[i]);
                    }
                }
                stringBuilder.AppendLine("Rock Types available: " + report.Count);
                foreach (string item in report)
                {
                    stringBuilder.AppendLine("     " + item.CapitalizeFirst());
                }
                stringBuilder.AppendLine();
            }
            return(stringBuilder.ToString().TrimEndNewlines());
        }
Пример #2
0
        public override string GetInspectString()
        {
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.Append(base.GetInspectString());
            stringBuilder.AppendLine(Static.InspectQuarryPercent + ": " + QuarryPercent.ToStringDecimalIfSmall() + "%");
            if (PlayerCanSeeOwners)
            {
                //    stringBuilder.AppendLine("ForColonistUse".Translate());
                if (owners.Count == 0)
                {
                    stringBuilder.AppendLine("QRY_RestrictedTo".Translate() + ": " + "Nobody".Translate().ToLower());
                }
                else if (owners.Count == 1)
                {
                    stringBuilder.AppendLine("QRY_RestrictedTo".Translate() + ": " + owners[0].Label);
                }
                else
                {
                    stringBuilder.Append("QRY_RestrictedTo".Translate() + ": ");
                    bool conjugate = false;
                    for (int i = 0; i < OwnerInspectCount; i++)
                    {
                        if (conjugate)
                        {
                            stringBuilder.Append(", ");
                        }
                        conjugate = true;
                        stringBuilder.Append(owners[i].LabelShort);
                    }
                    if (owners.Count > 3)
                    {
                        stringBuilder.Append($" (+ {owners.Count - 3})");
                    }
                    stringBuilder.AppendLine();
                }
            }
            if (Prefs.DevMode || PlayerCanSeeOwners)
            {
                stringBuilder.AppendLine("Rock Types available: ");
                List <string> report = new List <string>();
                for (int i = 0; i < rocksUnder.Count; i++)
                {
                    QuarryRockType rockType = rocksUnder[i];
                    if (!report.Contains(rockType.rockDef.LabelCap))
                    {
                        report.Add(rockType.rockDef.LabelCap);
                        stringBuilder.AppendLine("     " + rockType.rockDef.LabelCap + (rockType.chunkDef != null ? ": chunks" : "") + (rockType.blockDef != null ? ((rockType.chunkDef != null ? ", " : ": ") + "blocks") : ""));
                    }
                }
                stringBuilder.AppendLine();
            }
            return(stringBuilder.ToString().TrimEndNewlines());
        }
Пример #3
0
        public override string GetInspectString()
        {
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.AppendLine(Static.InspectQuarryPercent + ": " + QuarryPercent.ToStringDecimalIfSmall() + "%");
            if (PlayerCanSeeOwners)
            {
                stringBuilder.AppendLine("ForColonistUse".Translate());
                if (owners.Count == 0)
                {
                    stringBuilder.AppendLine("Owner".Translate() + ": " + "Nobody".Translate().ToLower());
                }
                else if (owners.Count == 1)
                {
                    stringBuilder.AppendLine("Owner".Translate() + ": " + owners[0].Label);
                }
                else
                {
                    stringBuilder.Append("Owners".Translate() + ": ");
                    bool conjugate = false;
                    for (int i = 0; i < OwnerInspectCount; i++)
                    {
                        if (conjugate)
                        {
                            stringBuilder.Append(", ");
                        }
                        conjugate = true;
                        stringBuilder.Append(owners[i].LabelShort);
                    }
                    if (owners.Count > 3)
                    {
                        stringBuilder.Append($" (+ {owners.Count - 3})");
                    }
                    stringBuilder.AppendLine();
                }
            }
            return(stringBuilder.ToString().TrimEndNewlines());
        }
Пример #4
0
 public override string GetInspectString()
 {
     return(Static.InspectQuarryPercent + ": " + QuarryPercent.ToStringDecimalIfSmall() + "%");
 }