A custom Action can be set up to simply run the Clear() method mentioned above.
Is it possible to remove all items from inventory but limited that by category?
I assume it's using this...
KickStarter.runtimeInventory.RemoveAllInCategory (int categoryID);
It is - see its description in the scripting guide.
This script is no longer working for me as it did before. Do I need to revise the code for version 1.74.5?
The inventory system was overhauled in AC's v1.72 update - the updated way to remove all items from the inventory is to call:
KickStarter.runtimeInventory.PlayerInvCollection.DeleteAll ();
For details on what other functions you can call to control the Player's inventory, see the Scripting Guide's entry for InventoryCollection, as well as the Manual's "Inventory scripting" chapter.
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
A custom Action can be set up to simply run the Clear() method mentioned above.
Is it possible to remove all items from inventory but limited that by category?
I assume it's using this...
KickStarter.runtimeInventory.RemoveAllInCategory (int categoryID);
It is - see its description in the scripting guide.
This script is no longer working for me as it did before. Do I need to revise the code for version 1.74.5?
The inventory system was overhauled in AC's v1.72 update - the updated way to remove all items from the inventory is to call:
For details on what other functions you can call to control the Player's inventory, see the Scripting Guide's entry for InventoryCollection, as well as the Manual's "Inventory scripting" chapter.