VR-Forces 4.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrfmodel
aggregatedPatrolController.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2004 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
8
12
13
#pragma once
14
15
#include "
vrfobjcore/singleTaskControllerComponent.h
"
16
#include "
vrfmodel/vrfmodelDefines.h
"
17
18
class
DtFormationState
;
19
class
DtAggregatedPatrolPSR
;
20
class
DtVrfObjectManager
;
21
32
class
DT_DLL_vrfmodel
DtAggregatedPatrolController
:
public
DtSingleTaskControllerComponent
33
{
34
public
:
35
36
enum
DtPatrolAlongState
37
{
38
DtMovingAlongRoute = 0,
39
DtReversingDirection = 1
40
};
41
44
DtAggregatedPatrolController
(
const
DtString
& name,
45
DtVrfObject
* owner,
46
DtSimManager
* simManager,
47
DtComponentDescriptor
* desc = 0,
48
DtReaderWriterRegistry
* parentRegistry = 0);
49
51
virtual
~
DtAggregatedPatrolController
();
52
55
virtual
DtString
type
()
const
;
56
59
virtual
bool
init
();
60
62
virtual
void
registerTaskMsgCallbacks
();
63
66
DtSimTaskStatePtr
currentTaskState
()
const
;
67
72
static
void
patrolTwoPointsTaskCallback(
DtSimMessage
* msg,
void
* usr,
DtSimTaskStatePtr
taskStatePtr);
73
77
static
void
patrolAlongTaskCallback(
DtSimMessage
* msg,
void
* usr,
DtSimTaskStatePtr
taskStatePtr);
78
83
static
void
taskCompleteReportCallback(
DtSimMessage
* msg,
void
* usr);
84
88
static
DtSimComponent
* creator(
const
DtString
& name,
89
DtVrfObject
* owner,
90
DtSimManager
* simManager,
91
DtComponentDescriptor
* desc = 0,
92
DtReaderWriterRegistry
* parentRegistry = 0);
93
94
protected
:
95
100
virtual
void
onPatrolTwoPointsTask(
DtSimMessage
* msg,
DtSimTaskStatePtr
taskStatePtr);
101
109
virtual
void
onTaskComplete(
DtSimMessage
* msg);
110
118
virtual
bool
moveTo(
const
DtString
& controlPointName);
119
123
virtual
void
processPatrolAlongTask(
DtSimMessage
* msg,
DtSimTaskStatePtr
taskStatePtr);
124
130
virtual
bool
createPSR();
131
139
virtual
DtIteratorDirection
initialTraversalDirection(
140
const
DtString
& routeName,
const
DtVector
& initialWorldPosition)
const
;
141
150
virtual
void
sendMoveAlongToSelf(
const
DtString
& routeName,
151
enum
DtIteratorDirection
traversalDirection
,
bool
startAtClosestPoint);
152
153
private
:
154
156
DtAggregatedPatrolController
(
const
DtAggregatedPatrolController
& orig);
157
159
DtAggregatedPatrolController
&
operator=
(
const
DtAggregatedPatrolController
& orig);
160
protected
:
161
164
DtAggregatedPatrolPSR
*
myProcessState
;
165
};
166
Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)