Package org.bukkit

Examples of org.bukkit.Effect


      }
      if (killSection.getBoolean("reward.airstrike")) {
        this.airstrikePlayers.add(player.getName());
      }
      if (killSection.contains("reward.effect")) {
        Effect effect = Effect.valueOf(killSection.getString("reward.effect"));
        player.getWorld().playEffect(player.getLocation(), effect, null);
      }
    }
  }
View Full Code Here


    public void execute(ScriptEntry scriptEntry) throws CommandExecutionException {

        // Extract objects from ScriptEntry
        List<dLocation> locations = (List<dLocation>) scriptEntry.getObject("location");
        List<dPlayer> targets = (List<dPlayer>) scriptEntry.getObject("targets");
        Effect effect = (Effect) scriptEntry.getObject("effect");
        ParticleEffect particleEffect = (ParticleEffect) scriptEntry.getObject("particleeffect");
        Element iconcrack = scriptEntry.getElement("iconcrack");
        Element radius = scriptEntry.getElement("radius");
        Element data = scriptEntry.getElement("data");
        Element qty = scriptEntry.getElement("qty");
        Element offset = scriptEntry.getElement("offset");

        // Report to dB
        dB.report(scriptEntry, getName(), (effect != null ? aH.debugObj("effect", effect.name()) :
                particleEffect != null ? aH.debugObj("special effect", particleEffect.name()) :
                iconcrack.debug()) +
                aH.debugObj("locations", locations.toString()) +
                (targets != null ? aH.debugObj("targets", targets.toString()): "") +
                radius.debug() +
View Full Code Here

    @Override
    public boolean playEffect(Vector position, int type, int data) {
        World world = getWorld();

        final Effect effect = effects.get(type);
        if (effect == null) {
            return false;
        }

        world.playEffect(BukkitUtil.toLocation(world, position), effect, data);
View Full Code Here

TOP

Related Classes of org.bukkit.Effect

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.