Class ParticleGraphicsAdapterImpl
Inheritance
object
ParticleGraphicsAdapterImpl
Assembly: .dll
Syntax
public class ParticleGraphicsAdapterImpl : IParticleGraphicsAdapter
Constructors
|
Edit this page
View Source
ParticleGraphicsAdapterImpl(IParticleState, RendererParticles)
Declaration
public ParticleGraphicsAdapterImpl(IParticleState particle, RendererParticles renderer)
Parameters
Fields
|
Edit this page
View Source
defColor
Declaration
private static Color defColor
Field Value
|
Edit this page
View Source
graphics_color
Declaration
public Color graphics_color
Field Value
|
Edit this page
View Source
graphics_colorRenderer
Declaration
public RendererParticles_RenderBatch graphics_colorRenderer
Field Value
|
Edit this page
View Source
graphics_globalID
Declaration
public int graphics_globalID
Field Value
|
Edit this page
View Source
graphics_isRegistered
Declaration
public bool graphics_isRegistered
Field Value
|
Edit this page
View Source
graphics_listID
Declaration
public int graphics_listID
Field Value
|
Edit this page
View Source
graphics_listNumber
Declaration
public int graphics_listNumber
Field Value
|
Edit this page
View Source
particle
Declaration
public IParticleState particle
Field Value
|
Edit this page
View Source
renderer
Declaration
private RendererParticles renderer
Field Value
|
Edit this page
View Source
state_cur
Declaration
public ParticleGraphicsAdapterImpl.PositionSnap state_cur
Field Value
|
Edit this page
View Source
state_prev
Declaration
public ParticleGraphicsAdapterImpl.PositionSnap state_prev
Field Value
Methods
|
Edit this page
View Source
AddParticle(ParticleMovementState)
Adds the particle to the renderer. Only needs to be called once to register a particle.
Declaration
public void AddParticle(ParticleMovementState movementState)
Parameters
Type |
Name |
Description |
ParticleMovementState |
movementState |
The current movement state of the new particle.
|
|
Edit this page
View Source
BondUpdate(ParticleBondGraphicState)
Declaration
public void BondUpdate(ParticleBondGraphicState bondState)
Parameters
|
Edit this page
View Source
CircuitUpdate(ParticlePinGraphicState)
Pushes an update for the pin configuration of the particle and
the immediate connections to neighboring particles.
Declaration
public void CircuitUpdate(ParticlePinGraphicState state)
Parameters
Type |
Name |
Description |
ParticlePinGraphicState |
state |
Data about the current state of the
particle's pin configuration and neighbor connections.
|
|
Edit this page
View Source
ClearParticleColor()
Call this when you want to remove the particle color.
It goes back to default afterwards. This only needs to
be called when the color which has been set manually
should be removed.
Declaration
public void ClearParticleColor()
|
Edit this page
View Source
HideParticle()
Complements ShowParticle(). Hides the particle.
Call this if you want to hide the particle.
Declaration
public void HideParticle()
|
Edit this page
View Source
RemoveParticle()
Removes a particle from the renderer. Only needs to be called once
when the particle is removed from the system.
Declaration
public void RemoveParticle()
|
Edit this page
View Source
SetParticleColor(Color)
Call this when you want to update the particle color.
This only needs to be called when the color which has
automatically been set when the particle was added to the
rendering system should be changed in some way.
Declaration
public void SetParticleColor(Color color)
Parameters
Type |
Name |
Description |
Color |
color |
The new color of the particle.
|
|
Edit this page
View Source
ShowParticle()
Complements HideParticle(). Shows the particle.
Calling this method is not necessary if the particle is never
hidden. By default the particle is visible once it is added
and updated.
Declaration
public void ShowParticle()
|
Edit this page
View Source
Update(ParticleMovementState)
Updates the particle graphics. This is applied and
shown directly in the next render cycle. Call it once
per round, even if the particle has not moved.
Example: A particle has expanded. Call
Update(ParticleMovementState) to update the visuals.
Declaration
public void Update(ParticleMovementState movementState)
Parameters
|
Edit this page
View Source
Update(bool, ParticleJointMovementState, bool)
Declaration
private void Update(bool forceRenderUpdate, ParticleJointMovementState jointMovementState, bool noAnimation)
Parameters
|
Edit this page
View Source
Update(bool, ParticleMovementState, bool)
Declaration
private void Update(bool forceRenderUpdate, ParticleMovementState movementState, bool noAnimation)
Parameters
|
Edit this page
View Source
UpdateReset()
Like Update(ParticleMovementState), but forces
the update to be applied visually without an animation, even
if the particle positions are the same as in the previous frame.
Declaration
public void UpdateReset()
|
Edit this page
View Source
UpdateReset(ParticleMovementState)
Like Update(ParticleMovementState), but forces
the update to be applied visually without an animation, even
if the particle positions are the same as in the previous frame.
Declaration
public void UpdateReset(ParticleMovementState movementState)
Parameters
Implements