コード例 #1
0
 private static void BuildDatabaseIfNecessary()
 {
     if (GraphicDatabaseHeadRecords.heads.Count <= 0 || GraphicDatabaseHeadRecords.skull == null || GraphicDatabaseHeadRecords.stump == null)
     {
         GraphicDatabaseHeadRecords.heads.Clear();
         foreach (string text in GraphicDatabaseHeadRecords.HeadsFolderPaths)
         {
             foreach (string str in GraphicDatabaseUtility.GraphicNamesInFolder(text))
             {
                 GraphicDatabaseHeadRecords.heads.Add(new GraphicDatabaseHeadRecords.HeadGraphicRecord(text + "/" + str));
             }
         }
         GraphicDatabaseHeadRecords.skull = new GraphicDatabaseHeadRecords.HeadGraphicRecord(GraphicDatabaseHeadRecords.SkullPath);
         GraphicDatabaseHeadRecords.stump = new GraphicDatabaseHeadRecords.HeadGraphicRecord(GraphicDatabaseHeadRecords.StumpPath);
     }
 }
コード例 #2
0
 private static void BuildDatabaseIfNecessary()
 {
     if (heads.Count <= 0 || skull == null || stump == null)
     {
         heads.Clear();
         string[] headsFolderPaths = HeadsFolderPaths;
         foreach (string text in headsFolderPaths)
         {
             foreach (string item in GraphicDatabaseUtility.GraphicNamesInFolder(text))
             {
                 heads.Add(new HeadGraphicRecord(text + "/" + item));
             }
         }
         skull = new HeadGraphicRecord(SkullPath);
         stump = new HeadGraphicRecord(StumpPath);
     }
 }
コード例 #3
0
 private static void BuildDatabaseIfNecessary()
 {
     if (GraphicDatabaseHeadRecords.heads.Count > 0 && GraphicDatabaseHeadRecords.skull != null && GraphicDatabaseHeadRecords.stump != null)
     {
         return;
     }
     GraphicDatabaseHeadRecords.heads.Clear();
     string[] headsFolderPaths = GraphicDatabaseHeadRecords.HeadsFolderPaths;
     foreach (string text in headsFolderPaths)
     {
         foreach (string item in GraphicDatabaseUtility.GraphicNamesInFolder(text))
         {
             GraphicDatabaseHeadRecords.heads.Add(new HeadGraphicRecord(text + "/" + item));
         }
     }
     GraphicDatabaseHeadRecords.skull = new HeadGraphicRecord(GraphicDatabaseHeadRecords.SkullPath);
     GraphicDatabaseHeadRecords.stump = new HeadGraphicRecord(GraphicDatabaseHeadRecords.StumpPath);
 }
コード例 #4
0
 private static void BuildDatabaseIfNecessary()
 {
     if (GraphicDatabaseHeadRecords.heads.Count > 0 && GraphicDatabaseHeadRecords.skull != null && GraphicDatabaseHeadRecords.stump != null)
     {
         return;
     }
     GraphicDatabaseHeadRecords.heads.Clear();
     string[] headsFolderPaths = GraphicDatabaseHeadRecords.HeadsFolderPaths;
     for (int i = 0; i < headsFolderPaths.Length; i++)
     {
         string text = headsFolderPaths[i];
         foreach (string current in GraphicDatabaseUtility.GraphicNamesInFolder(text))
         {
             GraphicDatabaseHeadRecords.heads.Add(new GraphicDatabaseHeadRecords.HeadGraphicRecord(text + "/" + current));
         }
     }
     GraphicDatabaseHeadRecords.skull = new GraphicDatabaseHeadRecords.HeadGraphicRecord(GraphicDatabaseHeadRecords.SkullPath);
     GraphicDatabaseHeadRecords.stump = new GraphicDatabaseHeadRecords.HeadGraphicRecord(GraphicDatabaseHeadRecords.StumpPath);
 }