m |
(Added simple example to SInventoryItem .MasterID .PlayerItemID .Name .Description .Brand .CustomData) |
||
Line 19: | Line 19: | ||
<pre>Items = Space.Inventory.Items | <pre>Items = Space.Inventory.Items | ||
Items[1].PlayerItemID</pre>}} | Items[1].PlayerItemID</pre>}} | ||
− | {{ScriptFunction|string|Name|{ get; }|Returns the name of the inventory item}} | + | {{ScriptFunction|string|Name|{ get; }|Returns the name of the inventory item|5= |
− | {{ScriptFunction|string|Description|{ get; }|Returns the registered description of the inventory item in the users locale}} | + | <pre>Items = Space.Inventory.Items |
− | {{ScriptFunction|string|Brand|{ get; }|Returns brand information about the item}} | + | Items[1].Name</pre>}} |
− | {{ScriptFunction|string|CustomData|{ get; }|Returns any custom data associated with this item, typically used for 'game' items}} | + | {{ScriptFunction|string|Description|{ get; }|Returns the registered description of the inventory item in the users locale|5= |
+ | <pre>Items = Space.Inventory.Items | ||
+ | Items[1].Description</pre>}} | ||
+ | {{ScriptFunction|string|Brand|{ get; }|Returns brand information about the item|5= | ||
+ | <pre>Items = Space.Inventory.Items | ||
+ | Items[1].Brand</pre>}} | ||
+ | {{ScriptFunction|string|CustomData|{ get; }|Returns any custom data associated with this item, typically used for 'game' items|5= | ||
+ | <pre>Items = Space.Inventory.Items | ||
+ | Items[1].CustomData</pre>}} | ||
{{Scripting Navbox}} | {{Scripting Navbox}} |
Each SInventoryItem refers to a single item in the users inventory. Below members may require inventory authorization, please see Scripting/SInventory for master inventory access.
Updates the inventory items custom data, and requests a synchronisation with the inventory server. It may not update on the server immediately, but all local calls will reflect the new data. Note: this request can be rate limited and should only be called from a user initiated action (such as clicking a button). Updates to custom data must not be initiated on a timer or regular automatic event. Access to this function can be blacklisted to specific creators if abused.
Player will 'Use' this item.
Items = Space.Inventory.Items Items[1].Use()
Player will 'Delete' this item.
Items = Space.Inventory.Items Items[1].Delete()
The master ID for this item - also known as the Curator ID or Item ID, this is the ID for the master item from which this copy exists.
Items = Space.Inventory.Items itemMasterID = Items[1].MasterID
The instance ID for this item - this is guaranteed to be unique per inventory item
Items = Space.Inventory.Items Items[1].PlayerItemID
Returns the name of the inventory item
Items = Space.Inventory.Items Items[1].Name
Returns the registered description of the inventory item in the users locale
Items = Space.Inventory.Items Items[1].Description
Returns brand information about the item
Items = Space.Inventory.Items Items[1].Brand
Returns any custom data associated with this item, typically used for 'game' items
Items = Space.Inventory.Items Items[1].CustomData
|