AppEasy Core SDK
1.5.0
Cross platform mobile and desktop app and game development SDK - The easy way to make apps
|
A particle. More...
#include <CzActorParticles.h>
Public Member Functions | |
CzActorParticle () | |
virtual | ~CzActorParticle () |
void | Update (float dt) |
Updates this particle. | |
void | CopyToOld () |
Makes a copy of particle transient data. | |
void | CopyFromOld () |
Restores particle transient data. Used to reset a particle. | |
CzActorParticle * | Clone () |
Clones the oarticle. | |
bool | setProperty (unsigned int property_name, const CzXomlProperty &data, bool delta) |
Sets the named property of the particle. | |
bool | setProperty (unsigned int property_name, const CzString &data, bool delta) |
Sets the named property of the particle. | |
bool | getProperty (unsigned int property_name, CzXomlProperty &prop) |
Gets the named property of the property. | |
Static Public Member Functions | |
static void | InitClass () |
Initialises the class. | |
static void | ReleaseClass () |
static bool | _setPosition (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getPosition (IzXomlResource *target) |
static bool | _setSize (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getSize (IzXomlResource *target) |
static bool | _setVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getVelocity (IzXomlResource *target) |
static bool | _setVelocityDamping (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getVelocityDamping (IzXomlResource *target) |
static bool | _setGravity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getGravity (IzXomlResource *target) |
static bool | _setScale (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getScale (IzXomlResource *target) |
static bool | _setScaleVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getScaleVelocity (IzXomlResource *target) |
static bool | _setScaleVelocityDamping (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getScaleVelocityDamping (IzXomlResource *target) |
static bool | _setAngle (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getAngle (IzXomlResource *target) |
static bool | _setAngularVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getAngularVelocity (IzXomlResource *target) |
static bool | _setAngularVelocityDamping (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getAngularVelocityDamping (IzXomlResource *target) |
static bool | _setColour (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getColour (IzXomlResource *target) |
static bool | _setColourVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getColourVelocity (IzXomlResource *target) |
static bool | _setColourVelocityDamping (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getColourVelocityDamping (IzXomlResource *target) |
static bool | _setDepth (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getDepth (IzXomlResource *target) |
static bool | _setDepthVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getDepthVelocity (IzXomlResource *target) |
static bool | _setDepthVelocityDamping (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getDepthVelocityDamping (IzXomlResource *target) |
static bool | _setActive (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getActive (IzXomlResource *target) |
static bool | _setVisible (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getVisible (IzXomlResource *target) |
static bool | _setLifeSpan (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getLifeSpan (IzXomlResource *target) |
static bool | _setSpawnDelay (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getSpawnDelay (IzXomlResource *target) |
static bool | _setLifeTime (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getLifeTime (IzXomlResource *target) |
static bool | _setLives (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getLives (IzXomlResource *target) |
static bool | _setOPosition (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOPosition (IzXomlResource *target) |
static bool | _setOVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOVelocity (IzXomlResource *target) |
static bool | _setOScale (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOScale (IzXomlResource *target) |
static bool | _setOScaleVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOScaleVelocity (IzXomlResource *target) |
static bool | _setOAngle (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOAngle (IzXomlResource *target) |
static bool | _setOAngularVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOAngularVelocity (IzXomlResource *target) |
static bool | _setOColour (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOColour (IzXomlResource *target) |
static bool | _setOColourVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getOColourVelocity (IzXomlResource *target) |
static bool | _setODepth (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getODepth (IzXomlResource *target) |
static bool | _setODepthVelocity (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getODepthVelocity (IzXomlResource *target) |
static bool | _setAttached (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getAttached (IzXomlResource *target) |
static bool | _setSrcRect (IzXomlResource *target, const CzXomlProperty &prop, bool add) |
static CzXomlProperty | _getSrcRect (IzXomlResource *target) |
Public Attributes | |
CzActorParticles * | Parent |
Particles parent emitter. | |
CzBitmapSprite * | Visual |
Visual element that represents the particle. | |
CzVec2 | Position |
Position relative to particle system actor. | |
CzVec2 | Velocity |
Velocity of particle. | |
CzVec2 | VelocityDamping |
Velocity damping for particle. | |
CzVec2 | Gravity |
Gravitational acceleration. | |
CzVec2 | Scale |
Scale of particle. | |
CzVec2 | ScaleVelocity |
Scale velocity of particle. | |
CzVec2 | ScaleVelocityDamping |
Scale velocity of particle. | |
float | Angle |
Rotation of particle. | |
float | AngularVelocity |
Rotation of particle. | |
float | AngularVelocityDamping |
Rotation of particle. | |
CzVec4 | Colour |
Particle colour. | |
CzVec4 | ColourVelocity |
Particle colour velocity. | |
CzVec4 | ColourVelocityDamping |
Particle colour velocity damping. | |
float | Depth |
Depth of particle. | |
float | DepthVelocity |
Depth velocity of particle. | |
float | DepthVelocityDamping |
Depth velocity damping of particle. | |
bool | Active |
Active state. | |
bool | Visible |
Visible state. | |
float | LifeSpan |
Total duration of particle in seconds. | |
float | SpawnDelay |
Amount of time to wait before spawning in seconds. | |
float | LifeTime |
Current life time in seconds. | |
int | Lives |
Number of lives for particle (how time it will be respawned) | |
CzVec2 | OPosition |
Original Position relative to particle system actor. | |
CzVec2 | OVelocity |
Original Velocity of particle. | |
CzVec2 | OScale |
Original Scale of particle. | |
CzVec2 | OScaleVelocity |
Original Scale velocity of particle. | |
float | OAngle |
Original Rotation of particle. | |
float | OAngularVelocity |
Original Rotation veloxity of particle. | |
CzVec4 | OColour |
Original Particle colour. | |
CzVec4 | OColourVelocity |
Original Particle colour velocity. | |
float | ODepth |
Original Depth of particle. | |
float | ODepthVelocity |
Original Depth velocity of particle. | |
bool | Attached |
Attached particles will follow the particle actor. | |
Static Protected Attributes | |
static CzXomlClassDef * | ActorParticleClassDef = NULL |
A particle.
CzActorParticle::CzActorParticle | ( | ) | [inline] |
CzActorParticle::~CzActorParticle | ( | ) | [virtual] |
CzXomlProperty CzActorParticle::_getActive | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getAngle | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getAngularVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getAngularVelocityDamping | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getAttached | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getColour | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getColourVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getColourVelocityDamping | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getDepth | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getDepthVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getDepthVelocityDamping | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getGravity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getLifeSpan | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getLifeTime | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getLives | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOAngle | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOAngularVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOColour | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOColourVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getODepth | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getODepthVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOPosition | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOScale | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOScaleVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getOVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getPosition | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getScale | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getScaleVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getScaleVelocityDamping | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getSize | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getSpawnDelay | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getSrcRect | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getVelocity | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getVelocityDamping | ( | IzXomlResource * | target | ) | [static] |
CzXomlProperty CzActorParticle::_getVisible | ( | IzXomlResource * | target | ) | [static] |
bool CzActorParticle::_setActive | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setAngle | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setAngularVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setAngularVelocityDamping | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setAttached | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setColour | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setColourVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setColourVelocityDamping | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setDepth | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setDepthVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setDepthVelocityDamping | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setGravity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setLifeSpan | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setLifeTime | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setLives | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOAngle | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOAngularVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOColour | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOColourVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setODepth | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setODepthVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOPosition | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOScale | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOScaleVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setOVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setPosition | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setScale | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setScaleVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setScaleVelocityDamping | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setSize | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setSpawnDelay | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setSrcRect | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setVelocity | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setVelocityDamping | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
bool CzActorParticle::_setVisible | ( | IzXomlResource * | target, |
const CzXomlProperty & | prop, | ||
bool | add | ||
) | [static] |
Clones the oarticle.
void CzActorParticle::CopyFromOld | ( | ) |
Restores particle transient data. Used to reset a particle.
void CzActorParticle::CopyToOld | ( | ) |
Makes a copy of particle transient data.
bool CzActorParticle::getProperty | ( | unsigned int | property_name, |
CzXomlProperty & | prop | ||
) |
Gets the named property of the property.
Returns the named property of the particle. The properties value is returned in a CzXomlProperty which is a structure that contains a union of all possible property types.
property_name | Name of the property. | |
[out] | prop | The property data that. |
void CzActorParticle::InitClass | ( | ) | [static] |
Initialises the class.
Sets up the classes avaiiable properties. Used by the XOML system to find, set amd get class properties.
void CzActorParticle::ReleaseClass | ( | ) | [static] |
bool CzActorParticle::setProperty | ( | unsigned int | property_name, |
const CzXomlProperty & | data, | ||
bool | delta | ||
) |
Sets the named property of the particle.
Sets the named property of this particle. The properties value supplied will be converted. If delta is set to true then the existing value of the property will be added to instead of replaced.
property_name | Name of the property as a string hash (faster searching). | |
[in] | data | The property data. |
delta | true if property should be added to instead of replaced. |
bool CzActorParticle::setProperty | ( | unsigned int | property_name, |
const CzString & | data, | ||
bool | delta | ||
) |
Sets the named property of the particle.
Sets the named property of this particle. The properties value (data) is supplied as a string and will be converted. If delta is set to true then the existing value of the property will be added to instead of replaced.
property_name | Name of the property as a string hash (faster searching). | |
[in] | data | The property data. |
delta | true to property should be added to instead of replaced. |
void CzActorParticle::Update | ( | float | dt | ) |
Updates this particle.
Updates ths particle, nicluding:
dt | The number of seconds since the app was last updated |
Active state.
CzXomlClassDef * CzActorParticle::ActorParticleClassDef = NULL [static, protected] |
float CzActorParticle::Angle |
Rotation of particle.
Rotation of particle.
Rotation of particle.
Attached particles will follow the particle actor.
Particle colour.
Particle colour velocity.
Particle colour velocity damping.
float CzActorParticle::Depth |
Depth of particle.
Depth velocity of particle.
Depth velocity damping of particle.
Gravitational acceleration.
Total duration of particle in seconds.
Current life time in seconds.
Number of lives for particle (how time it will be respawned)
float CzActorParticle::OAngle |
Original Rotation of particle.
Original Rotation veloxity of particle.
Original Particle colour.
Original Particle colour velocity.
float CzActorParticle::ODepth |
Original Depth of particle.
Original Depth velocity of particle.
Original Position relative to particle system actor.
Original Scale of particle.
Original Scale velocity of particle.
Original Velocity of particle.
Particles parent emitter.
Position relative to particle system actor.
Scale of particle.
Scale velocity of particle.
Scale velocity of particle.
Amount of time to wait before spawning in seconds.
Velocity of particle.
Velocity damping for particle.
Visible state.
Visual element that represents the particle.