VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
flyToLocationTask.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2005 MaK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 
10 #pragma once
11 
12 
13 #include "vrftasks/simTask.h"
14 #include <readerWriter/rwString.h>
15 #include "readerWriter/rwVector.h"
16 #include <vlpi/netStructs.h>
17 
18 
19 
21 {
22  DtNet64Vector myAimingPoint;
23  DtNetU8 myUseFixedPitch;
24  DtNetU8 myPadding1;
25  DtNetU16 myPadding2;
26 };
27 
35 
38 {
39 
40 public:
41 
44 
47  DtFlyToLocationTask(const DtString & writeName,
48  DtReaderWriterRegistry * parentRegistry = 0);
49 
51  DtFlyToLocationTask(const DtString & writeName, const DtFlyToLocationTask & orig,
52  DtReaderWriterRegistry * parentRegistry = 0);
53 
56 
57  virtual ~DtFlyToLocationTask();
58 
59  virtual const DtSimTaskMessageType& type() const;
60 
62  virtual DtSimTask * clone(const DtString & name, DtReaderWriterRegistry *
63  parentRegistry = 0) const;
64 
66  virtual DtString stringRep() const;
67 
70  virtual const DtVector & aimingPoint() const;
71  virtual void setAimingPoint(const DtVector & point);
72 
75  virtual int netRepSize() const;
76 
78  virtual bool setFromNet(const char* contentBuffer,
79  unsigned contentSize);
80 
81  virtual void setUseFixedPitch(bool);
82  virtual bool useFixedPitch() const;
83 
86  virtual bool setToNet();
87 
88  static DtSimTask * creator();
89 
90 protected:
91 
94 };
DtRwVector myAimingPoint
Definition: flyToLocationTask.h:92
DtNetU8 myUseFixedPitch
Definition: flyToLocationTask.h:23
DtRwBoolean myUseFixedPitch
Definition: flyToLocationTask.h:93
Definition: readerWriterRegistry.h:39
virtual DtSimTask * clone(const DtString &name, DtReaderWriterRegistry *parentRegistry=0) const =0
Make a copy of this task. Returns a newly allocated instance of a DtSimTask. Override this member fun...
DtNetU16 myPadding2
Definition: flyToLocationTask.h:25
Definition: rwVector.h:23
Definition: flyToLocationTask.h:20
virtual bool setFromNet(const char *contentBuffer, unsigned contentSize)
Sets mySubtask member from the incoming contentBuffer (cast to type DtNetSimTask). Derived classes should call down to this function first, and then extract their own data starting at the location contentBuffer + DtSimTask::netRepSize().
virtual bool setToNet()
Calls netRep() to create the network buffer. Casts the resulting myNetRep to type DtNetSimTask*...
DtNet64Vector myAimingPoint
Definition: flyToLocationTask.h:22
DtFlyToLocationTask represents a moveToLocation task for an entity to perform. It inherits read/writa...
Definition: flyToLocationTask.h:37
#define DT_DLL_vrftasks
This file is used to determine how to build.
Definition: vrftasksDefines.h:26
Description: Readable, Writable bool.
Definition: rwBoolean.h:26
DtSimTask is an abstract base class from which real tasks can derive. It manages the read/write capab...
Definition: simTask.h:30
virtual DtString stringRep() const =0
Returns a human-readable string representation of the task. This string representation is used to dis...
const DtSimTask & operator=(const DtSimTask &orig)
assignment operator; same as copy constructor
virtual const DtSimTaskMessageType & type() const =0
What kind of task am I? Returns a string indicating the kind of task (for example, “move-to”, “follow-entity”). Derived classes must implement this member function to return a unique string representing the type of task. The set of standard task types supplied with VR-Forces is in taskTypes.h.
File: rwVector.h.
virtual int netRepSize() const
Returns the size in bytes of the network representation of the class. This is the size in bytes of th...
DtNetU8 myPadding1
Definition: flyToLocationTask.h:24

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)