Example usage for com.badlogic.gdx.graphics.g2d ParticleEffect loadEmitterImages

List of usage examples for com.badlogic.gdx.graphics.g2d ParticleEffect loadEmitterImages

Introduction

In this page you can find the example usage for com.badlogic.gdx.graphics.g2d ParticleEffect loadEmitterImages.

Prototype

public void loadEmitterImages(FileHandle imagesDir) 

Source Link

Usage

From source file:de.gebatzens.meteva.PlayerSpaceship.java

License:Open Source License

public PlayerSpaceship(double x, double y) {
    super(GScout.getRegion("raumschiff"), x, y);

    width *= 0.7f;//w w w. j a v  a2s  .  com

    scaleToScreenSize();

    updateRect();

    rnormal = texture;
    reis = GScout.getRegion("raumschifffrost");
    firetex = GScout.getRegion("raumschiffglut");

    ParticleEffect bombEffect = new ParticleEffect();
    bombEffect.loadEmitters(Gdx.files.internal("particles/partikeltest"));
    bombEffect.loadEmitterImages(Gdx.files.internal("particles"));
    bombEffectPool = new ParticleEffectPool(bombEffect, 1, 2);
    PooledEffect effect = bombEffectPool.obtain();
    effects.add(effect);
    ScaledNumericValue value = effect.getEmitters().get(0).getScale();
    highMax = value.getHighMax();
    highMin = value.getHighMin();
    lowMax = value.getLowMax();
    lowMin = value.getLowMin();

    value = effect.getEmitters().get(0).getVelocity();
    vhighMax = value.getHighMax();
    vhighMin = value.getHighMin();
    vlowMax = value.getLowMax();
    vlowMin = value.getLowMin();

}