Class: A_CreateExplosion

b5. A_CreateExplosion

b5.A_CreateExplosion

new b5.A_CreateExplosion(container, count, type, duration, speed, spin_speed, rate, damping, properties, actor){b5.A_CreateExplosion}

actions/generic/actors.js, line 35

Action that creates an explosion particle system actor then exits

Created actions should be added to an actor or scenes actions list to be processed

For a complete overview of Actions see Booty5 Actions Overview

Name Type Description
container string | b5.Scene | b5.Actor

Path to scene / actor or instance of scene / actor that will contain the generated particle actor

count number

Total number of particles to create

type object | string

The actor type of each particle created, for example Actor, ArcActor, LabelActor, PolygonActor etc

duration number

The total duration of the particle system in seconds

speed number

The speed at which the particles blow apart

spin_speed number

The speed at which particles spin

rate number

Rate at which particles are created

damping number

A factor to reduce velocity of particles each frame, values greater than 1 will increase velocities

properties object

Object that contains property / value pairs that will be set to particles when they are created (e.g. {"vx":0,"vy":0})

actor b5.Actor

If provided then the generated particle actor will be placed at the same position and orientation as this actor, actor can be an instance of an actor or a path to an actor

Returns:
Type Description
b5.A_CreateExplosion The created action