Beispiel #1
0
 public LootBehavior(
     LootDef pub,
     params Tuple<int, LootDef>[] soul)
 {
     PublicBag = pub ?? LootDef.Empty;
     SoulBag = soul;
 }
Beispiel #2
0
 public LootBehavior(
     LootDef pub,
     params Tuple <int, LootDef>[] soul)
 {
     PublicBag = pub ?? LootDef.Empty;
     SoulBag   = soul;
 }
        public virtual void Populate(IList <LootDef> lootDefs, LootDef overrides = null)
        {
            if (overrides == null)
            {
                foreach (var lootDef in LootDefs)
                {
                    lootDefs.Add(lootDef);
                }
                return;
            }

            foreach (var lootDef in LootDefs)
            {
                lootDefs.Add(new LootDef(
                                 lootDef.Item,
                                 overrides.Probabilty >= 0 ? overrides.Probabilty : lootDef.Probabilty,
                                 overrides.NumRequired >= 0 ? overrides.NumRequired : lootDef.NumRequired,
                                 overrides.Threshold >= 0 ? overrides.Threshold : lootDef.Threshold));
            }
        }
 loot: new LootBehavior(LootDef.Empty,
     Tuple.Create(800, new LootDef(0, 5, 0, 8,
Beispiel #5
0
 loot: new LootBehavior(LootDef.Empty,
         Tuple.Create(100, new LootDef(0, 2, 0, 2,