Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/src/world_entities/world_entity.h @ 4504

Last change on this file since 4504 was 4504, checked in by bensch, 19 years ago

orxonox/trunk: merged the SoundEngine into the Trunk.
merged file by file, but merged all the files in favor of the new trunk

File size: 1.7 KB
Line 
1/*!
2    \file world_entity.h
3    \brief Definition of the basic WorldEntity
4*/
5
6#ifndef _WORLD_ENTITY_H
7#define _WORLD_ENTITY_H
8
9#include "p_node.h"
10#include "comincl.h"
11#include "resource_manager.h"
12#include "factory.h"
13#include "load_param.h"
14
15//class CollisionCluster;
16class CharacterAttributes;
17class Model;
18class SoundEngine;
19class SoundBuffer;
20class SoundSource;
21
22//! Basic class from which all interactive stuff in the world is derived from
23class WorldEntity : public PNode
24{       
25  friend class World;
26
27 public:
28  WorldEntity(const TiXmlElement* root = NULL);
29  virtual ~WorldEntity ();
30
31  void loadParams(const TiXmlElement* root);
32  void loadModel(const char* fileName);
33
34  //void setCollision (CollisionCluster* newhull);
35 
36  //void addAbility(Ability* ability);
37  //void removeAbility(Ability* ability);
38  void setDrawable (bool bDraw); 
39  void setCharacterAttributes(CharacterAttributes* charAttr);
40  CharacterAttributes* getCharacterAttributes();
41
42  virtual void postSpawn ();
43  virtual void leftWorld ();
44
45  virtual void hit (WorldEntity* weapon, Vector* loc);
46  virtual void collide (WorldEntity* other,  Uint32 ownhitflags, Uint32 otherhitflags);
47  virtual void command (Command* cmd);
48
49  void processDraw ();
50  virtual void draw ();
51  virtual void tick (float time);
52 
53 protected:
54  Model* model;                  //!< The model that should be loaded for this entity.
55  CharacterAttributes* charAttr;      //!< the character attributes of a world_entity
56 
57 private:
58  bool bCollide;                      //!< If it should be considered for the collisiontest.
59  bool bDraw;                         //!< If it should be visible.
60
61
62
63  //CollisionCluster* collisioncluster; //!< The collision-Cluster of this entity.
64};
65
66#endif /* _WORLD_ENTITY_H */
Note: See TracBrowser for help on using the repository browser.