![]() |
VR-Forces 5.0.2 Developer's Guide
|
The "this" version is the own-ship object. It is separated to
allow special functions for the ownship that are not available for other objects. ///////////////////////////////////////////////////////////////////////!

Public Member Functions | |
| DtScriptOwnshipObject (DtLocalObject *const localObject) | |
| DtScriptOwnshipObject (const DtScriptOwnshipObject &orig) | |
| ~DtScriptOwnshipObject () | |
| virtual void | attachToParent (DtScriptVrfObject &) const |
| virtual std::list < DtScriptVrfObject > | getAllVrfSubordinates (bool isVrf) const |
| DtSimulationServices * | simulationServices () const |
| virtual bool | isValid () const |
| void | setLocation3D (const DtLocation3D &newloc) |
| void | setHeading (const double heading) |
| void | setPitch (const double heading) |
| virtual void | setLabel (const std::string &) |
| virtual void | setExtendedLabel (int, const std::string &) |
| virtual void | setNavigationEnabled (bool) |
| DtLocalObject * | ownshipObject () |
| const DtLocalObject * | ownshipObject () const |
| virtual std::list< std::string > | getResourceNames (void) const |
| virtual double | getResourceAmounts (const std::string &resourceName, double *fullAmount) const |
| virtual void | depleteResource (const std::string &resourceName, double amount) |
| virtual void | replenishResource (const std::string &resourceName, double amount) |
| virtual int | getNotifyLevel () const |
| virtual std::string | getCurrentFormationName () |
| virtual DtVectorOffset3D | getFormationExtent () |
| virtual std::string | getMunitionType (const std::string &resourceName) |
| virtual bool | addResource (const std::string &resourceType, const std::string &resourceName, double currentAmount, double fullAmount) |
| virtual void | updateStateAndParameterProperties () |
| virtual void | removeResource (const std::string &resourceName) |
| virtual double | getOrderedSpeed () const |
| virtual bool | isUnderFire () const |
| virtual int | suppressionLevel () const |
| virtual std::string | nonLethalDamageEffect () const |
| virtual std::list < DtScriptVrfObject > | getObservedHostileContacts (void) |
| virtual std::list < DtScriptVrfObject > | getAllHostileContacts (void) |
| virtual std::list < DtScriptVrfObject > | getAllContacts (void) |
| virtual int | targetPriority (const DtScriptVrfObject &otherEntity) |
| virtual bool | registerDetonationInterest (double range, const std::string &munitionType) |
| virtual bool | registerFireInterest (double range, const std::string &munitionType) |
| virtual bool | getLastDetonation (std::string &munitionType, DtLocation3D &location) |
| virtual bool | getLastFire (std::string &munitionType, DtLocation3D &location) |
| virtual void | setDestroyed (bool destroyed) |
| virtual std::string | getRulesOfEngagement () |
| virtual void | setRulesOfEngagement (const std::string &rule) |
| virtual std::list< std::string > | embeddedEntityNames () |
| virtual std::list< std::string > | embeddedEntitiesOfType (std::string typeString) |
| virtual std::list< std::string > | embeddedEntitiesCapableOf (std::string taskSetName) |
| virtual DtScriptVrfObject | simObjectByEmbeddedEntityName (std::string eeName) |
| virtual std::string | embeddedEntityStatus (std::string eeName) |
| virtual double | normalizedSensorSignature (const DtScriptVrfObject &targetEntity, std::string domain) |
| virtual void | changeAttachment (const std::string &parentUUID) |
| virtual void | setExtendedData (const std::string &key, const std::string &val) |
| virtual bool | canFireAt (const DtLocation3D &location) |
| virtual boost::shared_ptr < DtScriptComponentSystem > | lookupSystem (const std::string &systemName) |
| virtual std::list< std::string > | getSystemNames () |
| virtual std::string | getSystemCategory (const std::string &systemName) |
| virtual bool | isEmbarked () const |
| virtual DtScriptVrfObject | getEmbarkedOn () const |
| virtual bool | getNavigationEnabled () const |
| virtual void | clearAssignedTransport () const |
| virtual DtScriptVrfObject | getAssignedTransport () |
| virtual void | setAssignedTransport (DtScriptVrfObject &) const |
| virtual bool | hasStateProperty (const std::string &propertyName) |
| virtual bool | hasParameterProperty (const std::string &propertyName) |
Public Member Functions inherited from DtScriptVrfObject | |
| DtScriptVrfObject (const DtSimulationServices *, const DtUUID &name) | |
| DtScriptVrfObject (DtSimObjectReference) | |
| DtScriptVrfObject (const DtScriptVrfObject &orig) | |
| DtScriptVrfObject () | |
| DtScriptVrfObject & | operator= (const DtScriptVrfObject &orig) |
| ~DtScriptVrfObject () | |
| bool | operator== (const DtScriptVrfObject &orig) |
| virtual std::list< std::string > | getFormationNames () |
| virtual std::list< int > | getFormationPromotionOrder (const std::string &formationName) |
| virtual std::list< std::string > | formationSubFormations (const std::string &formationName) |
| virtual double | getHeightAboveTerrain (bool &available) const |
| virtual bool | hasLosToObject (const DtScriptVrfObject &target, bool &dataAvailable) const |
| virtual bool | isPointInside (const DtLocation3D &point) const |
| virtual bool | independentlyTasked () const |
| virtual bool | hasLosToLocation (DtLocation3D &targetLoc, bool &dataAvailable) const |
| virtual std::string | getEntityType () const |
| virtual bool | isAggregate () const |
| virtual bool | isPseudoAggregate () const |
| virtual std::string | getEchelonLevel () const |
| virtual std::string | getForceType () const |
| virtual int | getForceEnumeration () const |
| virtual std::string | getDamageState () const |
| virtual unsigned | getLifeformPosture () const |
| virtual unsigned | getAppearance () const |
| virtual bool | isDestroyed () const |
| virtual bool | isFirePowerKilled () const |
| virtual bool | isMobilityKilled () const |
| virtual bool | isSensorKilled () const |
| virtual bool | isInvisible () const |
| virtual bool | isOnTopOf (DtScriptVrfObject &) const |
| virtual bool | isOnTopOfWithDistance (DtScriptVrfObject &, double) const |
| virtual std::list < DtScriptVrfObject > | getEmbarkedObjects (void) const |
| virtual DtVectorOffset3D | getOffsetFromParent () const |
| virtual DtVectorOffset3D | getOffsetOfLocation (const DtLocation3D &location) const |
| virtual std::list < DtScriptVrfObject > | getSubordinates (void) const |
| virtual std::list < DtScriptVrfObject > | getVrfSubordinates (bool isVrf) const |
| virtual DtScriptVrfObject | getSuperior () const |
| virtual double | recalculatePhysicalFootprintFromSubordinates (const std::list< DtScriptVrfObject > &) const |
| virtual std::list < DtScriptVrfObject > | getAllSubordinates (void) const |
| virtual std::list < DtScriptVrfObject > | getCapableSubordinates (void) const |
| virtual std::list < DtScriptVrfObject > | getCapableVrfSubordinates (bool isVrf) const |
| virtual bool | isVrfSimulated () const |
| virtual std::list< DtLocation3D > | getLocations3D (void) const |
| virtual std::string | getName () const |
| virtual std::string | getLabel () const |
| virtual std::string | getExtendedLabel (int) const |
| virtual int | getAirTurbulence () const |
| virtual std::string | getGlobalId () const |
| virtual std::string | getObjectId () const |
| virtual double | getHeading () const |
| virtual double | getPitch () const |
| virtual double | getRoll () const |
| virtual double | getDraft () const |
| void | terrainSurfaceDebug () |
| void | deleteObject () |
| bool | isDeleted () const |
| virtual bool | isLocal () const |
| virtual DtVectorOffset3D | getBoundingVolume (DtVectorOffset3D &offset) const |
| virtual DtVectorOffset3D | getBoundingVolumeAllSubordinates (bool bIncludeDestroyedSubordinates, DtVectorOffset3D &offset) const |
| virtual std::string | getNbcDamage (int &dmgPerSec, int &moppLvl) const |
| virtual std::string | getNbcAgent () const |
| virtual bool | isBreached () const |
| virtual std::string | getExtendedData (const std::string &key) const |
| virtual DtLocation3D | getClosestPointToLocation2D (const DtLocation3D &location, double &distance) const |
| virtual DtLocation3D | getIntersectionPointWithLine2D (const DtLocation3D &point1, const DtLocation3D &point2, bool &hasIntersection) const |
| virtual bool | isActive () const |
| virtual std::string | getDiGuyHandItem () const |
| virtual bool | isAnimationAvailable (const std::string &animationName) const |
| virtual bool | isAppearanceAvailable (const std::string &appearanceName) const |
| virtual bool | isHandItemAvailable (const std::string &handItemName) const |
| virtual bool | isHeadAvailable (const std::string &headName) const |
| virtual bool | isGestureAvailable (const std::string &gestureName) const |
| virtual double | animationDuration (const std::string &animationName) const |
| virtual double | animationSpeed (const std::string &animationName) const |
| virtual double | getAnimationTransitionInfo (const std::string &fromAnimation, const std::string &toAnimation, DtVectorOffset3D &deltaPos, double &deltaHeading) const |
| virtual void | setSimulationServices (const DtSimulationServices *simManager) |
| virtual DtString | objectType () const |
| DtString | serialize () |
| virtual bool | deserialize (const DtString &data) |
| DtSimObjectReference | vrfObject () const |
| void | testValid () const |
| bool | testAggregateSimObjectValid () const |
| const DtSimulationServices * | simulationServices () const |
| virtual DtLocation3D | getLocation3D () const |
| virtual DtLocation3D | getLocation3dAllSubordinates (bool bIncludeDestroyedSubordinates) const |
| virtual double | getSpeed () const |
| virtual std::string | getUUID () const |
| virtual DtVector3D | getDirection3D () const |
| virtual DtVector3D | getVelocity3D () const |
| virtual DtVectorOffset3D | getPartParentPosition (int) const |
| virtual DtLocation3D | getPartWorldPosition (int) const |
| virtual double | getPartPitch (int) const |
| virtual double | getPartPitchIncludingParent (int, bool includeParent=false) const |
| virtual double | getPartHeading (int) const |
| virtual double | getPartHeadingIncludingParent (int, bool includeParent=false) const |
| virtual double | getPartTranslationForward (int) const |
| virtual double | getPartTranslationRight (int) const |
| virtual double | getPartTranslationUp (int) const |
Public Member Functions inherited from DtAsciiSerializable | |
| DtAsciiSerializable () | |
| DtAsciiSerializable (const DtAsciiSerializable &orig) | |
| virtual | ~DtAsciiSerializable () |
| virtual std::string | objectTypeC () const |
| virtual void | init (void *userData) |
Protected Attributes | |
| std::string | myLastDetonationMunition |
| DtLocation3D | myLastDetonationLocation |
| std::string | myLastFireMunition |
| DtLocation3D | myLastFireLocation |
| std::map< std::string, DtScriptComponentSystem * > | myScriptComponentSystems |
| DtLocalObject * | myLocalObject |
Protected Attributes inherited from DtScriptVrfObject | |
| DtRwUUID | myUUID |
| const DtSimulationServices * | mySimulationServices |
| DtSimObjectReference | mySimObjectReference |
| DtVrfSimulatedSimObjectFacade | myVrfSimulatedSimObjectFacade |
| DtAggregateSimObjectFacade * | myAggregateSimObjectFacade |
| DtPlatformSimObjectFacade | myPlatformSimObjectFacade |
| static bool | processDetonation (const DtDetonationContext &detonationContext, void *usr) |
| bool | processDetonation (const DtDetonationContext &detonationContext) |
| static bool | processFire (const DtFireContext &fireContext, void *usr) |
| bool | processFire (const DtFireContext &fireContext) |
Additional Inherited Members | |
Static Public Member Functions inherited from DtScriptVrfObject | |
| static DtAsciiSerializable * | creator () |
| static DtScriptVrfObject | nullObject () |
| DtScriptOwnshipObject::DtScriptOwnshipObject | ( | DtLocalObject *const | localObject | ) |
| DtScriptOwnshipObject::DtScriptOwnshipObject | ( | const DtScriptOwnshipObject & | orig | ) |
| DtScriptOwnshipObject::~DtScriptOwnshipObject | ( | ) |
| void DtScriptOwnshipObject::setLocation3D | ( | const DtLocation3D & | newloc | ) |
Script API functions.
| void DtScriptOwnshipObject::setHeading | ( | const double | heading | ) |
Script API functions.
| void DtScriptOwnshipObject::setPitch | ( | const double | heading | ) |
Script API functions.
|
virtual |
Script API functions.
|
virtual |
Script API functions.
|
virtual |
Script API functions.
| DtLocalObject* DtScriptOwnshipObject::ownshipObject | ( | ) |
Ownship can modify itself.
| const DtLocalObject* DtScriptOwnshipObject::ownshipObject | ( | ) | const |
Script API functions.
|
virtual |
Script API functions.
|
virtual |
Returns the current amount as the return value for the supplied resource name.
Note that in the Lua interface, fullAmount is a pure_out_value, meaning that the parameter is not included as a function argument, but is provided as a second return value of the function. E.g. use: curAmount, fullAmount = getResourceAmounts(resourceName)
|
virtual |
Deplete the resource by the current amount, not going below zero.
|
virtual |
Replenishes the resource amount, not going above full.
|
virtual |
Returns the notify level this object is currently set to.
|
virtual |
Gets the name of the active formation.
|
virtual |
Gets the formation extent from the formation state.
|
virtual |
Returns the entity type of the munition resource. If it is not a munition type the empty string is returned.
|
virtual |
Adds a new resource given the type, name (including any systems it should be in) current amount and full amount. If the resource type (see rsrcTypes.h) is not valid will not create resource. Return true if resource is created.
|
virtual |
If this is a psuedo aggregate will update state and parameter properties in the state repository given the composition of the leaf nodes and their current values.
|
virtual |
Removes the resource from the supplied system.
|
virtual |
|
virtual |
True if under fire, as defined in the object state repository.
|
virtual |
Returns the suppression level: an integer from 0 to 3. 0 indicates not suppressed, and the entity is considered suppressed for levels 1-3.
|
virtual |
Returns the non lethal damage type of the entity.
|
virtual |
It gets the list of contacts for the entity and filters out all but known hostile objects that were detected by sensors (vs. just spot reports).
|
virtual |
It gets the list of contacts for the entity and filters out all but known hostile objects. The Lua API function requires this list be returned in a table, so there is a wrapper function for it in the vrfLua module.
|
virtual |
It gets the list of contacts and returns it. The Lua API function requires this list be returned in a table, so there is a wrapper function for it in the vrfLua module.
|
virtual |
It gets the list of priority targets and returns it. The Lua API function requires this list be returned in a table, so there is a wrapper function for it in the vrfLua module.
|
virtual |
It registers interest in any detonation that occurs within the specified range of the object with the specified munition type.
|
virtual |
It registers interest in any fire that occurs within the specified range of the object with the specified munition type.
|
virtual |
If interest in detonations has previously been registered, this function will return the munition type and location of the detonation. If no detonations have been received since the last call to this function, it returns false.
|
virtual |
If interest in fires has previously been registered, this function will return the munition type and location of the fire. If no fires have been received since the last call to this function, it returns false.
|
virtual |
Sets the damage state of this entity to be destroyed if true, or not damaged if false.
|
virtual |
Returns the current rules of engagement of this entity.
|
virtual |
Sets the rules of engagement of this entity.
|
virtual |
Returns the complete list of Embedded Entity names available to this object.
|
virtual |
Returns a list of Embedded Entity names available to this object matching the given typeString, where typeString is a string representation of the seven digit DIS enumeration. (e.g. "1:2:-1:-1:-1:-1:-1")
|
virtual |
Returns a list of Embedded Entity names available to this object that are capable of the given task/set, where taskSetName is the string identifier of any task or set. (e.g. "turn-to-heading" or "set-destroy")
|
virtual |
Returns the DtScriptVrfObject corresponding to the given Embedded Entity name. isValid will return false if there is no corresponding DtScriptVrfObject, either because it is recovered, or the Embedded Entity is not available(configured) on this object.
|
virtual |
Returns the deployment status of the Embedded Entity with the given name. Return values are one of "recovered", "deleted", "destroyed", "deployed", and "unknown". "unknown" is only applicable if the given Embedded Entity is not available(configured) on this object.
|
virtual |
This function determines if the given target entity is detectable by the ownship entity in the given domain. The function is intended for use when the ownship entity does not have a given sensor, or it is not sensing the target entity type, and a script wants to know if a target entity is detectable. The function assumes that a normalized signature of 1.0 is required for detection. That is, a generic detection table has entries for normalized signatures only as low as 1.0. A normalized signature is computed by dividing signature by range in km, so this condition means that the entity is within a range that is equal to its raw signature in km.
The domain is.
|
virtual |
This allows the object to change its attachment without using the embarkation controller which is some circumstances is not desired. Simple change attachment will not make any assumptions about placement of the object unlike embarkation which calculates where it thinks this object should be. If the parentName is null then the object will be detached if it is currenly attached.
|
virtual |
Sets the extended data with the given key to the new value.
|
virtual |
Can fire at a location given the rules of engagement.
|
virtual |
Gets a script component system from the system name.
|
virtual |
Gets a list of all system names for this entity.
|
virtual |
Gets the category, e.g. movement, weapon, etc., of the given system. The systemName is the display name of the system.
|
virtual |
Script API functions above. ////////////////////////////////////!
Overrides to look at next rather than current frame Returns whether or not this item is embarked on any other item
Reimplemented from DtScriptVrfObject.
|
virtual |
Parent this object is embarked on.
Reimplemented from DtScriptVrfObject.
|
virtual |
Accessor for navigation by gameware enabled/disabled.
|
virtual |
Given an object which is a parent, attach to it (immediate embark)
|
virtual |
The given object is your assigned transport.
|
virtual |
The given object is your assigned transport.
|
virtual |
The given object is your assigned transport.
|
virtual |
Checks to see if the property exists. Because the sim object might not yet be available when a script is initialized, use the next frame state to get it.
Reimplemented from DtScriptVrfObject.
|
virtual |
Checks to see if the property exists. Because the sim object might not yet be available when a script is initialized, use the next frame state to get it.
Reimplemented from DtScriptVrfObject.
|
virtual |
Use next frame (not current frame) subordiantes as this might change within a tick.
Reimplemented from DtScriptVrfObject.
| DtSimulationServices* DtScriptOwnshipObject::simulationServices | ( | ) | const |
Simulation services associated with this object.
|
virtual |
Reimplemented from DtScriptVrfObject.
|
staticprotected |
Callback to process new detonations.
|
protected |
Callback to process new detonations.
|
staticprotected |
Callback to process new fires.
|
protected |
Callback to process new fires.
|
protected |
The munition type of the last detonation.
|
protected |
The location of the last detonation.
|
protected |
The munition type of the last fire.
|
protected |
The location of the last fire.
|
protected |
List of systems which we have previously looked up, by name.
|
mutableprotected |