Versions Compared
Key
- This line was added.
- This line was removed.
- Formatting was changed.
Excerpt |
---|
Describes a structure (something a truck can build) on the map. |
Properties
Info |
---|
Inherits all the properties of a Game objects (id, x, y, z, player, selected, name, health, armour, thermal, born, etc.) then adds/overrides the properties listed below. |
Property | Type | Description | Game version | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
type | Constant | STRUCTURE | 3.1 | ||||||||||
status | Constant | Describes construction status of the structure:
| 3.1 | ||||||||||
stattype | Constant | What sort of structure is it?
| 3.1 | ||||||||||
modules | Number, | The number of modules built on the structure, or Warzone 3.1 Beta 2 and earlier: The property would not exist for structures that couldn't have modules. | 3.1 beta 2 | ||||||||||
group | Number | The group that the structure is in, or null if it's not in a group. | 3.2 | ||||||||||
cost | Number | What did the structure cost to build? | 3.2 | ||||||||||
range | Number, Null | The maximum range of the structures' weapon, or It's not clear whether range will be present for sensors. | 3.2 | ||||||||||
isSensor | Boolean | Does this structure have a sensor on it?
| 3.2 | ||||||||||
isCB | Boolean | Does this structure have a counter battery (CB) turret on it?
| 3.2 | ||||||||||
isRadarDetector | Boolean | Does this structure have a radar detector on it?
| 3.2 | ||||||||||
canHitAir | Boolean | Can this structure attack aircraft (VTOLs / transports)?
| 3.2 | ||||||||||
canHitGround | Boolean | Can this structure attack ground units and other structures?
| 3.2 | ||||||||||
hasIndirect | Boolean | Does this structure have an indirect fire weapon (such as artillery or archangel missiles)?
| 3.2 | ||||||||||
weapons | Array of Weapon Status | An array containing basic information about the weapons attached to the droid. Each object in the array contains two properties:
| 3.2 |
Div | ||||||
---|---|---|---|---|---|---|
| ||||||
Availability
Introduced in:
|
Div | ||||
---|---|---|---|---|
| ||||
ContentsJump to:
|
Div | ||
---|---|---|
| ||
Where to get them?Lots of API features return structure objects, including... Functions: enumArea(), enumRange(), enumStruct(), enumStructOffWorld(), label(), objFromId() Events: eventAttacked(), eventAttackedUnthrottled(), eventDestroyed(), eventDroidBuilt(), eventObjectSeen(), eventObjectTransfer(), eventResearched(), eventStructureBuilt(), eventStructureReady() Other: If specified when using queue() or setTimer(), the resultant function calls will be passed a structure object. If you bind() to a structure object, the function called when it is destroyed will be passed the structure object. |
Div | ||
---|---|---|
| ||
Working with StructuresCreate them:
Remove them:
List them:
Tell them what to do:
Find out what's happening to them:
|
Div | ||
---|---|---|
| ||
See alsoRelated articles:
|