Emergency 20 Dokumentation  4.2.0
GaperComponent.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 
17 
18 
19 //[-------------------------------------------------------]
20 //[ Namespace ]
21 //[-------------------------------------------------------]
22 namespace em5
23 {
24 
25 
26  //[-------------------------------------------------------]
27  //[ Classes ]
28  //[-------------------------------------------------------]
34  {
35 
36 
37  //[-------------------------------------------------------]
38  //[ Public definitions ]
39  //[-------------------------------------------------------]
40  public:
41  static const uint32 COMPONENT_ID;
42 
43 
44  //[-------------------------------------------------------]
45  //[ Public methods ]
46  //[-------------------------------------------------------]
47  public:
55  explicit GaperComponent(qsf::Prototype* prototype);
56 
61  virtual ~GaperComponent();
62 
63  bool getUseMobilephone() const;
64  void setUseMobilephone(bool useMobilephone);
65 
66 
67  //[-------------------------------------------------------]
68  //[ Public virtual qsf::Component methods ]
69  //[-------------------------------------------------------]
70  public:
71  virtual void serialize(qsf::BinarySerializer& serializer) override;
72 
73 
74  //[-------------------------------------------------------]
75  //[ Protected virtual qsf::Component methods ]
76  //[-------------------------------------------------------]
77  protected:
78  virtual void onSetSimulating(bool simulating) override;
79 
80 
81  //[-------------------------------------------------------]
82  //[ Protected virtual qsf::MovableObjectRenderingListener methods ]
83  //[-------------------------------------------------------]
84  protected:
85  virtual qsf::Component* getMovableObjectRenderingListenerComponent() override;
86  virtual void onObjectRenderingStartup() override;
87  virtual void onObjectRenderingShutdown() override;
88 
89 
90  //[-------------------------------------------------------]
91  //[ Private methods ]
92  //[-------------------------------------------------------]
93  private:
94  void updateAnimation(const qsf::JobArguments& jobArguments);
95  void resetWaitTimer();
96  bool preCheck();
97  void pushAnimation();
98 
99 
100  //[-------------------------------------------------------]
101  //[ Private data ]
102  //[-------------------------------------------------------]
103  private:
104  // Internal
105  qsf::JobProxy mAnimatingJobProxy;
106  qsf::Time mTimeGaping;
107  bool mUseMobilephone;
108 
109 
110  //[-------------------------------------------------------]
111  //[ CAMP reflection system ]
112  //[-------------------------------------------------------]
113  QSF_CAMP_RTTI() // Only adds the virtual method "campClassId()", nothing more
114 
115 
116  };
117 
118 
119 //[-------------------------------------------------------]
120 //[ Namespace ]
121 //[-------------------------------------------------------]
122 } // em5
123 
124 
125 //[-------------------------------------------------------]
126 //[ CAMP reflection system ]
127 //[-------------------------------------------------------]
Definition: ActionPriority.h:13
Job proxy class.
Definition: JobProxy.h:51
Abstract component class.
Definition: Component.h:105
Job proxy based OGRE movable object rendering listener.
Definition: JobProxyMovableObjectRenderingListener.h:31
unsigned int uint32
Definition: PlatformTypes.h:181
#define EM5_API_EXPORT
Definition: Export.h:28
EMERGENCY 5 gaper component class.
Definition: GaperComponent.h:33
Job arguments class: holds data to be passed to the called job method by the job manager.
Definition: JobArguments.h:40
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
#define QSF_CAMP_TYPE_NONCOPYABLE(type)
See "CAMP_TYPE_NONCOPYABLE" for details.
Definition: CampClass.h:112
static const uint32 COMPONENT_ID
"em5::GaperComponent" unique component ID
Definition: GaperComponent.h:41
Prototype class.
Definition: Prototype.h:100
Binary serializer class.
Definition: BinarySerializer.h:35
Data type for encapsulating time information. It might represents points in time and time spans...
Definition: Time.h:32