コード例 #1
0
 public void GetBotsData(List <MyObjectBuilder_AIComponent.BotData> botDataList)
 {
     foreach (KeyValuePair <int, IMyBot> pair in this.m_allBots)
     {
         MyObjectBuilder_AIComponent.BotData item = new MyObjectBuilder_AIComponent.BotData {
             BotBrain     = pair.Value.GetObjectBuilder(),
             PlayerHandle = pair.Key
         };
         botDataList.Add(item);
     }
 }
コード例 #2
0
 public void GetBotsData(List <MyObjectBuilder_AIComponent.BotData> botDataList)
 {
     foreach (var keyValPair in m_allBots)
     {
         var newData = new MyObjectBuilder_AIComponent.BotData()
         {
             BotBrain     = keyValPair.Value.GetObjectBuilder(),
             PlayerHandle = keyValPair.Key
         };
         botDataList.Add(newData);
     }
 }