C# Class MBParticle, Pharos

THE Particle class. This is what it's all about!
Show file Open project: rstaewen/Pharos Class Usage Examples

Public Properties

Property Type Description
AbsVelocity Vector3
Acceleration float
AffectedByZones List
Age float
AgePercent float
AngularRotation float
Color Color
Force Vector3
Friction float
Heading Vector3
ImageFrameIndex int
Lifetime float
Mass float
Orientation float
Parent MBEmitter
Position Vector3
Rotation Vector3
Scale Vector3
UserData object[]
Velocity Vector3
mbColor Color

Public Methods

Method Description
Die ( ) : void

Let this particle die immediately

HasUserData ( int slotID ) : bool

Checks if a particle has a certain user data slot

HasUserDataValue ( int slotID ) : bool

Checks if a particle has a certain user data slot filled with data

MBParticle ( ) : System.Collections.Generic
Reset ( ) : void
ToObject ( ) : MBParticleObject

Create an Object-Proxy holding this particle

Method Details

Die() public method

Let this particle die immediately
public Die ( ) : void
return void

HasUserData() public method

Checks if a particle has a certain user data slot
public HasUserData ( int slotID ) : bool
slotID int the slot id obtained by MBEmitter.GetParticleUserDataID
return bool

HasUserDataValue() public method

Checks if a particle has a certain user data slot filled with data
public HasUserDataValue ( int slotID ) : bool
slotID int the slot id obtained by MBEmitter.GetParticleUserDataID
return bool

MBParticle() public method

public MBParticle ( ) : System.Collections.Generic
return System.Collections.Generic

Reset() public method

public Reset ( ) : void
return void

ToObject() public method

Create an Object-Proxy holding this particle
public ToObject ( ) : MBParticleObject
return MBParticleObject

Property Details

AbsVelocity public property

Unlike Velocity (which is set by the user), this is the total velocity taking forces, rotation etc.. into account. This will be set by the engine.
This is useful for parameters that rely on the actual speed/direction of a particle
public Vector3 AbsVelocity
return Vector3

Acceleration public property

Acceleration in direction of heading in Units per Second
public float Acceleration
return float

AffectedByZones public property

List of zones that this particle is inside
public List AffectedByZones
return List

Age public property

Age in seconds
This will be set by the emitter before any parameters are called
public float Age
return float

AgePercent public property

Age in percent (0..1)
This will be set by the emitter before any parameters are called
public float AgePercent
return float

AngularRotation public property

Internal field! Used by Orientation parameter
Used by Orientation parameter
public float AngularRotation
return float

Color public property

Current color
public Color Color
return Color

Force public property

Cumulated forces like Gravity, Forcefields etc...
public Vector3 Force
return Vector3

Friction public property

Friction is applied to the resulting force for dampening
public float Friction
return float

Heading public property

Normalized acceleration vector
public Vector3 Heading
return Vector3

ImageFrameIndex public property

The current MBEmitter.FramesUV index a.k.a. the shown texture frame
public int ImageFrameIndex
return int

Lifetime public property

Lifetime in seconds
public float Lifetime
return float

Mass public property

Mass
public float Mass
return float

Orientation public property

Image Orientation
public float Orientation
return float

Parent public property

Gets the emitter this particle belongs to
public MBEmitter Parent
return MBEmitter

Position public property

Position in ParticleSystem's space
public Vector3 Position
return Vector3

Rotation public property

Rotation around emitter transform
public Vector3 Rotation
return Vector3

Scale public property

Scale in world units
public Vector3 Scale
return Vector3

UserData public property

User data array
This array is used by parameters that need to store extra data. \sa \ref particleuserdata
public object[] UserData
return object[]

Velocity public property

Velocity in Units per Second
public Vector3 Velocity
return Vector3

mbColor public property

Internal Field! Color storage used for fades and animations
public Color mbColor
return Color