diff options
author | David Walter Seikel | 2014-01-13 19:47:58 +1000 |
---|---|---|
committer | David Walter Seikel | 2014-01-13 19:47:58 +1000 |
commit | f9158592e1478b2013afc7041d9ed041cf2d2f4a (patch) | |
tree | b16e389d7988700e21b4c9741044cefa536dcbae /libraries/irrlicht-1.8.1/source/Irrlicht/CParticleGravityAffector.h | |
parent | Libraries readme updated with change markers and more of the Irrlicht changes. (diff) | |
download | SledjHamr-f9158592e1478b2013afc7041d9ed041cf2d2f4a.zip SledjHamr-f9158592e1478b2013afc7041d9ed041cf2d2f4a.tar.gz SledjHamr-f9158592e1478b2013afc7041d9ed041cf2d2f4a.tar.bz2 SledjHamr-f9158592e1478b2013afc7041d9ed041cf2d2f4a.tar.xz |
Update Irrlicht to 1.8.1. Include actual change markers this time. lol
Diffstat (limited to '')
-rw-r--r-- | libraries/irrlicht-1.8.1/source/Irrlicht/CParticleGravityAffector.h | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/libraries/irrlicht-1.8.1/source/Irrlicht/CParticleGravityAffector.h b/libraries/irrlicht-1.8.1/source/Irrlicht/CParticleGravityAffector.h new file mode 100644 index 0000000..5491b51 --- /dev/null +++ b/libraries/irrlicht-1.8.1/source/Irrlicht/CParticleGravityAffector.h | |||
@@ -0,0 +1,64 @@ | |||
1 | // Copyright (C) 2002-2012 Nikolaus Gebhardt | ||
2 | // This file is part of the "Irrlicht Engine". | ||
3 | // For conditions of distribution and use, see copyright notice in irrlicht.h | ||
4 | |||
5 | #ifndef __C_PARTICLE_GRAVITY_AFFECTOR_H_INCLUDED__ | ||
6 | #define __C_PARTICLE_GRAVITY_AFFECTOR_H_INCLUDED__ | ||
7 | |||
8 | #include "IParticleGravityAffector.h" | ||
9 | #include "SColor.h" | ||
10 | |||
11 | namespace irr | ||
12 | { | ||
13 | namespace scene | ||
14 | { | ||
15 | |||
16 | //! Particle Affector for affecting direction of particle | ||
17 | class CParticleGravityAffector : public IParticleGravityAffector | ||
18 | { | ||
19 | public: | ||
20 | |||
21 | CParticleGravityAffector( | ||
22 | const core::vector3df& gravity = core::vector3df(0.0f,-0.03f,0.0f), | ||
23 | u32 timeForceLost = 1000); | ||
24 | |||
25 | //! Affects a particle. | ||
26 | virtual void affect(u32 now, SParticle* particlearray, u32 count); | ||
27 | |||
28 | //! Set the time in milliseconds when the gravity force is totally | ||
29 | //! lost and the particle does not move any more. | ||
30 | virtual void setTimeForceLost( f32 timeForceLost ) { TimeForceLost = timeForceLost; } | ||
31 | |||
32 | //! Set the direction and force of gravity. | ||
33 | virtual void setGravity( const core::vector3df& gravity ) { Gravity = gravity; } | ||
34 | |||
35 | //! Set the time in milliseconds when the gravity force is totally | ||
36 | //! lost and the particle does not move any more. | ||
37 | virtual f32 getTimeForceLost() const { return TimeForceLost; } | ||
38 | |||
39 | //! Set the direction and force of gravity. | ||
40 | virtual const core::vector3df& getGravity() const { return Gravity; } | ||
41 | |||
42 | //! Writes attributes of the object. | ||
43 | //! Implement this to expose the attributes of your scene node animator for | ||
44 | //! scripting languages, editors, debuggers or xml serialization purposes. | ||
45 | virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options) const; | ||
46 | |||
47 | //! Reads attributes of the object. | ||
48 | //! Implement this to set the attributes of your scene node animator for | ||
49 | //! scripting languages, editors, debuggers or xml deserialization purposes. | ||
50 | //! \param startIndex: start index where to start reading attributes. | ||
51 | //! \return: returns last index of an attribute read by this affector | ||
52 | virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options); | ||
53 | |||
54 | private: | ||
55 | f32 TimeForceLost; | ||
56 | core::vector3df Gravity; | ||
57 | }; | ||
58 | |||
59 | } // end namespace scene | ||
60 | } // end namespace irr | ||
61 | |||
62 | |||
63 | #endif | ||
64 | |||