public void add(State state) { switch (state) { case BURNING: burning = emitter(); burning.pour(FlameParticle.FACTORY, 0.06f); if (getVisible()) { Sample.INSTANCE.play(Assets.SND_BURNING); } break; case LEVITATING: levitation = emitter(); levitation.pour(Speck.factory(Speck.JET), 0.02f); break; case INVISIBLE: PotionOfInvisibility.melt(ch); break; case PARALYSED: paused = true; break; case FROZEN: iceBlock = IceBlock.freeze(this); paused = true; break; case ILLUMINATED: GameScene.effect(halo = new TorchHalo(this)); break; } }