Example #1
0
        public LootContent_ItemsWithChance(LootContentSerializable serializable, Database.Loader loader)
            : base(serializable, loader)
        {
            Items = new ImmutableCollection <LootItem>(serializable.Items?.Select(item => LootItem.Create(item, loader)));

            OnDataDeserialized(serializable, loader);
        }
Example #2
0
        public LootContent_RandomItems(LootContentSerializable serializable, Database.Loader loader)
            : base(serializable, loader)
        {
            MinAmount = UnityEngine.Mathf.Clamp(serializable.MinAmount, 0, 999999999);
            MaxAmount = UnityEngine.Mathf.Clamp(serializable.MaxAmount, 0, 999999999);
            Items     = new ImmutableCollection <LootItem>(serializable.Items?.Select(item => LootItem.Create(item, loader)));

            OnDataDeserialized(serializable, loader);
        }