コード例 #1
0
 public static AltCobalt GetAltCobalt()
 {
     if (!vanillaAltsAdded)
     {
         WorldGen.AddAlt(new AltCobalt(TileID.Cobalt, Lang.misc[12].Value));
         WorldGen.AddAlt(new AltCobalt(TileID.Palladium, Lang.misc[21].Value, 0.9f));
     }
     return(ChosenAltCobalt ?? (ChosenAltCobalt = AltCobalts[WorldGen.genRand.Next(AltCobalts.Count)]));
 }
コード例 #2
0
 internal static void tryFind(int oreTileType)
 {
     foreach (var altCobalt in AltCobalts)
     {
         if (altCobalt.oreTileType != oreTileType)
         {
             continue;
         }
         ChosenAltCobalt = altCobalt;
         break;
     }
 }
コード例 #3
0
 internal static void Add(AltCobalt alt)
 {
     AltCobalts.Add(alt);
 }
コード例 #4
0
 internal static void UnchooseAltCobalt()
 {
     ChosenAltCobalt = null;
 }