C# Class MBParticleSystem, Pharos

Inheritance: MBObject
Afficher le fichier Open project: rstaewen/Pharos Class Usage Examples

Méthodes publiques

Свойство Type Description
AutoPlay bool
Camera Camera
Duration float
Infinite bool
Invisible bool
ParticleBlocksize int
ParticleThreshold int
PauseAfterTimeWarp bool
Persistent bool
PersistentAtlas bool
SingleShot bool
TexturePadding int
TimeWarp float
TimeWarpStepSize float

Méthodes publiques

Méthode Description
AddAnchor ( ) : MBAnchor,

Creates a new empty anchor

AddAnchor ( MBAnchor, source, MBObject, parent ) : MBAnchor,

Creates a clone of an existing anchor and adds it as a child of source

AddAnchor ( MBObject, parent ) : MBAnchor,

Creates a new empty anchor as a child of parent

AddEmitter ( ) : MBEmitter

Creates a new empty child emitter

AddEmitter ( MBEmitter source, MBObject, parent ) : MBEmitter

Creates a clone of an existing emitter and adds it as a child of source

AddEmitter ( MBObject, parent ) : MBEmitter

Creates a new empty emitter as a child of parent

AddLayer ( Material mat ) : MBLayer,
Clear ( ) : void

Clears all particles

FindLayer ( Material forMaterial ) : MBLayer,

Return a layer with matching material or null

FindLayer ( string shaderName ) : MBLayer,

Return a layer with matching shader

GenerateTextureMap ( ) : void

Generate a texture atlas containing all textures our emitters need

GenerateTextureMap ( bool forceRebuild ) : void

Generate a texture atlas containing all textures our emitters need

GetTextureUV ( Texture2D texture ) : Rect

Gets the UV of the corresponding texture

Halt ( ) : void

Stops all emitters and destroys all particles immediately

LateUpdate ( ) : void
Pause ( ) : void

Freezes the particle system

Play ( ) : void

Starts playing

Play ( bool pauseAfterTimewarp ) : void

Starts playing

Purge ( ) : void
Reset ( ) : void
SetTextureAtlas ( string path ) : void

Set the filename that this particle system uses to write it's texture atlas

Start ( ) : void
Stop ( ) : void

Stops all emitters, but continues rendering until all particles died

Update ( ) : void
mbAddIdleParticles ( int count ) : void
mbBuildDictionary ( bool reload ) : void
mbCalculateRuntime ( ) : void
mbGetParticle ( ) : MBParticle,
mbIdleParticle ( IEnumerable particles ) : void
mbIdleParticle ( MBParticle, particle ) : void
mbLayerTextures ( MBLayer, lyr ) : List

Gets all textures used by an layer of this particlesystem

mbReloadHierarchy ( ) : void
mbRender ( ) : void
mbResetBuffers ( ) : void
mbUpdate ( ) : void
mbUpdateStep ( bool render ) : void

Méthodes protégées

Méthode Description
OnDisable ( ) : void
OnEnable ( ) : void

Method Details

AddAnchor() public méthode

Creates a new empty anchor
public AddAnchor ( ) : MBAnchor,
Résultat MBAnchor,

AddAnchor() public méthode

Creates a clone of an existing anchor and adds it as a child of source
public AddAnchor ( MBAnchor, source, MBObject, parent ) : MBAnchor,
source MBAnchor, the anchor to be cloned
parent MBObject, the new parent of the clone
Résultat MBAnchor,

AddAnchor() public méthode

Creates a new empty anchor as a child of parent
public AddAnchor ( MBObject, parent ) : MBAnchor,
parent MBObject, the parent of the new anchor
Résultat MBAnchor,

AddEmitter() public méthode

Creates a new empty child emitter
public AddEmitter ( ) : MBEmitter
Résultat MBEmitter

AddEmitter() public méthode

Creates a clone of an existing emitter and adds it as a child of source
public AddEmitter ( MBEmitter source, MBObject, parent ) : MBEmitter
source MBEmitter the emitter to be cloned
parent MBObject, the parent of the new emitter
Résultat MBEmitter

AddEmitter() public méthode

Creates a new empty emitter as a child of parent
public AddEmitter ( MBObject, parent ) : MBEmitter
parent MBObject, the parent of the new emitter
Résultat MBEmitter

AddLayer() public méthode

public AddLayer ( Material mat ) : MBLayer,
mat Material
Résultat MBLayer,

Clear() public méthode

Clears all particles
public Clear ( ) : void
Résultat void

FindLayer() public méthode

Return a layer with matching material or null
public FindLayer ( Material forMaterial ) : MBLayer,
forMaterial Material the Material the layer needs to use
Résultat MBLayer,

FindLayer() public méthode

Return a layer with matching shader
public FindLayer ( string shaderName ) : MBLayer,
shaderName string the shader the layer needs to use
Résultat MBLayer,

GenerateTextureMap() public méthode

Generate a texture atlas containing all textures our emitters need
public GenerateTextureMap ( ) : void
Résultat void

GenerateTextureMap() public méthode

Generate a texture atlas containing all textures our emitters need
public GenerateTextureMap ( bool forceRebuild ) : void
forceRebuild bool if set to false, atlas will only be built if a texture is missing
Résultat void

GetTextureUV() public méthode

Gets the UV of the corresponding texture
public GetTextureUV ( Texture2D texture ) : Rect
texture UnityEngine.Texture2D a Texture from MBImage
Résultat Rect

Halt() public méthode

Stops all emitters and destroys all particles immediately
public Halt ( ) : void
Résultat void

LateUpdate() public méthode

public LateUpdate ( ) : void
Résultat void

OnDisable() protected méthode

protected OnDisable ( ) : void
Résultat void

OnEnable() protected méthode

protected OnEnable ( ) : void
Résultat void

Pause() public méthode

Freezes the particle system
public Pause ( ) : void
Résultat void

Play() public méthode

Starts playing
public Play ( ) : void
Résultat void

Play() public méthode

Starts playing
public Play ( bool pauseAfterTimewarp ) : void
pauseAfterTimewarp bool true to play until Timewarp and then pause
Résultat void

Purge() public méthode

public Purge ( ) : void
Résultat void

Reset() public méthode

public Reset ( ) : void
Résultat void

SetTextureAtlas() public méthode

Set the filename that this particle system uses to write it's texture atlas
public SetTextureAtlas ( string path ) : void
path string path to a .png file, e.g. "assets/myparticlesys.png"
Résultat void

Start() public méthode

public Start ( ) : void
Résultat void

Stop() public méthode

Stops all emitters, but continues rendering until all particles died
public Stop ( ) : void
Résultat void

Update() public méthode

public Update ( ) : void
Résultat void

mbAddIdleParticles() public méthode

public mbAddIdleParticles ( int count ) : void
count int
Résultat void

mbBuildDictionary() public méthode

public mbBuildDictionary ( bool reload ) : void
reload bool
Résultat void

mbCalculateRuntime() public méthode

public mbCalculateRuntime ( ) : void
Résultat void

mbGetParticle() public méthode

public mbGetParticle ( ) : MBParticle,
Résultat MBParticle,

mbIdleParticle() public méthode

public mbIdleParticle ( IEnumerable particles ) : void
particles IEnumerable
Résultat void

mbIdleParticle() public méthode

public mbIdleParticle ( MBParticle, particle ) : void
particle MBParticle,
Résultat void

mbLayerTextures() public méthode

Gets all textures used by an layer of this particlesystem
public mbLayerTextures ( MBLayer, lyr ) : List
lyr MBLayer,
Résultat List

mbReloadHierarchy() public méthode

public mbReloadHierarchy ( ) : void
Résultat void

mbRender() public méthode

public mbRender ( ) : void
Résultat void

mbResetBuffers() public méthode

public mbResetBuffers ( ) : void
Résultat void

mbUpdate() public méthode

public mbUpdate ( ) : void
Résultat void

mbUpdateStep() public méthode

public mbUpdateStep ( bool render ) : void
render bool
Résultat void

Property Details

AutoPlay public_oe property

Whether this particle system will start playing automatically
public bool AutoPlay
Résultat bool

Camera public_oe property

The camera used by this ParticleSystem
public Camera Camera
Résultat Camera

Duration public_oe property

The duration in seconds one loop lasts
public float Duration
Résultat float

Infinite public_oe property

Whether this ParticleSystem has infinite duration
This is useful if you play single emitter instead of the whole ParticleSystem. \note Note that in Infinite mode AgePercent is always 0.5 while Age is undefined.
public bool Infinite
Résultat bool

Invisible public_oe property

Whether this particle system renders particles?
Unlike a muted system all emitters will be calculated and only the rendering will be suppressed.
public bool Invisible
Résultat bool

ParticleBlocksize public_oe property

How many Particles are created at once when the threshold exceeds
public int ParticleBlocksize
Résultat int

ParticleThreshold public_oe property

Initial particle treshold
public int ParticleThreshold
Résultat int

PauseAfterTimeWarp public_oe property

Pause ParticleSystem after time warping?
Useful to precalculate complex Particlesystems' timewarping. Call Play() again to continue playing
public bool PauseAfterTimeWarp
Résultat bool

Persistent public_oe property

Whether this particle system is persistent between scene changes
public bool Persistent
Résultat bool

PersistentAtlas public_oe property

Whether the texture atlas is persistent or generated at Start()
public bool PersistentAtlas
Résultat bool

SingleShot public_oe property

Whether this ParticleSystem runs once or repeats playing
public bool SingleShot
Résultat bool

TexturePadding public_oe property

Texture padding used when packing textures
If you see glitches around your particles, increase texture padding!
public int TexturePadding
Résultat int

TimeWarp public_oe property

Amount of time Advance the particle system should advance without rendering when starting to play
public float TimeWarp
Résultat float

TimeWarpStepSize public_oe property

Timestep used for TimeWarp.
Using a larger timestep is faster but may lead to incorrect results
public float TimeWarpStepSize
Résultat float