Class Effect

Direct Known Subclasses:
ExplosionEffect, MultiEffect, ParticleEffect, RadialEffect, SeqEffect, WaveEffect, WrapEffect

public class Effect extends Object
  • Field Details

    • all

      public static final Seq<Effect> all
    • id

      public final int id
    • renderer

      public Cons<Effect.EffectContainer> renderer
    • lifetime

      public float lifetime
    • clip

      public float clip
      Clip size.
    • startDelay

      public float startDelay
      Time delay before the effect starts
    • baseRotation

      public float baseRotation
      Amount added to rotation
    • followParent

      public boolean followParent
      If true, parent unit is data are followed.
    • rotWithParent

      public boolean rotWithParent
      If this and followParent are true, the effect will offset and rotate with the parent's rotation.
    • layer

      public float layer
    • layerDuration

      public float layerDuration
  • Constructor Details

  • Method Details

    • startDelay

      public Effect startDelay(float d)
    • init

      public void init()
    • followParent

      public Effect followParent(boolean follow)
    • rotWithParent

      public Effect rotWithParent(boolean follow)
    • layer

      public Effect layer(float l)
    • baseRotation

      public Effect baseRotation(float d)
    • layer

      public Effect layer(float l, float duration)
    • wrap

      public WrapEffect wrap(Color color)
    • wrap

      public WrapEffect wrap(Color color, float rotation)
    • at

      public void at(Position pos)
    • at

      public void at(Position pos, boolean parentize)
    • at

      public void at(Position pos, float rotation)
    • at

      public void at(float x, float y)
    • at

      public void at(float x, float y, float rotation)
    • at

      public void at(float x, float y, float rotation, Color color)
    • at

      public void at(float x, float y, Color color)
    • at

      public void at(float x, float y, float rotation, Color color, Object data)
    • at

      public void at(float x, float y, float rotation, Object data)
    • shouldCreate

      public boolean shouldCreate()
    • create

      public void create(float x, float y, float rotation, Color color, Object data)
    • add

      protected void add(float x, float y, float rotation, Color color, Object data)
    • render

      public float render(int id, Color color, float life, float lifetime, float rotation, float x, float y, Object data)
    • render

      public void render(Effect.EffectContainer e)
    • get

      @Nullable public static Effect get(int id)
    • shake

      public static void shake(float intensity, float duration, float x, float y)
    • shake

      public static void shake(float intensity, float duration, Position loc)
    • floorDust

      public static void floorDust(float x, float y, float size)
    • floorDustAngle

      public static void floorDustAngle(Effect effect, float x, float y, float angle)
    • decal

      public static void decal(TextureRegion region, float x, float y, float rotation)
    • decal

      public static void decal(TextureRegion region, float x, float y, float rotation, float lifetime, Color color)
    • scorch

      public static void scorch(float x, float y, int size)
    • rubble

      public static void rubble(float x, float y, int blockSize)