Пример #1
0
        public override unsafe int GetBlueprints(List <MyBlueprintDefinitionBase.ProductionInfo> blueprints)
        {
            int num   = 0;
            int index = 0;

            while (index < this.m_blueprints.Length)
            {
                int num3  = this.m_blueprints[index].GetBlueprints(blueprints);
                int count = blueprints.Count;
                int num5  = count - 1;
                while (true)
                {
                    if (num5 < (count - num3))
                    {
                        num += num3;
                        index++;
                        break;
                    }
                    MyBlueprintDefinitionBase.ProductionInfo info = blueprints[num5];
                    MyFixedPoint *pointPtr1 = (MyFixedPoint *)ref info.Amount;
                    pointPtr1[0]    *= this.m_items[index].Amount;
                    blueprints[num5] = info;
                    num5--;
                }
            }
            return(num);
        }
Пример #2
0
 public override int GetBlueprints(List <MyBlueprintDefinitionBase.ProductionInfo> blueprints)
 {
     MyBlueprintDefinitionBase.ProductionInfo item = new MyBlueprintDefinitionBase.ProductionInfo {
         Blueprint = this,
         Amount    = 1
     };
     blueprints.Add(item);
     return(1);
 }