Module Object

This module contains the OBJECT class.

1) Wrapper.Object#OBJECT class, extends Core.Base#BASE

The Wrapper.Object#OBJECT class is a wrapper class to handle the DCS Object objects:

  • Support all DCS Object APIs.
  • Enhance with Object specific APIs not in the DCS Object API set.
  • Manage the "state" of the DCS Object.

1.1) OBJECT constructor:

The OBJECT class provides the following functions to construct a OBJECT instance:

1.2) OBJECT methods:

The following methods can be used to identify an Object object:


Global(s)

OBJECT

Type DCSObject

DCSObject.id_

The ID of the controllable in DCS

Type OBJECT

OBJECT.ClassName
OBJECT:Destroy()

Destroys the OBJECT.

OBJECT:GetID()

Returns the unit's unique identifier.

OBJECT:New(ObjectName)

Create a new OBJECT from a DCSObject

OBJECT.ObjectName

The name of the Object.

Global(s)

#OBJECT OBJECT

Type Object

Type DCSObject

A DCSObject

Field(s)

DCSObject.id_

The ID of the controllable in DCS

Type OBJECT

The OBJECT class

Field(s)

#string OBJECT.ClassName
OBJECT:Destroy()

Destroys the OBJECT.

Return value

#nil: The DCS Unit is not existing or alive.

OBJECT:GetID()

Returns the unit's unique identifier.

Return values

  1. Dcs.DCSWrapper.Object#Object.ID: ObjectID

  2. #nil: The DCS Object is not existing or alive.

OBJECT:New(ObjectName)

Create a new OBJECT from a DCSObject

Parameter

Return value

#OBJECT: self

#string OBJECT.ObjectName

The name of the Object.