Godot Nature of Code  1.2.0
Nature of Code implemented in Godot Engine
Public Member Functions | Public Attributes | List of all members
Particles.SimpleParticleSystem Class Reference

Simple particle system. More...

Inheritance diagram for Particles.SimpleParticleSystem:
Forces.SimpleMover

Public Member Functions

delegate SimpleParticle ParticleCreationFunc ()
 Particle creation function definition More...
 
 SimpleParticleSystem ()
 Create a default particle system. More...
 
 SimpleParticleSystem (WrapModeEnum wrapMode)
 Create a default particle system with a custom wrap mode. More...
 
- Public Member Functions inherited from Forces.SimpleMover
 SimpleMover ()
 Create a simple wrapping mover with a circle mesh. More...
 
 SimpleMover (WrapModeEnum wrapMode)
 Create a simple mover with a custom wrap mode and a circle mesh. More...
 
virtual void ApplyForce (Vector2 force)
 Apply force on mover. More...
 
virtual void ApplyAngularForce (float force)
 Apply angular force on mover. More...
 
virtual void ApplyFriction (float coef)
 Apply friction on mover. More...
 
virtual void ApplyAngularFriction (float coef)
 Apply angular friction on mover. More...
 
virtual void ApplyDrag (float coef)
 Apply drag on mover. More...
 
virtual void ApplyDamping (float coef)
 Apply damping on mover. More...
 

Public Attributes

bool Emitting = true
 System is emitting More...
 
bool RemoveWhenEmptyParticles
 Remove system when particle list is empty More...
 
int ParticleCount = -1
 Particle count. Use -1 for "unlimited" particles More...
 
int ParticleSpawnFrameDelay = 4
 Particle spawn frame delay More...
 
int ParticleCountPerWave = 1
 Particle count per wave More...
 
bool LocalCoords = true
 Draw in local coords More...
 
Node ParticlesContainer
 Particles container. Use Parent by default.
 
ParticleCreationFunc ParticleCreationFunction
 Particles creation function More...
 
- Public Attributes inherited from Forces.SimpleMover
Vector2 Velocity = Vector2.Zero
 Current velocity More...
 
Vector2 Acceleration = Vector2.Zero
 Current acceleration More...
 
float AngularVelocity
 Current angular velocity More...
 
float AngularAcceleration
 Current angular acceleration More...
 
float MaxVelocity = 10
 Max velocity More...
 
float MaxAngularVelocity = 0.1f
 Max angular velocity More...
 
float Mass = 1
 Mass More...
 
WrapModeEnum WrapMode
 Wrapping mode More...
 
bool DisableForces
 Disable forces More...
 
bool SyncRotationOnVelocity
 Synchronize rotation on velocity More...
 
SimpleMesh Mesh
 Mesh More...
 

Additional Inherited Members

- Public Types inherited from Forces.SimpleMover
enum class  WrapModeEnum { Wrap , Bounce , None }
 Wrapping mode enum. More...
 
- Protected Member Functions inherited from Forces.SimpleMover
virtual void UpdateAcceleration ()
 Update acceleration value. More...
 
- Protected Attributes inherited from Forces.SimpleMover
CollisionShape2D collisionShape2D
 Collision shape More...
 
- Properties inherited from Forces.SimpleMover
bool Drawing [get, set]
 Draw mesh More...
 
Vector2 MeshSize [get, set]
 Mesh size More...
 
float Radius [get, set]
 Mesh radius More...
 

Detailed Description

Simple particle system.

Definition at line 10 of file SimpleParticleSystem.cs.

Constructor & Destructor Documentation

◆ SimpleParticleSystem() [1/2]

Particles.SimpleParticleSystem.SimpleParticleSystem ( )
inline

Create a default particle system.

Definition at line 45 of file SimpleParticleSystem.cs.

45 : this(WrapModeEnum.None) { }
WrapModeEnum
Wrapping mode enum.
Definition: SimpleMover.cs:15

◆ SimpleParticleSystem() [2/2]

Particles.SimpleParticleSystem.SimpleParticleSystem ( WrapModeEnum  wrapMode)
inline

Create a default particle system with a custom wrap mode.

Parameters
wrapModeWrap mode

Definition at line 51 of file SimpleParticleSystem.cs.

51  : base(wrapMode)
52  {
53  particles = new List<SimpleParticle>();
54  DisableForces = true;
55  Drawing = false;
56  }
bool DisableForces
Disable forces
Definition: SimpleMover.cs:51
Draw primitives.
Definition: DrawCanvas.cs:7

Member Function Documentation

◆ ParticleCreationFunc()

delegate SimpleParticle Particles.SimpleParticleSystem.ParticleCreationFunc ( )

Particle creation function definition

Member Data Documentation

◆ Emitting

bool Particles.SimpleParticleSystem.Emitting = true

System is emitting

Definition at line 16 of file SimpleParticleSystem.cs.

◆ LocalCoords

bool Particles.SimpleParticleSystem.LocalCoords = true

Draw in local coords

Definition at line 31 of file SimpleParticleSystem.cs.

◆ ParticleCount

int Particles.SimpleParticleSystem.ParticleCount = -1

Particle count. Use -1 for "unlimited" particles

Definition at line 22 of file SimpleParticleSystem.cs.

◆ ParticleCountPerWave

int Particles.SimpleParticleSystem.ParticleCountPerWave = 1

Particle count per wave

Definition at line 28 of file SimpleParticleSystem.cs.

◆ ParticleCreationFunction

ParticleCreationFunc Particles.SimpleParticleSystem.ParticleCreationFunction

Particles creation function

Definition at line 37 of file SimpleParticleSystem.cs.

◆ ParticleSpawnFrameDelay

int Particles.SimpleParticleSystem.ParticleSpawnFrameDelay = 4

Particle spawn frame delay

Definition at line 25 of file SimpleParticleSystem.cs.

◆ RemoveWhenEmptyParticles

bool Particles.SimpleParticleSystem.RemoveWhenEmptyParticles

Remove system when particle list is empty

Definition at line 19 of file SimpleParticleSystem.cs.


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