Warhorse ScripBind documentation
ContentsIndexHome
PreviousUpNext
C_ScriptBindPickableItem Methods

The methods of the C_ScriptBindPickableItem class are listed here.

 
Name 
Description 
 
 
 
Syntax: self.item:BelongsToDeadBody()
DEPRECATED Returns true if the item's owner is dead
 
 
Syntax: self.item:CanPickUp( ScriptHandle userId )
Checks if the item can be picked up by the user.
 
 
Syntax: self.item:CanSteal( ScriptHandle userId )
Checks if the item can be stolen by the user.
 
 
Syntax: self.item:CanUse( ScriptHandle userId )
Checks if the item can be used by the user.
 
 
Syntax: self.item:GetEntityHoldingInHand()
Returns the script table of entity that is hodling this item, if ant 
 
Syntax: self.item:GetExtensionParams( const char *extension, SmartScriptTable params )
Gets extension parameters.
 
 
Syntax: self.item:GetHealth()
Gets item health.
 
 
Syntax: self.item:GetId()
Gets item id
 
 
Syntax: self.item:GetLinkedOwner()
Returns linked owner
 
 
Syntax: self.item:GetMaxHealth()
Gets the maximum item health.
 
 
Syntax: self.item:GetMountedAngleLimits()
Gets the mounted angle limits for the item.
 
 
Syntax: self.item:GetMountedDir()
Gets the mounted direction for the item.
 
 
Syntax: self.item:GetOwnerId()
Gets the identifier of the item's owner.
 
 
Syntax: self.item:GetParams()
Gets the item parameters.
 
 
Syntax: self.item:GetPhase()
Returns phase relative from 0 to 1.
 
 
Syntax: self.item:GetPhaseId()
Returns absolute phase id from 0 to max phases.
 
 
Syntax: self.item:GetSlot( bool usePresence )
Gets the slot that holds the item. Uses either the presence or the holder to determine the slot. May return invalid wuid if the item's presence/holder is not a slot
 
 
Syntax: self.item:GetStats()
Gets the item statistics.
 
 
Syntax: self.item:GetUIName()
Gets the UI name.
 
 
Syntax: self.item:IsDestroyed()
Event that occurs when the item is destroyed.
 
 
Syntax: self.item:IsFromShop()
Returns true if the item is owner by some shop and can be bought instead of picked
 
 
Syntax: self.item:IsMounted()
Checks if the item is mounted.
 
 
Syntax: self.item:IsOversized()
Returns true if the item is too big to be picket up
 
 
Syntax: self.item:IsUsed()
Checks if the item is used.
 
 
Syntax: self.item:OnHit( SmartScriptTable hitTable )
Events that occurs when the item is hit.
 
 
Syntax: self.item:OnSteal( ScriptHandle userId )
If user is player, asks if he wants to steal the item and steals it.
 
 
Syntax: self.item:OnUsed( ScriptHandle userId )
Events that occurs when the item is used.
 
 
Syntax: self.item:PlayAnimation( const char *animationName )
Plays the specified animation.
 
 
Syntax: self.item:Reset()
Resets the item.
 
 
Syntax: self.item:Select( bool select )
Selects/deselects the item.
 
 
Syntax: self.item:SetExtensionActivation( const char *extension, bool activation )
Activates/deactivates an extension.
 
 
Syntax: self.item:SetExtensionParams( const char *extension, SmartScriptTable params )
Sets extension parameters.
 
 
Syntax: self.item:SetMountedAngleLimits( float min_pitch, float max_pitch, float yaw_range )
Sets the mounted angle limits (yaw-pitch).
 
 
Syntax: self.item:SetPhase(phase)
Sets phase of this objects and reload its mode. Phase relative from 0 to 1.
 
 
Syntax: self.item:SetPhaseById(id)
Sets phase of this objects by phase id and reload its model. Id is absolute phase from 0 to max phases. Max phases needs to be known from DB.
 
 
Syntax: self.item:StartUse( ScriptHandle userId )
The specified user now will start to use the item.
 
 
Syntax: self.item:StopUse( ScriptHandle userId )
The specified user now will stop to use the item.
 
 
Use 
Syntax: self.item:Use( ScriptHandle userId )
The specified user now will use the item.
 
Copyright (c) 2012. All rights reserved.