Gravity Engine 2 3.0
Loading...
Searching...
No Matches
GravityEngine2.DustBall Class Reference
Inheritance diagram for GravityEngine2.DustBall:
GravityEngine2.IGSParticlesInit

Public Member Functions

void InitNewParticles (int numLastActive, int numActive, GBUnits.GEScaler geScaler, ref NativeArray< double3 > r, ref NativeArray< double3 > v)
 Provide the initial positions and velocity for a range of particles. This method will be called as particles are created by the particle system. The implementing class must fill in the r[] and v[] arrays for the range specified. These arrays are indexed by [particle_num, dimension] where dimension 0,1,2 correspond to x,y,z.
 

Public Attributes

Vector3 position
 
float radius = 1f
 Radius of the ball of particles.
 
GBUnits.Units units = GBUnits.Units.DL
 
Vector3 velocity
 Velocity of each particle when it is initalized.
 

Member Function Documentation

◆ InitNewParticles()

void GravityEngine2.DustBall.InitNewParticles ( int fromParticle,
int toParticle,
GBUnits.GEScaler geScaler,
ref NativeArray< double3 > r,
ref NativeArray< double3 > v )

Provide the initial positions and velocity for a range of particles. This method will be called as particles are created by the particle system. The implementing class must fill in the r[] and v[] arrays for the range specified. These arrays are indexed by [particle_num, dimension] where dimension 0,1,2 correspond to x,y,z.

See the DustBox script for a sample usage of this interface.

Parameters
fromParticle
toParticle
scaleWorldToGE
r
v

Implements GravityEngine2.IGSParticlesInit.


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