Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/pickups2/src/orxonox/objects/pickup/Turbo.h @ 2227

Last change on this file since 2227 was 2227, checked in by dsommer, 15 years ago

Turbo funktioniert

File size: 1003 bytes
Line 
1#ifndef _Turbo_H__
2#define _Turbo_H__
3
4#include "tools/Timer.h"
5#include "Item.h"
6#include "OrxonoxPrereqs.h"
7
8namespace orxonox
9{
10        class _OrxonoxExport Turbo : public Item
11        {
12       
13        public:
14        Turbo(BaseObject* creator);
15        virtual ~Turbo();
16
17        virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode);
18
19        virtual bool pickedUp(Pawn* player);
20        virtual bool dropped(Pawn* player); //erst bei festen Items
21
22        void setSpeedBoost(SpaceShip* ship);
23        void unsetSpeedBoost(SpaceShip* ship);
24
25        inline void setBoost(float boost)
26                { this->boost_ = boost; }
27        inline float getBoost() const
28                { return this->boost_; }
29
30        inline void setDuration(float duration)
31                { this->duration_ = duration; }
32        inline float getDuration() const
33                { return this->duration_; }
34
35       
36        inline void setAccBoost(float accboost)
37                { this->accboost_ = accboost; }
38        inline float getAccBoost() const
39                { return this->accboost_; }
40
41        private:
42        Timer<Turbo> turbotimer_;
43        float boost_;
44        float duration_;
45        float accboost_;
46        };
47}
48
49#endif /* _Turbo_H__ */
Note: See TracBrowser for help on using the repository browser.