Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: I've added mention of the new param CREATED_BY_PLAN to the unit, group, and vehicle objects. TN-781

Editor objects are all elements that exist in the editor (whether they have visible representation or not). They are only available while the editor is open (which can be tested by looking for the map control, by checking the applicationState, or setting an editorLoad.2C editorUnload).

The objects are defined by a string which follows this pattern: "_{type}_{index}", where type is one of the possible object types listed below, in the Arguments section, and {index} is a number, starting at 0 within each type, and then being incremented for each object. The index is never reduced or reset, even if all objects of that type have been deleted.
Examples:

"_unit_1"
"_group_0"
"_waypoint_12"

To acquire the editor object for a specific Object, you can use the findEditorObject command, e.g.

_edObj = map findEditorObject ["unit",player]; // may return "_unit_0" (as a string)

To do the reverse - finding the Object for an associated editor object, use the evalObjectArgument command, e.g.

_obj = map evalObjectArgument ["unit_0","VARIABLE_NAME"]; // may return WEST 1-1-A-1:1 (as an object)

Demo mission: addMenu.zip

Arguments

Editor objects have different arguments attached to them, which specify some of their properties.
Most of these arguments are only useful within the internal editor code, and none of them should ever be changed by a user, but some may give useful information about an object that is not available otherwise. More object information can be retrieved by examining the available VBS Object Variables.

All arguments are case-sensitive, and can be retrieved via getObjectArgument while the RTE is open.
The returned object can be either an array, another editor object or a string. e.g.

_dname = map getObjectArgument ["_artillery_0", "DISPLAY_NAME"]

THESE PROPERTIES SHOULD ONLY BE READ! MODIFYING THEM MAY LEAD TO UNPREDICTABLE RESULTS.

The following arguments are available in all editor objects:

  • DISPLAY_NAME: Name of editor object, as it appears in the object tree.
  • NAME: For those items that can be named, the name given in the edit window.
  • POSITION: Position3D of editor object.
  • VARIABLE_NAME: The editor object itself.

Object Types

artillery

  • COORDINATES: Strike coordinates.
  • DISPERSION: Impact radius.

camera

camera_waypoint

center

collection

controlstation

  • AUTO_ACTIVATE: Activate on vehicle entry
  • VARIABLE_NAME
  • ALLOW_LOCK: Allow camera locking
  • AUTO_ACTIVATE: Activate on vehicle entry
  • ACT_ON_START: Activate on mission start
  • SHOW_HINTS: Show hints
  • MARK_TARGETS: Can mark targets on map
  • MINIMAP: Enable mini-map
  • CHANGE_TARGET: Relocate locked target
  • AUTO_ORBIT:
  • ENABLE_RECORD: Allow video recording
  • RECORD_FRAMES: Recording FPS
  • RECORD_RESOLUTION_X: Recording resolution in X
  • RECORD_RESOLUTION_Y: Recording resolution in Y
  • COORD_TYPE: Coordinates Type
  • RECORD_UI: Recording UI

distance

  • LDIS: Distance (in meters) to previous distance object.

firesupport

  • PARENT: The vehicle fire support was requested from.

group

  • CREATED_BY_PLAN: VBS4 only. Whether the group was created by PLAN.

hidden

ied

  • PROXIMITY_DIS: Proximity distance.
  • VECTORDIR: vectorDir positioning information.
  • VECTORUP: vectorUp positioning information.

intel

knowledgeDatabase

lookAt

marker

  • A: Size (Left-Right).
  • B: Size (Up-Down).
  • ANGLE: Angle.
  • AUTOSCALE: Scale with map ("true" or "false").
  • CONDITION: Result of presence condition.
  • IS_INTERACTIVE: Set to "true" if marker is currently selected.

mine

object

  • V_ID: Visitor ID # if object has been promoted in editor (V1.50+)
  • AZIMUT: Positioning angle
  • HAS_CREW: Whether the vehicle is currently manned
  • HEALTH: Health status (1=undamaged, 0=destroyed)
  • TOWED_BY: Tow vehicle
  • VECTORDIR: vectorDir values
  • VECTORUP: vectorUp values

sound_source

trigger

  • A: Size (Left-Right).
  • B: Size (Up-Down).

unit

  • CARGO: Vehicle unit occupies cargo position in.
  • COMMANDER: Vehicle unit occupies commander position in.
  • DRIVER: Vehicle unit occupies driver position in.
  • GUNNER: Vehicle unit occupies gunner position in.
  • LEADER: Group leader.
  • LOADOUT: For custom units: [[weapons],[ammo],name]
  • PARENT: The group the unit belongs to. Empty, if single unit without waypoints.
  • PLAYABLE: Whether unit can be player-controlled ("true" or "false").
  • PLAYER: Whether the unit is currently controlled by the player.
  • CREATED_BY_PLAN: VBS4 only. Whether the unit was created by PLAN.

vehicle

  • ARC_DIR: Gunner Arc direction
  • ARC_WIDTH: Gunner Arc width angle
  • AZIMUT: Positioning angle
  • PARENT: The group of the vehicle's effectiveCommander.
  • HAS_CREW: Whether the vehicle is currently manned
  • HEALTH: Health status (1=undamaged, 0=destroyed)
  • TOWED_BY: Tow vehicle
  • TRIGGER: Trigger vehicle is attached to.
  • VECTORDIR: vectorDir values
  • VECTORUP: vectorUp values
  • CREATED_BY_PLAN: VBS4 only. Whether the vehicle was created by PLAN.

verbal_command

waypoint

  • AIRCRAFT_SPEED: Custom speed (in kts)
  • AIRCRAFT_HEIGHT: Aircraft height (in ft)
  • AZIMUT: Positioning angle
  • CONDITION: Result of waypoint condition
  • IS_HIGHLIGHTED: Whether the waypoint is currently selected (1 or 0)
  • NEXTTASK: Next waypoint in sequence
  • PARENT: Group waypoint belongs to
  • PARENT_UNIT: Group leader
  • PLACEMENT: Placement radius
  • PREVTASK: Previous waypoint in sequence
  • RADIUS: Loiter radius
  • TIMEOUT_MAX: Timeout min
  • TIMEOUT_MID: Timeout mid
  • TIMEOUT_MIN: Timeout max