Exemple #1
0
 /// <summary>
 /// Used to house player's current held object data. If the player was not holding anything, just make first param false and the rest will be ignored.
 /// </summary>
 /// <param name="playerWasHoldingSomething">If player was holding something, pass true. If not, pass false</param>
 /// <param name="pickupPrefabName">Name of the Pickup type object's prefab in the case the player was holding a Pickup type object</param>
 /// <param name="inventoryItemType">Inventory Item Type, in the case the player was holding an InventoryItem type</param>
 /// <param name="localRotation">The last local rotation of the held object when it was in the player's hand</param>
 public FPEHeldObjectSaveData(bool playerWasHoldingSomething, string pickupPrefabName, FPEInventoryManagerScript.eInventoryItems inventoryItemType, Quaternion localRotation)
 {
     heldSomething = playerWasHoldingSomething;
     puPrefabName  = pickupPrefabName;
     invItemType   = inventoryItemType;
     localRot      = new FPEQuaternion(localRotation);
 }
Exemple #2
0
 public FPEInventoryItemSaveData(FPEInventoryManagerScript.eInventoryItems type)
 {
     invType = type;
 }
Exemple #3
0
 public FPEInventoryWorldSaveData(Vector3 pos, Quaternion rot, FPEInventoryManagerScript.eInventoryItems type) : base(pos, rot)
 {
     invType = type;
 }
Exemple #4
0
 /// <summary>
 /// Returns quantity of specified inventory item type. If there are no such items in the
 /// inventory, zero is returned;
 /// </summary>
 /// <param name="itemToCheck">The type of item for which quantity will be checked</param>
 /// <returns></returns>
 public int inventoryQuantity(FPEInventoryManagerScript.eInventoryItems itemToCheck)
 {
     return(inventoryQuantities[(int)itemToCheck]);
 }