Class SimpleParticleInfluenceFactory.BasicVortex

java.lang.Object
com.ardor3d.extension.effect.particle.ParticleInfluence
com.ardor3d.extension.effect.particle.SimpleParticleInfluenceFactory.BasicVortex
All Implemented Interfaces:
Savable
Enclosing class:
SimpleParticleInfluenceFactory

public static class SimpleParticleInfluenceFactory.BasicVortex extends ParticleInfluence
  • Field Details

  • Constructor Details

    • BasicVortex

      public BasicVortex()
    • BasicVortex

      public BasicVortex(double strength, double divergence, ReadOnlyLine3 axis, boolean random, boolean transformWithScene)
  • Method Details

    • getType

      public int getType()
    • setType

      public void setType(int type)
    • getStrength

      public double getStrength()
    • setStrength

      public void setStrength(double strength)
    • getDivergence

      public double getDivergence()
    • setDivergence

      public void setDivergence(double divergence)
    • getAxis

      public ReadOnlyLine3 getAxis()
    • setAxis

      public void setAxis(ReadOnlyLine3 axis)
    • getHeight

      public double getHeight()
    • setHeight

      public void setHeight(double height)
    • getRadius

      public double getRadius()
    • setRadius

      public void setRadius(double radius)
    • isRandom

      public boolean isRandom()
    • setRandom

      public void setRandom(boolean random)
    • isTransformWithScene

      public boolean isTransformWithScene()
    • setTransformWithScene

      public void setTransformWithScene(boolean transformWithScene)
    • prepare

      public void prepare(ParticleSystem system)
      Description copied from class: ParticleInfluence
      Gives the influence a chance to perform any necessary initialization immediately before ParticleInfluence.apply(double, com.ardor3d.extension.effect.particle.Particle, int) is called on each particle for the current frame.
      Overrides:
      prepare in class ParticleInfluence
      Parameters:
      system - the particle system containing the influence
    • apply

      public void apply(double dt, Particle p, int index)
      Description copied from class: ParticleInfluence
      Apply the influence defined by this class on a given particle. Should probably do this by making a call to particle.getSpeed().addLocal(....); etc.
      Specified by:
      apply in class ParticleInfluence
      Parameters:
      dt - amount of time since last apply call in ms.
      p - the particle to apply the influence to.
      index - the index of the particle we are working with. This is useful for adding small steady amounts of variation, or remembering information.
    • write

      public void write(OutputCapsule capsule) throws IOException
      Specified by:
      write in interface Savable
      Overrides:
      write in class ParticleInfluence
      Throws:
      IOException
    • read

      public void read(InputCapsule capsule) throws IOException
      Specified by:
      read in interface Savable
      Overrides:
      read in class ParticleInfluence
      Throws:
      IOException
    • getClassTag

      public Class<? extends SimpleParticleInfluenceFactory.BasicVortex> getClassTag()
      Specified by:
      getClassTag in interface Savable
      Overrides:
      getClassTag in class ParticleInfluence