Add warehouse class

This commit is contained in:
omltcat
2026-01-26 20:11:25 +08:00
parent f50e33e1a3
commit c92b995da3
2 changed files with 25 additions and 1 deletions
+6 -1
View File
@@ -13,4 +13,9 @@ Airbase.Category = {
---Returns a localized string of the airbases's callsign.<br>
---In the case of airbases, the callsign of world airbases is defined by the game. Callsigns for units, farps, or ships can be specified by the user with the mission editor or scripting engine.
---@return string
function Airbase:getCallsign() end
function Airbase:getCallsign() end
---Returns the warehouse object associated with the airbase object.<br>
---Can then be used to call the warehouse class functions to modify the contents of the warehouse.
---@return Warehouse
function Airbase:getWarehouse() end
+19
View File
@@ -0,0 +1,19 @@
---@meta
---@class Warehouse
---@field whid_ string
Warehouse = {}
--- Adds the passed amount of a given item to the warehouse.<br>
---itemName is the typeName associated with the item: `weapons.missiles.AIM_54C_Mk47`<br>
---A wsType table can also be used, however the last digit with wsTypes has been known to change: `{4, 4, 7, 322}`
---@param item string|table
---@param count integer
function Warehouse:addItem(item, count) end
---Returns the number of the passed type of item currently in a warehouse object.<br>
---itemName is the typeName associated with the item: `weapons.missiles.AIM_54C_Mk47`<br>
---A wsType table can also be used, however the last digit with wsTypes has been known to change: `{4, 4, 7, 322}`
---@param item string|table
---@return integer
function Warehouse:getItemCount(item) end