Airbase#
Airbase represents airdromes, helipads, and ships with flight decks or landing
pads. It extends CoalitionObject (and, transitively,
Object).
- class Airbase#
Inherits all member functions of
CoalitionObjectandObject.Static functions#
- static getByName(name)#
Returns the
Airbasewith the given name, ornilif it does not exist.- Parameters:
name (
string) – Airbase name.- Returns:
The matching airbase, or
nil.- Return type:
- static getDescByName(typeName)#
Returns a description table for an airbase type.
- Parameters:
typeName (
string) – Airbase type name.- Returns:
Description table.
- Return type:
table
Member functions#
- getCallsign()#
Returns the airbase’s callsign.
- Returns:
Callsign.
- Return type:
string
- getUnit(unitNumber)#
For ship/carrier airbases, returns the underlying
Unitat the given unit number.- Parameters:
unitNumber (
number) – Unit number.- Returns:
The underlying unit.
- Return type:
- getID()#
Returns the airbase’s numeric ID.
- Returns:
Airbase ID.
- Return type:
number
- getCategoryEx()#
Returns the airbase’s more specific category (see Airbase.Category). Equivalent to
airbase:getDesc().category.- Returns:
Airbase category.
- Return type:
number
- getParking(available)#
Returns a table of parking spots at the airbase, optionally filtered to only currently-available spots.
- Parameters:
available (
boolean) – Optional; if true, only return free parking spots.- Returns:
Parking spot descriptor tables.
- Return type:
table
- getRunways()#
Returns a table describing the airbase’s runways.
- Returns:
Runway descriptor tables.
- Return type:
table
- getTechObjectPos(objectType, index)#
Returns the position of a named technical object (e.g. a specific building) at the airbase.
- Parameters:
objectType (
string) – Technical object type name.index (
number) – Index, if multiple objects of that type exist.
- Returns:
Position of the technical object.
- Return type:
table
- getDispatcherTowerPos()#
Returns the position of the airbase’s control tower.
- Returns:
Tower position.
- Return type:
table
- getRadioSilentMode()#
Returns whether the airbase’s ATC is currently in radio-silent mode.
- Returns:
Whether radio silence is active.
- Return type:
boolean
- setRadioSilentMode(silent)#
Enables or disables radio-silent mode for the airbase’s ATC.
- Parameters:
silent (
boolean) – Whether radio silence should be active.
- autoCapture(enabled)#
Enables or disables automatic coalition capture of the airbase (based on nearby ground forces).
- Parameters:
enabled (
boolean) – Whether auto-capture should be enabled.
- autoCaptureIsOn()#
Returns whether auto-capture is currently enabled for the airbase.
- Returns:
Whether auto-capture is enabled.
- Return type:
boolean
- setCoalition(coalitionId)#
Forcibly sets the airbase’s owning coalition, bypassing normal capture logic.
- Parameters:
coalitionId (
number) – New owning coalition (seecoalition.side).
Enumerators#
Airbase.Category identifies the specific airbase category (via
airbase:getDesc().category – not airbase:getCategory(), which always
returns Object.Category.BASE):
Value |
Meaning |
|---|---|
|
Land airdrome ( |
|
Helipad/FARP ( |
|
Ship with flight deck ( |
Footnotes#
Airbases can be enumerated via
coalition.getAirbases()orworld.getAirbases().