Emergency 20 Dokumentation  4.2.0
ArrivedAtDespawnAction.h
Go to the documentation of this file.
1 // Copyright (C) 2012-2018 Promotion Software GmbH
2 
3 
4 //[-------------------------------------------------------]
5 //[ Header guard ]
6 //[-------------------------------------------------------]
7 #pragma once
8 
9 
10 //[-------------------------------------------------------]
11 //[ Includes ]
12 //[-------------------------------------------------------]
13 #include "em5/Export.h"
14 
16 
18 
19 
20 //[-------------------------------------------------------]
21 //[ Namespace ]
22 //[-------------------------------------------------------]
23 namespace em5
24 {
25 
26 
27  //[-------------------------------------------------------]
28  //[ Classes ]
29  //[-------------------------------------------------------]
38  {
39 
40 
41  //[-------------------------------------------------------]
42  //[ Public definitions ]
43  //[-------------------------------------------------------]
44  public:
46 
47 
48  //[-------------------------------------------------------]
49  //[ Public methods ]
50  //[-------------------------------------------------------]
51  public:
57 
62  virtual ~ArrivedAtDespawnAction();
63 
71  void init(const qsf::logic::TargetPoint& targetPoint);
72  void init(const std::vector<qsf::logic::TargetPoint>& targetPoints);
73 
74 
75  //[-------------------------------------------------------]
76  //[ Public virtual qsf::Actions methods ]
77  //[-------------------------------------------------------]
78  public:
79  virtual void serialize(qsf::BinarySerializer& serializer) override;
80 
81 
82  //[-------------------------------------------------------]
83  //[ Protected virtual qsf::Action methods ]
84  //[-------------------------------------------------------]
85  protected:
86  virtual qsf::action::Result updateAction(const qsf::Clock& clock) override;
87 
88 
89  //[-------------------------------------------------------]
90  //[ Private data ]
91  //[-------------------------------------------------------]
92  private:
93  std::vector<qsf::logic::TargetPoint> mTargetPoints;
94 
95 
96  //[-------------------------------------------------------]
97  //[ CAMP reflection system ]
98  //[-------------------------------------------------------]
99  QSF_CAMP_RTTI() // Only adds the virtual method "campClassId()", nothing more
100 
101 
102  };
103 
104 
105 //[-------------------------------------------------------]
106 //[ Namespace ]
107 //[-------------------------------------------------------]
108 } // em5
109 
110 
111 //[-------------------------------------------------------]
112 //[ CAMP reflection system ]
113 //[-------------------------------------------------------]
Definition: ActionPriority.h:13
EMERGENCY 5 arrived at spawn action.
Definition: ArrivedAtDespawnAction.h:37
A target point is a spatial configuration that allows an interaction between two entities. Since a target point is relative to the interacting as well as the interacted on entity it can be dynamic and is often invalidated as soon as one of the entities moves. Simple class that is copyable via the default mechanisms and public members because it is only a tiny data collection.
Definition: TargetPoint.h:39
Clock class.
Definition: Clock.h:33
#define EM5_API_EXPORT
Definition: Export.h:28
void serialize(BinarySerializer &serializer, BitFlagSet< STORAGE, ENUM > &bitFlagSet)
Definition: BitFlagSet.h:359
#define QSF_CAMP_RTTI()
Only adds the virtual method "campClassId()", nothing more.
Definition: CampClass.h:75
static const qsf::NamedIdentifier ACTION_ID
"em5::ArrivedAtDespawnAction" unique action identifier
Definition: ArrivedAtDespawnAction.h:45
#define QSF_CAMP_TYPE_NONCOPYABLE(type)
See "CAMP_TYPE_NONCOPYABLE" for details.
Definition: CampClass.h:112
Abstract action base class.
Definition: Action.h:59
Class combining strings with their hashes.
Definition: NamedIdentifier.h:34
Binary serializer class.
Definition: BinarySerializer.h:35
Result
Definition: ActionResult.h:20