Emergency 20 Dokumentation  4.2.0
ParkingVehicleCleanup.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 //[-------------------------------------------------------]
14 
15 
16 //[-------------------------------------------------------]
17 //[ Namespace ]
18 //[-------------------------------------------------------]
19 namespace em5
20 {
21 
22 
23  //[-------------------------------------------------------]
24  //[ Classes ]
25  //[-------------------------------------------------------]
32  {
33 
34 
35  //[-------------------------------------------------------]
36  //[ Public definitions ]
37  //[-------------------------------------------------------]
38  public:
39  static const uint32 GAMELOGIC_TYPE_ID; // "em5::ParkingVehicleCleanup" game logic type ID
40 
41 
42  //[-------------------------------------------------------]
43  //[ Public static methods ]
44  //[-------------------------------------------------------]
45  public:
46  static void createParkingVehicleCleanup(qsf::Entity& vehicleEntity);
47 
48 
49  //[-------------------------------------------------------]
50  //[ Public methods ]
51  //[-------------------------------------------------------]
52  public:
58 
64 
65  void init(qsf::Entity& originalEntity);
66  uint64 getOriginalEntityId() const;
67 
68 
69  //[-------------------------------------------------------]
70  //[ Public virtual qsf::GameLogic methods ]
71  //[-------------------------------------------------------]
72  public:
73  virtual bool onStartup() override;
74  virtual void onShutdown() override;
75 
76 
77  //[-------------------------------------------------------]
78  //[ Protected virtual em5::Cleanup methods ]
79  //[-------------------------------------------------------]
80  protected:
81  virtual Cleanup::CleanupResult onReadyForCleanupCheap() const override;
82  virtual ExecuteResult onExecuteCleanup() override;
83 
84 
85  //[-------------------------------------------------------]
86  //[ Private data ]
87  //[-------------------------------------------------------]
88  private:
89  uint32 mPrefabAssetIdBackup;
90  uint64 mMetaEntityId;
91  qsf::WeakPtr<qsf::Entity> mOriginalEntity;
92  uint32 mFreeplayEventId;
93 
94 
95  //[-------------------------------------------------------]
96  //[ CAMP reflection system ]
97  //[-------------------------------------------------------]
98  QSF_CAMP_RTTI() // Only adds the virtual method "campClassId()", nothing more
99 
100 
101  };
102 
103 
104 //[-------------------------------------------------------]
105 //[ Namespace ]
106 //[-------------------------------------------------------]
107 } // em5
108 
109 
110 //[-------------------------------------------------------]
111 //[ CAMP reflection system ]
112 //[-------------------------------------------------------]
Definition: ActionPriority.h:13
Entity class.
Definition: Entity.h:46
unsigned int uint32
Definition: PlatformTypes.h:181
CleanupResult
Definition: Cleanup.h:45
ExecuteResult
Definition: Cleanup.h:52
#define EM5_API_EXPORT
Definition: Export.h:28
uint64_t uint64
Definition: PlatformTypes.h:184
#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
Cleanup base class.
Definition: Cleanup.h:37
Cleanup for parking vehicle, it is restored at the original position This cleanup handles static vehi...
Definition: ParkingVehicleCleanup.h:31
static const uint32 GAMELOGIC_TYPE_ID
Definition: ParkingVehicleCleanup.h:39