Thrive
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
thrive::TimedCompoundEmitterComponent Class Reference

Component for automatic timed compound emissions. More...

#include <compound_emitter_system.h>

Inheritance diagram for thrive::TimedCompoundEmitterComponent:
thrive::Component

Public Member Functions

void load (const StorageContainer &storage) override
 Loads the component. More...
 
StorageContainer storage () const override
 Serializes the component. More...
 
- Public Member Functions inherited from thrive::Component
virtual ~Component ()=0
 Destructor.
 
bool isVolatile () const
 A volatile component is not serialized during a save. More...
 
EntityId owner () const
 The entity this component belongs to. More...
 
void setVolatile (bool isVolatile)
 Sets the volatile flag. More...
 
void setOwner (EntityId owner)
 Sets the component's owner. More...
 
virtual ComponentTypeId typeId () const =0
 The component's type id.
 
virtual std::string typeName () const =0
 The component's type name.
 

Static Public Member Functions

static luabind::scope luaBindings ()
 Lua bindings. More...
 
- Static Public Member Functions inherited from thrive::Component
static luabind::scope luaBindings ()
 Lua bindings. More...
 

Public Attributes

CompoundId m_compoundId
 The compound id to emit.
 
uint16_t m_particlesPerEmission = 0
 The number of particles created per emission interval.
 
float m_potencyPerParticle = 1.0f
 The potency new particles will receive.
 
Milliseconds m_emitInterval = 1000
 How often new particles are spawned.
 
Milliseconds m_timeSinceLastEmission = 0
 For use by TimedCompoundEmitterSystem.
 

Detailed Description

Component for automatic timed compound emissions.

Member Function Documentation

void TimedCompoundEmitterComponent::load ( const StorageContainer &  storage)
overridevirtual

Loads the component.

Parameters
storage

Implements thrive::Component.

luabind::scope TimedCompoundEmitterComponent::luaBindings ( )
static

Lua bindings.

Exposes:

  • CompoundEmitterComponent()
  • CompoundEmitterComponent::m_compoundId
  • CompoundEmitterComponent::m_particlesPerEmission
  • CompoundEmitterComponent::m_potencyPerParticle
  • CompoundEmitterComponent::m_emitInterval
Returns
StorageContainer TimedCompoundEmitterComponent::storage ( ) const
overridevirtual

Serializes the component.

Returns

Implements thrive::Component.


The documentation for this class was generated from the following files: