InventoryItem (of IconItem)

class InventoryItem

Defined in InventoryItem.sc.

This extends IconItem and adds the ability to automatically print messages (for the look and do verbs) that include a visual representation of the inventory item. It also provides an owner property that indicates who owns the item.

An example inventory item might look like:

(instance Hammer of InventoryItem
        (properties
                view 900
                loop 1
                cursor 900                      ; Optional cursor when using this item.
                message V_HAMMER        ; Optional verb associated with the item.
                signal $0002
                noun N_HAMMER           ; noun from message resource 0
        )
)
class diagram

Properties

Inherited from IconItem:

Property Description
view  
loop  
cel  
nsLeft  
nsTop  
nsRight  
nsBottom  
state  
cursor  
type  
message  
modifiers  
signal  
maskView  
maskLoop  
maskCel  
highlightColor  
lowlightColor  
noun  
modNum  
helpVerb  
name  

Defined in InventoryItem:

Property Description
owner  
script  
value  

Methods

show()
highlight(param1)
onMe(param1)
ownedBy(theObj)
moveTo(theOwner)
doVerb(theVerb)