public static void RegisterListWantsCrossRef <T>(List <T> wanterList, string targetDefName, object debugWanterInfo = null) where T : new()
 {
     DirectXmlCrossRefLoader.WantedRefForList <T> wantedRefForList = null;
     foreach (DirectXmlCrossRefLoader.WantedRef wantedRef in DirectXmlCrossRefLoader.wantedRefs)
     {
         if (wantedRef.wanter == wanterList)
         {
             wantedRefForList = (DirectXmlCrossRefLoader.WantedRefForList <T>)wantedRef;
             break;
         }
     }
     if (wantedRefForList == null)
     {
         wantedRefForList = new DirectXmlCrossRefLoader.WantedRefForList <T>(wanterList, debugWanterInfo);
         DirectXmlCrossRefLoader.wantedRefs.Add(wantedRefForList);
     }
     wantedRefForList.AddWantedListEntry(targetDefName);
 }
 public static void RegisterListWantsCrossRef <T>(List <T> wanterList, string targetDefName) where T : new()
 {
     DirectXmlCrossRefLoader.WantedRefForList <T> wantedRefForList = null;
     foreach (DirectXmlCrossRefLoader.WantedRef current in DirectXmlCrossRefLoader.wantedRefs)
     {
         if (current.wanter == wanterList)
         {
             wantedRefForList = (DirectXmlCrossRefLoader.WantedRefForList <T>)current;
             break;
         }
     }
     if (wantedRefForList == null)
     {
         wantedRefForList = new DirectXmlCrossRefLoader.WantedRefForList <T>(wanterList);
         DirectXmlCrossRefLoader.wantedRefs.Add(wantedRefForList);
     }
     wantedRefForList.AddWantedListEntry(targetDefName);
 }