VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
movingObjectParameters.h
Go to the documentation of this file.
1 /****************************************************************************
2  * Copyright (c) 2021 MAK Technologies, Inc.
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
14 #include "readerWriter/rwVector.h"
17 
18 class DtEnvironment;
19 
33 {
34 public:
35 
37  DtMovingObjectParameters(const DtString& name = DtString::nullString(),
38  DtReaderWriterRegistry* parentRegistry = NULL,
39  DtEnvironmentSP env = DtEnvironmentSP(), DtEnvValueSP* objectNode = NULL);
41  DtReaderWriterRegistry* parentRegistry = NULL,
42  DtEnvironmentSP env = DtEnvironmentSP(), DtEnvValueSP* objectNode = NULL);
43 
45  virtual ~DtMovingObjectParameters();
46 
47 protected:
50  const DtString& name = DtString::nullString(),
51  DtReaderWriterRegistry* parentRegistry = NULL);
53  const DtSymbolString& name,
54  DtReaderWriterRegistry* parentRegistry = NULL);
55 
56 public:
58  const DtMovingObjectParameters& operator=
59  (const DtMovingObjectParameters& orig);
60 
62  (const DtString& name = DtString::nullString(),
63  DtReaderWriterRegistry* parentRegistry = NULL) const;
65  (const DtSymbolString& name,
66  DtReaderWriterRegistry* parentRegistry = NULL) const;
67 
70  virtual DtString type() const;
71 
73  static DtVrfObjectParameters * creator(DtEnvironmentSP env, DtEnvValueSP* objectNode);
74 
77  virtual bool inheritValues (const DtVrfObjectParameters* benefactor);
78  virtual void inheritValuesFromThisType (
79  const DtMovingObjectParameters* benefactor);
80 
81 private:
84 public:
85 
88  virtual int illuminationRecalcTime() const;
89  virtual void setIlluminationRecalcTime(int newValue);
91 
94  virtual int weatherAreaRecalcTime() const;
95  virtual void setWeatherAreaRecalcTime(int newValue);
97 
100  virtual bool canPivot() const;
101  virtual void setCanPivot (bool newValue);
103 
106  virtual bool protectEmbarkedFromCollateralDamage() const;
107  virtual void setProtectEmbarkedFromCollateralDamage (bool newValue);
109 
112  virtual DtReal maxPivotSpeed() const;
113  virtual void setMaxPivotSpeed (DtReal maxSpeed);
115 
118  virtual const DtVector& leftSupport() const;
119  virtual void setLeftSupport (const DtVector& newLeftSupport);
121 
124  virtual const DtVector& rightSupport() const;
125  virtual void setRightSupport (const DtVector& newRightSupport);
127 
130  virtual const DtVector& otherSupport() const;
131  virtual void setOtherSupport (const DtVector& newOtherSupport);
133 
136  virtual DtReal maxSpeed() const;
137  virtual void setMaxSpeed (DtReal speed);
139 
142  virtual DtReal maxReverseSpeed() const;
143  virtual void setMaxReverseSpeed (DtReal speed);
145 
148  virtual bool useModelArtPartInformation() const;
149  virtual void setUseModelArtPartInformation(bool);
151 
154  virtual DtReal turningRadius() const;
155  virtual void setTurningRadius (DtReal turningRadius);
157 
160  virtual DtReal maxSlope() const;
161  virtual void setMaxSlope (DtReal slope);
163 
166  virtual DtReal orderedSpeed() const;
167  virtual void setOrderedSpeed (DtReal speed);
169 
172  virtual DtReal maxAcceleration() const;
173  virtual void setMaxAcceleration (const DtReal maxAcceleration);
175 
178  virtual DtReal maxStoppingDeceleration() const;
179  virtual void setMaxStoppingDeceleration (const DtReal maxStoppingDeceleration);
181 
184  virtual DtReal maxLateralAcceleration() const;
185  virtual void setMaxLateralAcceleration (const DtReal maxLateralAcceleration);
187 
190  virtual DtReal fuelEfficiency() const;
191  virtual void setFuelEfficiency (const DtReal efficiency);
193 
196  virtual bool useObjectGeometry() const;
197  virtual void setUseObjectGeometry(bool);
199 
202  virtual bool useObjectVisuals() const;
203  virtual void setUseObjectVisuals(bool);
205 
208  virtual const DtString& objectGeometryFile() const;
209  virtual void setObjectGeometryFile(const DtFilename&);
211 
214  virtual bool embedIntoTerrain() const;
215  virtual void setEmbedIntoTerrain(bool);
217 
220  virtual void setDIGuyCharacterInfo(const DtRwDIGuyCharacterInfo & info);
221  virtual const DtRwDIGuyCharacterInfo & diguyCharacterInfo() const;
223 
226  virtual void setUsingRailMovement(bool rails);
227  virtual bool usingRailMovement() const;
229 
230  virtual void postGetSelf();
231 
232 protected:
233 
237 
243 
250 
260 
270 
280 
286 
293 
302 
319 
326 
332 
338 
346 
359 
368 
374 
380 
385 
391 
400 
407 
414 
421 
427 
428 };
Instances of DtVrfObjectParameters are the readable/writeable objects that contain the information ne...
Definition: vrfObjectParameters.h:63
This class allows one to collect and compare strings using an index number instead of having to do st...
Definition: symbolString.h:27
#define DT_DLL_vrfobjparam
This file is used to determine how to build.
Definition: vrfobjparamDefines.h:28
DtRwReal myMaxStoppingDeceleration
Parameter Name: max-deceleration Parameter Description: The maximum (braking) deceleration for the en...
Definition: movingObjectParameters.h:337
virtual void postGetSelf()
Called after either version of getSelf (mtl or environment). Default is no-op.
DtRwBoolean myUseObjectVisuals
Parameter Name: use-object-visuals Parameter Description: If specified, use the visuals as defined fo...
Definition: movingObjectParameters.h:379
DT_DLL_readerWriter DtBoost::shared_ptr< DtEnvironment > DtEnvironmentSP
Definition: readerWriter.h:30
DtRwDIGuyCharacterInfo myDIGuyCharacterInfo
Parameter Name: di-guy-character Parameter Description: DI-Guy representation of the entity if any...
Definition: movingObjectParameters.h:390
virtual bool inheritValues(const DtVrfObjectParameters *benefactor)
Values left unspecified may be inherited from a parameter block of the same type, typically an ancest...
virtual DtVrfObjectParameters * clone(const DtString &name=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=NULL) const
Definition: readerWriterRegistry.h:39
DtRwReal myMaxSlope
Parameter Name: max-slope Parameter Description: For ground entities, the maximum slope...
Definition: movingObjectParameters.h:318
static DtVrfObjectParameters * creator(DtEnvironmentSP env, DtEnvValueSP *objectNode)
DtRwReal myOrderedSpeed
Parameter Name: ordered-speed Parameter Description: The speed the entity will move when tasked...
Definition: movingObjectParameters.h:325
DtRwBoolean myProtectEmbarkedFromCollateralDamage
Parameter Name: protect-embarked-from-collateral-damage Parameter Description: If true...
Definition: movingObjectParameters.h:420
DtRwReal myMaxReverseSpeed
Parameter Name: max-reverse-speed Parameter Description: The maximum speed at which an entity can mov...
Definition: movingObjectParameters.h:292
DtRwOffsetVector myOtherSupport
Parameter Name: other-support Parameter Description: Support contact point in body coordinates...
Definition: movingObjectParameters.h:279
Contains the DtRwDIGuyCharacterInfo class declaration.
DtRwOffsetVector myRightSupport
Parameter Name: right-support Parameter Description: Support contact point in body coordinates...
Definition: movingObjectParameters.h:269
DtRwInt myWeatherAreaRecalcTime
Parameter Name: weather-area-recalc-time Parameter Description: Amount of time (in seconds) to recalc...
Definition: movingObjectParameters.h:413
Description: Readable, Writable int.
Definition: rwInt.h:25
DtRwBoolean myEmbedIntoTerrain
Parameter Name: embed-into-terrain Parameter Description: If true this object&#39;s geometry will be embe...
Definition: movingObjectParameters.h:384
virtual void inheritValuesFromThisType(const DtVrfObjectParameters *benefactor)
The moving-object-param parameter type is used for objects that are capable of movement, such as individual entities and aggregates. DtMovingObjectParameters; holds all of the configurable parameters for the DtVrfMovingObjectStateRepository class. Parameters include support points, maximum speed, maximum reverse speed, turning radius, maximum slope, ordered speed, maximum acceleration, maximum deceleration, and fuel efficiency. Aggregates are moving objects and have this parameter type. All of the platform-specific parameter types derive from this one. .
Definition: movingObjectParameters.h:32
DtRwBoolean myCanPivot
Parameter Name: can-pivot Parameter Description: Indicates whether not the entity can pivot to turn...
Definition: movingObjectParameters.h:242
Description: Readable, Writable DtReal (double)
Definition: rwReal.h:27
DtRwReal myMaxLateralAcceleration
Parameter Name: max-lateral-acceleration Parameter Description: The maximum lateral (turning) acceler...
Definition: movingObjectParameters.h:345
The DtRwDIGuyCharactertInfo class is a readable/writable class that can store itself and read itself ...
Definition: rwDIGuyCharacterInfo.h:32
DtRwBoolean myUseObjectGeometry
Parameter Name: use-object-geometry Parameter Description: If specified use the geometry file for nav...
Definition: movingObjectParameters.h:373
Specialized vector that can be used for the knowledge of an &quot;offset&quot; rather than location vector...
Definition: rwVector.h:109
Description: Readable, Writable bool.
Definition: rwBoolean.h:26
DtRwReal myTurningRadius
Parameter Name: turning-radius Parameter Description: Minimum turning radius. This will be used diffe...
Definition: movingObjectParameters.h:301
DtRwInt myIlluminationRecalcTime
Parameter Name: illumination-recalc-time Parameter Description: Amount of time (in seconds) to recalc...
Definition: movingObjectParameters.h:406
virtual DtString type() const
Returns a string identifying the type of parameter descriptor. Used to create the descriptor on read ...
DtRwReal myMaxSpeed
Parameter Name: max-speed Parameter Description: The top speed of the entity. Parameter Default Value...
Definition: movingObjectParameters.h:285
DtRwReal myMaxPivotSpeed
Parameter Name: max-pivot-speed Parameter Description: The maximum rate at which a ground entity can ...
Definition: movingObjectParameters.h:249
DtRwReal myMaxAcceleration
Parameter Name: max-acceleration Parameter Description: The maximum acceleration rate for the entity...
Definition: movingObjectParameters.h:331
Using a DtReaderWriterFile allows a DtReaderWriter object to be read in from an MTL stream contained ...
Definition: readerWriterFile.h:35
DtRwBoolean myUsingRailMovement
Parameter Name: using-rail-movement Parameter Description: If true entity will clamp to a route segme...
Definition: movingObjectParameters.h:399
DtReaderWriterFile myObjectGeometryFile
Parameter Name: object-geometry-file Parameter Description: If the object geometry is defined (a poly...
Definition: movingObjectParameters.h:367
File: rwVector.h.
DtRwOffsetVector myLeftSupport
Parameter Name: left-support Parameter Description: Support contact point in body coordinates...
Definition: movingObjectParameters.h:259
DtRwBoolean myUseModelArtPartInformation
Whether or not to load articulated part information from model as well. If there is an object geometr...
Definition: movingObjectParameters.h:426
DtRwReal myFuelEfficiency
Parameter Name: fuel-efficiency Parameter Description: Air and ground entities: the number of meters ...
Definition: movingObjectParameters.h:358

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)