Dragonfly  4.3
A text-based game engine
EventStep.h
1 ///
2 /// A "step" event, generated once per game loop.
3 ///
4 
5 #ifndef __EVENT_STEP_H__
6 #define __EVENT_STEP_H__
7 
8 #include "Event.h"
9 
10 namespace df {
11 
12 const std::string STEP_EVENT = "df::step";
13 
14 class EventStep : public Event {
15 
16  private:
17  int m_step_count; /// Iteration number of game loop.
18 
19  public:
20  /// Default constructor.
21  EventStep();
22 
23  /// Constructor with initial step count.
24  EventStep(int init_step_count);
25 
26  /// Set step count.
27  void setStepCount(int new_step_count);
28 
29  /// Get step count.
30  int getStepCount() const;
31 };
32 
33 } // end of namespace df
34 #endif // __EVENT_STEP_H__
Definition: EventStep.h:14
Definition: Event.h:15
A 2-d bounding box.
Definition: Box.h:10
EventStep()
Iteration number of game loop.
void setStepCount(int new_step_count)
Set step count.
int getStepCount() const
Get step count.