Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/src/orxonox/objects/pickup/PickupSpawner.h @ 2663

Last change on this file since 2663 was 2662, checked in by rgrieder, 16 years ago

Merged presentation branch back to trunk.

  • Property svn:eol-style set to native
File size: 1.4 KB
RevLine 
[2227]1#ifndef _PickupSpawner_H__
2#define _PickupSpawner_H__
[2202]3
[2227]4#include "OrxonoxPrereqs.h"
[2500]5#include "BaseItem.h"
[2389]6#include "tools/Timer.h"
[2500]7#include "objects/worldentities/StaticEntity.h"
[2227]8#include "objects/Tickable.h"
9
[2202]10namespace orxonox
11{
[2500]12        class _OrxonoxExport PickupSpawner : public StaticEntity, public Tickable
[2202]13        {
14        public:
15        PickupSpawner(BaseObject* creator);
16        virtual ~PickupSpawner();
[2389]17        virtual void changedActivity();
[2227]18        virtual void tick(float dt);
[2389]19        virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode);
[2227]20        virtual void triggering(Pawn* trigger); // Wenn ein Spieler in die Naehe kommt
[2389]21        void triggerRespawnTimer();
[2202]22
[2389]23        /*inline void setVisibility(bool visible)
24                { this->setActive(visible); }
25        inline float getVisibility() const
26                { return this->isActive(); }*/
27
[2202]28        void setItemTemplate(const std::string& itemtemplate);
[2227]29        inline const std::string& getItemTemplate() const
[2202]30                { return this->itemtemplate_; }
[2227]31
32        inline void setDistance(float distance)
33                { this->distance_ = distance; }
34        inline float getDistance() const
35                { return this->distance_; }
[2389]36        inline void setRespawnTimer (float respawntimer)
37                { this->respawntimer_ = respawntimer; }
38        inline float getRespawnTimer() const
39                { return this->respawntimer_; }
[2342]40
[2202]41        private:
42        std::string itemtemplate_;
43        Template* template_;
[2227]44        float distance_;
[2389]45        float respawntimer_;
46        Timer<BaseObject> RespawnTimer_;
[2227]47        };
48}
49
50#endif /* _PickupSpawner_H__ */
[2202]51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
[2342]67
Note: See TracBrowser for help on using the repository browser.