Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/world_entities/power_ups/power_up.h @ 6424

Last change on this file since 6424 was 6424, checked in by bensch, 18 years ago

orxonox/trunk: merged the branche network back to the trunk
merged with command:
svn merge https://svn.orxonox.net/orxonox/branches/network . -r 6351:HEAD
no conflicts

File size: 848 bytes
RevLine 
[5433]1/*!
[5039]2 * @file power_up.h
[5433]3 * @brief A class representing a PowerUp in the world.
4*/
[2077]5
[3224]6#ifndef _POWER_UP_H
7#define _POWER_UP_H
[2077]8
9#include "world_entity.h"
10
[6113]11class Material;
12
13typedef enum PowerUpRespawn {
14  RESPAWN_NONE,
15  RESPAWN_TIME,
16  RESPAWN_size
17} PowerUpRespawn;
18
[5434]19class PowerUp : public WorldEntity {
[2077]20
[6113]21public:
22  void loadParams(const TiXmlElement* root);
23  void collidesWith (WorldEntity* entity, const Vector& location);
24
25  virtual void draw () const;
26  void setRespawnType(const char* type);
27
[6424]28  int       writeState(const byte* data, int length, int sender);
29  int       readState(byte* data, int maxLength );
30
[6113]31protected:
32  PowerUp(float r, float g, float b);
[3544]33  virtual ~PowerUp ();
[6113]34  virtual void respawn() {};
35
36private:
37  Material* sphereMaterial;
38  PowerUpRespawn respawnType;
39  static const char* respawnTypes[];
[2077]40};
41
[3224]42#endif /* _POWER_UP_H */
Note: See TracBrowser for help on using the repository browser.