Documentation › Modules › Storage.em
File: Storage.em
Functions for working with internal storage areas.
CreateRootItemInStorageArea( area, itemname, objtype )#
Parameters
| area | Storage Area Reference |
| itemname | String |
| objtype | Integer objtype, OR String ObjtypeName, OR GetItemDescriptor struct. |
Explanation
Creates the "root" (top-level) item in the storage area provided. "itemname" is the name of this
item, and "objtype" is its type.
Note The item is normally a container. For example, a bankbox is a storage area and the root item
is the chest container. Normal items are then placed in this container.
Return values
Item Reference on success
Errors
- "Invalid parameter type"
- "Unable to create item"
Related
CreateStorageArea( areaname )#
Parameters
| areaname | String |
Explanation
Create a new storage area with name "areaname".
Return values
Storage Area reference on success
Errors
- Errors: none (returns 0 on invalid parameter)
DestroyRootItemInStorageArea( area, itemname )#
Parameters
| area | Storage Area Reference |
| itemname | String |
Explanation
Destroys the root item named "itemname" in storage area "area"
Return values
1 on delete success
0 on item not found
Errors
- "Invalid parameter type"
FindRootItemInStorageArea( area, itemname )#
Parameters
| area | Storage Area Reference |
| itemname | String |
Explanation
Finds the root item named "itemname" in the storage area named "area".
Return values
Item Reference on success
Errors
- "Invalid parameter type"
- "Root item not found."
FindStorageArea( areaname )#
Parameters
| areaname | String |
Explanation
Gets a reference to the storage area named "areaname"
Return values
Storage Area reference on success
Errors
- none (returns 0 on invalid parameter or area not found)
Related
StorageAreas()#
Explanation
Returns a StorageAreas object, see object reference for details
Return values
StorageAreas object