Location: Home / Lua Coding / Item Properties
The table below lists item properties visible from Lua. Some properties require additional notes - they are included at the end of the table.
|Object name with correct handling of A/AN/THE
|CH variable that item is held/worn by, or nil.
|Clan number if the item is from a clan
|Key of destination room for a portal.
|Name of drink type on a drink container
|Capacity remaining on a drink container
|Returns 1 if item is poisoned food/drink
|Number of items with the same object key in game
|OBJ type variable item is inside, or nil.
|Returns the object key
|Level of item
|Location type of item. See below for details.
|Name of item
|Current owner of item
|Long name of item as seen in a room
|ROOM variable that item is in, or nil.
|OBJ type variable of top level container. Same as obj if not in a container.
|Timer in seconds, or zero for no timer.
|Type of item as a number
|Type of item as a name
|Uses of item remaining - wands/portals/etc
|Value of item
|Item total weight
The 'loctype' object property returns the type of location an item is in. Return values are:
|- Object is on a player
|- Object is on a mob
|- Object is in a room.
|- Object is in a container.
|- Object is nowhere (auction or bug)