API GetAddonItemInfo: Difference between revisions

From Vendetta Lua
Jump to navigationJump to search
No edit summary
No edit summary
 
Line 13: Line 13:
| ret3_name    = name
| ret3_name    = name
| ret3_type    = string
| ret3_type    = string
| ret3_desc    = Name of weapon addon
| ret3_desc    = Name of weapon addon, otherwise nil
| ret3_opt    = true
| ret3_opt    = true
| notes        =  
| notes        =  
}}
}}

Latest revision as of 07:07, 20 October 2011

GetAddonItemInfo

Definition
GetAddonItemInfo( number  itemid) ->  number  current,  number  maximum [,  string  name ]
Description
Returns current and maximum ammo if itemid is a weapon with ammo, or current/maximum armor if itemid is a ship.
Arguments
Type Name Description
number itemid itemid of an addon or ship.
Returns
Type Name Description
number current Current ammo/armor, or -1.
number maximum Maximum ammo/armor, or -1.
string name Name of weapon addon, otherwise nil