![]() |
VR-Forces Developer's Guide
|
Abstract interface class for Weapon Information. This is used by DtWeaponInterfaceList. All code that is accessing information about weapons will have access to this base class only, and only be able to read the data. Weapon controllers will have derived versions that implement key functions for their specific weapon.

Public Types | |
| enum | TargetApplicability { TargetApplicability_Unspecified = 0, TargetApplicability_NotApplicable = 1, TargetApplicability_Overkill = 2, TargetApplicability_Applicable = 3, TargetApplicability_Ideal = 4 } |
| enum | WeaponStatus { WeaponStatus_Busy = 1, WeaponStatus_Disabled = 2, WeaponStatus_OutOfAmmo = 4, WeaponStatus_Suppressed = 8, WeaponStatus_Stowed = 16 } |
Public Member Functions | |
| DtWeaponInfoInterface () | |
| virtual | ~DtWeaponInfoInterface ()=0 |
| virtual DtString | displayName () const =0 |
| virtual DtU32 | status () const =0 |
| virtual DtString | statusString () const |
| virtual bool | ready () const |
| virtual bool | hasStatus (WeaponStatus testStatus) const |
| virtual std::list < DtSimTaskMessageType > | fireTaskTypes () const |
| virtual DtSimTask * | createFireTask (const DtRwLocationReference &location) const =0 |
| virtual bool | withinTargetRegion (const DtVector &localPosition) const =0 |
| virtual double | maximumRange () const =0 |
| virtual double | minimumRange () const =0 |
| virtual TargetApplicability | targetApplicability (const DtEntityType &type) const =0 |
| virtual bool | targetAmmunition (const DtEntityType &type) const =0 |
| virtual const std::list < DtEntityType > & | desiredAmmunition () const =0 |
| virtual const std::list < DtArtPartType > & | mountPartList () const =0 |
| virtual DtArtPartType | systemTurretNumber () const =0 |
| virtual bool | controlExternalTurret () const =0 |
| virtual const std::set < DtString > & | requiredTokens () const =0 |
| virtual bool | autonomousFire () const =0 |
| virtual const std::list < DtEntityType > & | autonomousTargetTypes () const =0 |
| virtual const DtRwProperties * | weaponProperties () const =0 |
| virtual int | priority () const =0 |
Static Public Member Functions | |
| static std::string | targetApplicabilityString (TargetApplicability app) |
| DtWeaponInfoInterface::DtWeaponInfoInterface | ( | ) |
|
pure virtual |
|
static |
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Weapon status bitfield. 0 indicates the weapon is in the "ready" state. For any non-0 value, the details of the status can be checked using the WeaponStatus bitfields on this return value.
Implemented in DtGenericWeaponInfo.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Task types that can be used to fire this weapon.
Reimplemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
List of the ammunition that is desired to be used by this weapon.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
A list of articulated parts to which this weapon is attached. That is, its parent part, that parent's part, etc. Used to determine when different weapons are dependent on the same part. The list contains articulated part type numbers.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
The articulated part corresponding to the turret in this gun system (as opposed to an ancestor part).
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Indicates that this weapon is controlling parent parts outside of the system to turn the gun. I.e., a tank MG is controlling the main turret in order to reach targets outside the normal slew range of the MG.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
List of resources required to operate the weapon; these are tokens that are reserved when the weapon operates, but are not consumed. There is no token reservation system; other components just check to see if their tokens against this set to see if there is a conflict. These tokens may represent crew members, for example.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Indicates whether on not this weapon should be used by VR-Forces autonomous fire controllers.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Returns the entity types which this weapon would be used against for autonomous fire.
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Implemented in DtGenericWeaponInfo.
|
pure virtual |
Priority of this weapon. Used to compare to other weapons on this platform if there are conflicts.
Implemented in DtGenericWeaponInfo.