public static GameObject GetPrefabToInstantiate(ItemInformation itemData, GameObject defaultPrefab = null) { var prefab = (defaultPrefab != null ? defaultPrefab : CloudGoodsSettings.DefaultItemDrop); foreach (var dropPrefab in CloudGoodsSettings.ExtraItemPrefabs) { if (IsPrefabForItem(itemData, dropPrefab)) { prefab = dropPrefab.prefab; } } return prefab; }
public virtual int GetRestrictedAmount(ItemInformation data, ItemContainer target) { restrictions = GetRestrictionsFor(target); foreach (ItemContainerStackRestrictions restriction in restrictions) { int restrictedAmount = restriction.GetRestrictionForType(data.ClassId); if (restrictedAmount != -1) { return restrictedAmount; } } return -1; }
public InstancedItemInformation() { Information = new ItemInformation(); }
public BundleItemInformation() { Information = new ItemInformation(); }
static bool IsPrefabForItem(ItemInformation itemData, DropPrefab dropPrefab) { return false; }
public abstract bool isItemSelected(ItemInformation item, IEnumerable tagList, bool isInverted = false);
public VoucherItemInformation() { Information = new ItemInformation(); }
public ContainerMoveState(ActionState newState = ActionState.No, int possibleAddAmount = 0, ItemInformation possibleSwapItem = null) { this.ContainerActionState = newState; this.PossibleAddAmount = possibleAddAmount; this.PossibleSwapItem = possibleSwapItem; }