Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/world_entities/effects/lightning_bolt.h @ 7460

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

orxonox/trunk: Namespaces for sound

File size: 1.6 KB
Line 
1/*!
2 * @file lightning_bolt.h
3 * @brief a LightningBolt Projectile
4 *  Der Effekt soll folgendermaßen funktionieren:
5 * -> Ein Partikel mit einer Blitz-Textur soll sehr schnell erscheinen,
6 * -> während er an Intensität zunimmt soll die Beleuchtung der gerenderten Szene entsprechend zunehmen.
7 * -> Je mehr Blitze zum gleichen Zeitpunkt sichtbar sind, desto heller soll die Beleuchtung werden, das heißt die Helligkeitszunahme pro Blitz soll Additiv sein.
8 * -> Ein Partikel soll ebenfalls sehr schnell wieder verblassen, dabei soll die Beleuchtung entsprechend der vorhergehenden Zunahme wieder abnehmen (Additiv)
9 */
10
11#ifndef _LIGHTNING_BOLT_H
12#define _LIGHTNING_BOLT_H
13
14#include "world_entity.h"
15
16#include "sound_buffer.h"
17#include "sound_source.h"
18
19class Material;
20
21class LightningBolt : public WorldEntity
22{
23  public:
24    LightningBolt(const TiXmlElement* root = NULL);
25    virtual ~LightningBolt ();
26
27    virtual void activate();
28    virtual void deactivate();
29
30    virtual void tick(float time);
31    virtual void draw() const;
32
33  private:
34    float flashFrequency;                   //!< frequency to activate itself
35    float flashRisingTime;                  //!< time to rise
36    float flashConstTime;                   //!< time to be drawn
37    float flashFallTime;                    //!< time to fall
38
39    float time;                             //!< time
40
41    bool  bRender;
42    bool  bNewCoordinate;
43    Material*      material;
44    Vector         offset;
45    float width;
46    float height;
47
48    float seedX;
49    float seedZ;
50    float seedTime;
51
52    OrxSound::SoundSource    soundSource;
53    OrxSound::SoundBuffer*   thunderBuffer;
54};
55
56#endif /* _LIGHTNING_BOLT_H */
Note: See TracBrowser for help on using the repository browser.