YAPOG  0.0.1
Yet Another Pokemon Online Game
MapEvent.hpp
Go to the documentation of this file.
1 #ifndef YAPOG_MAPEVENT_HPP
2 # define YAPOG_MAPEVENT_HPP
3 
4 # include "YAPOG/Macros.hpp"
8 
9 namespace yap
10 {
11  struct IMapEventCondition;
12  struct IMapEventAction;
13  struct ICollidable;
14 
15  class BoundingBox;
16  class MapEventArgs;
17  class EventBoundingBoxCollection;
18  class DynamicWorldObject;
19 
21  {
23 
24  public:
25 
26  MapEvent ();
27  virtual ~MapEvent ();
28 
29  bool Call (MapEventActionType actionType, MapEventArgs& args);
30 
31  void AddBoundingBox (BoundingBox* boundingBox);
32  void RemoveBoundingBox (BoundingBox* boundingBox);
33 
34  void AddCondition (IMapEventCondition* condition);
35  void RemoveCondition (IMapEventCondition* condition);
36  void AddAction (IMapEventAction* action);
37  void RemoveAction (IMapEventAction* action);
38 
39  void AddToEventBoundingBoxCollection (
40  EventBoundingBoxCollection& eventBoundingBoxCollection,
41  const DynamicWorldObject& parent);
42  void RemoveFromEventBoundingBoxCollection (
43  EventBoundingBoxCollection& eventBoundingBoxCollection);
44 
45  bool CollidesWith (const ICollidable& collidable) const;
46 
49  virtual MapEvent* Clone () const;
51 
52  protected:
53 
54  MapEvent (const MapEvent& copy);
55 
56  virtual bool HandleCall (
57  MapEventActionType actionType,
58  MapEventArgs& args);
59 
60  private:
61 
63 
66  };
67 } // namespace yap
68 
69 #endif // YAPOG_MAPEVENT_HPP