ORK Framework  2.25.2
API Documentation
ORKFramework.Inventory Class Reference
Inheritance diagram for ORKFramework.Inventory:
ORKFramework.ISaveData ORKFramework.IInventoryExchange

Public Member Functions

 Inventory (IContent content)
 
 Inventory (Combatant combatant)
 
 Inventory (Group g)
 
void Clear ()
 
IContentSimple GetContent ()
 
Combatant GetOwner ()
 
bool IsPlayerOwned ()
 
void FireChanged ()
 
void CheckDataChanged (bool checkItems, bool checkWeapons, bool checkArmors, bool checkAICollection, bool checkCraftingRecipes)
 
void MarkFireChanged ()
 
void FireChanged (ItemDropType type, int id, int level, int quantity)
 
void AutoAddShortcut (IShortcut shortcut)
 
bool CanCollect (IShortcut item)
 
void CheckQuantity (IShortcut shortcut)
 
int GetAllowedQuantity (IShortcut shortcut, int quantity)
 
void AddOccupiedSpace (IInventoryShortcut shortcut)
 
bool CheckSpace (float space, bool add)
 
void GetAll (bool addMoney, bool addEmptyMoney, bool addItems, bool addWeapons, bool addArmor, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes, int typeID, bool checkParent, ref List< IShortcut > list)
 
void GetAll (bool addMoney, bool addEmptyMoney, bool addItems, bool addWeapons, bool addArmors, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes, int typeID, bool checkParent, ref List< IInventoryShortcut > list)
 
void Add (Inventory inventory)
 
void Add (ItemGain[] list, bool showNotification, bool showConsole)
 
void Add (List< IShortcut > list, bool showNotification, bool showConsole)
 
bool Add (IShortcut item, bool showNotification, bool showConsole, bool markNewContent)
 
bool Add (IShortcut item, ref int addedQuantity, bool showNotification, bool showConsole, bool markNewContent)
 
void Remove (List< IShortcut > list, bool showNotification, bool showConsole)
 
void Remove (IShortcut item, bool showNotification, bool showConsole)
 
void Remove (IShortcut item, int quantity, bool showNotification, bool showConsole)
 
void Remove (ItemGain[] item, bool showNotification, bool showConsole)
 
void Drop (ItemGain[] item, bool showNotification, bool showConsole)
 
void Drop (List< IShortcut > list, bool showNotification, bool showConsole)
 
void Drop (IShortcut item, bool showNotification, bool showConsole)
 
void Drop (IShortcut item, int quantity, bool showNotification, bool showConsole)
 
bool Has (ItemGain[] list)
 
bool Has (ItemGain item)
 
bool Has (IShortcut item)
 
bool Has (List< IShortcut > list)
 
bool Has (IShortcut item, int quantity)
 
int GetCount (ItemGain item)
 
int GetCount (IShortcut item)
 
int GetAllowedCount (IShortcut item)
 
List< IShortcutGetStealable (bool addItems, bool addWeapons, bool addArmors)
 
bool HasSellable (bool addItems, bool addWeapons, bool addArmors, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes, List< int > itemTypes)
 
void GetSellable (ref List< ShopWrapperShortcut > list, bool addItems, bool addWeapons, bool addArmors, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes, List< int > itemTypes)
 
void RemoveItemType (int typeID, bool removeSubTypes, bool removeMoney, bool removeItems, bool removeWeapons, bool removeArmor, bool showNotification, bool showConsole)
 
void GetItemTypes (int parentType, ref List< int > list, bool onlySellable, bool addMoney, bool addEmptyMoney, bool addItems, bool addWeapons, bool addArmor, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes)
 
bool HasNewItemTypes (bool checkParent, List< int > types, bool onlySellable, bool addItems, bool addWeapons, bool addArmor, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes)
 
bool HasItemType (bool checkParent, int typeID, bool onlySellable, bool addMoney, bool addEmptyMoney, bool addItems, bool addWeapons, bool addArmor, bool addAIBehaviours, bool addAIRulesets, bool addCraftingRecipes, bool checkNewContent)
 
MoneyShortcut GetMoneyShortcut (int id)
 
int GetMoney (int id)
 
void SetMoney (int id, int quantity, bool showNotification, bool showConsole)
 
bool HasEnoughMoney (int id, int quantity)
 
void AddMoney (int id, int quantity, bool showNotification, bool showConsole)
 
void SubMoney (int id, int quantity, bool showNotification, bool showConsole)
 
int GetEquippedWeaponCount (int id)
 
int GetEquippedArmorCount (int id)
 
ItemShortcut GetItem (int id)
 
bool AddEquipment (EquipShortcut equip, bool showNotification, bool showConsole, bool markNewContent)
 
void RemoveEquipment (EquipShortcut equip, int quantity, bool showNotification, bool showConsole)
 
EquipShortcut GetEquipment (int id, ItemDropType type)
 
EquipShortcut GetEquipment (int id, int level, ItemDropType type)
 
EquipShortcut GetEquipment (EquipShortcut equip)
 
List< EquipShortcutGetEquipmentByPart (int partID, bool weapons, bool armors)
 
bool HasEquipment ()
 
bool HasEquippedEquipment ()
 
void AddNotifications (IShortcut shortcut, int addedQuantity, bool showNotification, bool showConsole)
 
void RemoveNotifications (IShortcut shortcut, int removedQuantity, bool showNotification, bool showConsole)
 
DataObject SaveGame ()
 Used to save the data - you need to add the data to a ORKFramework.DataObject. More...
 
void LoadGame (DataObject data)
 Used to load the data - you need to get the data from the ORKFramework.DataObject. More...
 

Public Attributes

bool showNotifications = false
 

Properties

Notify Changed
 
InventoryChanged ContentChanged
 
int Count [get]
 
Combatant Owner [get]
 
Group Group [get]
 
bool HasOwners [get]
 
SubInventory Items [get]
 
SubInventory Weapons [get]
 
SubInventory Armors [get]
 
CraftingHandler Crafting [get]
 
AICollectionHandler AICollection [get]
 
int MoneyCount [get]
 
bool IsEmpty [get]
 
float Space [get]
 
float TotalSpace [get]
 
bool Full [get]
 
- Properties inherited from ORKFramework.IInventoryExchange
bool IsEmpty [get]
 

Additional Inherited Members

- Events inherited from ORKFramework.IInventoryExchange
Notify Changed
 

Member Function Documentation

◆ LoadGame()

void ORKFramework.Inventory.LoadGame ( DataObject  data)

Used to load the data - you need to get the data from the ORKFramework.DataObject.

Parameters
dataA ORKFramework.DataObject containing the data.

Implements ORKFramework.ISaveData.

◆ SaveGame()

DataObject ORKFramework.Inventory.SaveGame ( )

Used to save the data - you need to add the data to a ORKFramework.DataObject.

Returns
A ORKFramework.DataObject containing the data.

Implements ORKFramework.ISaveData.