ParticleSystem
Used to create cool effects, like fire. The particle systems are created and drawn on the screen using functions in love.graphics. They also need to be updated in the update(dt) callback for you to see any changes in the particles emitted.
Constructors
love.graphics.newParticleSystem | Creates a new ParticleSystem. |
Functions
Object:type | Gets the type of the object as a string. |
Object:typeOf | Checks whether an object is of a certain type. |
ParticleSystem:count | Gets the amount of particles that are currently in the system. |
ParticleSystem:getDirection | Gets the direction of the particle emitter (in radians). |
ParticleSystem:getEmissionRate | Gets the amount of particles emitted per second. |
ParticleSystem:getOffsetX | Get the x coordinate of the particle rotation offset. |
ParticleSystem:getOffsetY | Get the y coordinate of the particle rotation offset. |
ParticleSystem:getPosition | Gets the position of the emitter. |
ParticleSystem:getSpread | Gets the amount of directional spread of the particle emitter (in radians). |
ParticleSystem:getX | Gets the x-coordinate of the particle emitter's position. |
ParticleSystem:getY | Gets the y-coordinate of the particle emitter's position. |
ParticleSystem:isActive | Checks whether the particle system is actively emitting particles. |
ParticleSystem:isEmpty | Checks whether the particle system is empty of particles. |
ParticleSystem:isFull | Checks whether the particle system is full of particles. |
ParticleSystem:pause | Pauses the particle emitter. |
ParticleSystem:reset | Resets the particle emitter, removing existing particles and resetting the lifetime counter. |
ParticleSystem:setBufferSize | Sets the size of the buffer (the max allowed amount of particles in the system). |
ParticleSystem:setColor | Sets the color of the image. |
ParticleSystem:setDirection | Sets the direction the particles will be emitted in. |
ParticleSystem:setEmissionRate | Sets the amount of particles emitted per second. |
ParticleSystem:setGravity | Sets the gravity affecting the particles (acceleration along the y-axis). |
ParticleSystem:setLifetime | Sets how long the particle system should emit particles (if -1 then it emits particles forever). |
ParticleSystem:setOffset | Set the offset position which the particle sprite is rotated around. |
ParticleSystem:setParticleLife | Sets the life of the particles. |
ParticleSystem:setPosition | Sets the position of the emitter. |
ParticleSystem:setRadialAcceleration | Set the radial acceleration (away from the emitter). |
ParticleSystem:setRotation | Sets the rotation of the image upon particle creation (in radians). |
ParticleSystem:setSize | Sets the size of the particle (1.0 being normal size). |
ParticleSystem:setSizeVariation | Sets the amount of size variation. |
ParticleSystem:setSpeed | Sets the speed of the particles. |
ParticleSystem:setSpin | Sets the spin of the sprite. |
ParticleSystem:setSpinVariation | Sets the amount of spin variation. |
ParticleSystem:setSpread | Sets the amount of spread for the system. |
ParticleSystem:setSprite | Sets the image which is to be emitted. |
ParticleSystem:setTangentialAcceleration | Sets the tangential acceleration (acceleration perpendicular to the particle's direction). |
ParticleSystem:start | Starts the particle emitter. |
ParticleSystem:stop | Stops the particle emitter, resetting the lifetime counter. |
ParticleSystem:update | Updates the particle system; moving, creating and killing particles. |
Supertypes
See Also
Other Languages
Dansk –
Deutsch –
English –
Español –
Français –
Indonesia –
Italiano –
Lietuviškai –
Magyar –
Nederlands –
Polski –
Português –
Română –
Slovenský –
Suomi –
Svenska –
Türkçe –
Česky –
Ελληνικά –
Български –
Русский –
Српски –
Українська –
עברית –
ไทย –
日本語 –
正體中文 –
简体中文 –
Tiếng Việt –
한국어
More info