VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
affectEngineeringObjectController.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2014 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 #pragma once
10 
12 #include "vlutil/vlString.h"
15 
18 
22 {
23 public:
26  DtSimManager * simManager, DtComponentDescriptor* desc = NULL,
27  DtReaderWriterRegistry * parentRegistry = 0);
28 
31 
33  virtual bool init();
34 
35 private:
38 
41 
42 public:
43 
45  virtual bool createPSR();
46 
47  virtual const char* type() const = 0;
48 
49  virtual void tick();
50 
53  virtual void registerTaskMsgCallbacks();
54 
55  static void taskCompleteReportCallback(DtSimMessage* msg, void* usr);
56 
57  virtual void processTaskCompleteReport(DtSimMessage* msg);
58 
62  virtual bool tickWhileDestroyed() const;
63 
64 protected:
65 
67  virtual void processIdleState() = 0;
68 
71  virtual void processSettingUpState() = 0;
72 
75  virtual void processAffectingState() = 0;
76 
80  virtual void processAffectingPausedState() = 0;
81 
84  virtual void processMovingIntoRangeState() = 0;
85 
87  virtual void moveInRange(const DtVrfObject* obj, double range,
88  double objectRadius);
89 
92  virtual void moveInRange(const DtLocalVertexList& vertices,
93  double range, double objectRadius);
94 
97  virtual void moveInRange(const DtVector& location, double range,
98  double objectRadius);
99 
101  virtual bool isInRange(const DtVrfObject* obj, double range,
102  double objectRadius) const;
103 
105  virtual bool isInRange(const DtLocalVertexList& vertices, double range,
106  double objectRadius) const;
107 
109  virtual bool isInRange(const DtVector& location, double range,
110  double objectRadius) const;
111 
113  virtual bool isArealEngineeringObject(const DtObjectType& objectType) const;
114 
116  virtual bool isLinearEngineeringObject(const DtObjectType& objectType) const;
117 
119  virtual bool isPointEngineeringObject(const DtObjectType& objectType) const;
120 
121 protected:
122 
126 
127 };
128 
#define DT_DLL_vrfmodel
This file is used to determine how to build.
Definition: vrfmodelDefines.h:24
DtVrfObject is used to represent any type of simulated object (entities, aggregate, control objects) in a VR-Forces application.
Definition: vrfObject.h:215
DtAffectEngineeringObjectPSR * myProcessState
Pointer to a process state repository used to store state data associated with this component...
Definition: affectEngineeringObjectController.h:125
This is a process state repository for the DtAffectEngineeringObjectController.
Definition: affectEngineeringObjectPSR.h:29
virtual void registerTaskMsgCallbacks()
This class provides a base class for all controllers that are capable of executing a DtSimTask...
Definition: singleTaskControllerComponent.h:20
A readable, writable type whose name is the name of a component and that has a list of component name...
Definition: componentDescriptor.h:42
*virtual const DtObjectType & objectType() const
Definition: readerWriterRegistry.h:39
virtual const char * type() const =0
Returns a string identifies the class type of component.
virtual bool init()
Calls setRadio()
Definition: objectType.h:27
This is the base class for controllers which affect the creation and destruction of engineering objec...
Definition: affectEngineeringObjectController.h:21
File: simMsg.h.
Definition: simMessage.h:35
virtual void tick()
This gives the thread of control to the component.
virtual bool tickWhileDestroyed() const
If the component returns true here, it will be ticked regardless of the destroyed state of the host e...
const DtTaskControllerComponent & operator=(const DtTaskControllerComponent &orig)
assignment operator
The simulation engine is controlled by a single,top-level class called the Simulation Manager...
Definition: simManager.h:102
DtRwAffectableEngineeringObject holds a the information needed to know how a unit may create a type o...
Definition: rwAffectableEngineeringObject.h:22
class DtLocalVertexList:
Definition: localVertexList.h:20

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)