Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/archive/Presentation_HS16/src/modules/waypoints/WaypointGroup.h @ 11948

Last change on this file since 11948 was 11321, checked in by ooguz, 8 years ago

Distance Trigger works!

File size: 2.0 KB
Line 
1
2
3#ifndef _WaypointGroup_H__
4#define _WaypointGroup_H__
5
6#include "OrxonoxPrereqs.h"
7#include "Waypointprereqs.h"
8#include "worldentities/StaticEntity.h"
9#include "graphics/Model.h"
10#include "objects/triggers/DistanceTrigger.h"
11
12#include <map>
13#include <string>
14
15#include "core/CoreIncludes.h"
16#include "util/OgreForwardRefs.h"
17#include "Waypoint.h"
18
19namespace orxonox
20{
21    /**
22    @brief
23        The StaticEntity is the simplest derivative of the @ref orxonox::WorldEntity class. This means all StaticEntity instances also have
24        a position in space, a mass, a scale, a frication, ... because every StaticEntity is a WorldEntity. You can attach StaticEntities to eachother ike @ref orxonox::WorldEntity WorldEntities.
25
26        In contrast to the MobileEntity the StaticEntity cannot move with respect to the parent to which it is attached. That's why
27        it is called StaticEntity. It will keep the same position (always with respect to its parent) forever unless you call the
28        function @see setPosition to changee it.
29
30        A StaticEntity can only have the collisition type WorldEntity::None or WorldEntity::Static. The collsion types WorldEntity::Dynamic and WorldEntity::Kinematic are illegal.
31    */
32
33    class _OrxonoxExport WaypointGroup : public StaticEntity {
34
35        public:
36
37            WaypointGroup(Context* context);
38            virtual ~WaypointGroup();
39
40
41            virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) override;
42
43        //Waypoint* getWaypoint();
44        Waypoint* getWaypoint(unsigned int index);
45        void setWaypoint(Waypoint* object);
46
47
48        Waypoint* getActive();
49
50
51        void activateNext();
52
53        //Waypoint* getFirst();
54
55
56
57
58
59
60        private:
61
62            //virtual bool isCollisionTypeLegal(CollisionType type) const override;
63
64        std::set<Waypoint*> waypoints_;
65        Waypoint* activeWaypoint;
66        unsigned int current = 0;
67        //std::set<Waypoint*>::iterator it;
68
69            // network callbacks
70    };
71}
72
73#endif /* _Waypoint_H__ */
Note: See TracBrowser for help on using the repository browser.