Fireworks on ground

Discussion in 'Plugin Development' started by plarsootje, Feb 19, 2013.

Thread Status:
Not open for further replies.
  1. hi,
    My question is how can i let explode the fireworks on the ground my code at the moment just let a firework spawn so like you normaly let a firework spawn but how can i make that the firework doesn't spanw but explode at the ground?

    code at the moment
    Code:
            Location loc = p.getLocation();
            Firework firework = p.getWorld().spawn(loc, Firework.class);
            FireworkMeta data = (FireworkMeta) firework.getFireworkMeta();
            data.addEffects(FireworkEffect.builder().withColor(Color.GREEN).with(Type.BALL_LARGE).build());
            data.setPower(2);
            firework.setFireworkMeta(data);
            return;
     
  2. Offline

    chasechocolate

Thread Status:
Not open for further replies.

Share This Page