Package org.bukkit

Examples of org.bukkit.World


        return true;
      }
    }else{ //is console
      if(args.length == 4){
        int x,y,z;
        World world;
        try{
          x = Integer.parseInt(args[0]);
        }catch(NumberFormatException nfe){
          sender.sendMessage("invalid value for parameter \"x\"");
          return true;
View Full Code Here


  public void onBlockPlace(BlockPlaceEvent event) {
    config = DigSettings.getConfig();

    Block block = event.getBlock();
    Player player = event.getPlayer();
    World world = block.getWorld();

    trackBedMaterials = Arrays.asList(config.getString("trackbed").split(","));

    int mode = DigSettings.getTrackMode(player);
    boolean placeBlocks = (mode != Common.TRACK_MODE_NONE);
View Full Code Here

    config = DigSettings.getConfig();

    Block block = event.getBlock();
    Player player = event.getPlayer();
    World world = block.getWorld();

    breakable = Arrays.asList(config.getString("breakable").split(","));
    digTools = Arrays.asList(config.getString("digTools").split(","));
    dontDrop = Arrays.asList(config.getString("dontDrop").split(","));
View Full Code Here

        event.setFormat(format);
    }
   
    @EventHandler(priority=EventPriority.MONITOR)
    public void onWorldLoad(WorldLoadEvent event) {
        World world = event.getWorld();
        PluginManager pm = plugin.getServer().getPluginManager();
        if (pm.getPermission("jobs.world."+world.getName().toLowerCase()) == null)
            pm.addPermission(new Permission("jobs.world."+world.getName().toLowerCase(), PermissionDefault.TRUE));
    }
View Full Code Here

        ConfigurationSection areaSection = conf.getConfigurationSection("restrictedareas");
        if (areaSection != null) {
            for (String areaKey : areaSection.getKeys(false)) {
                String worldName = conf.getString("restrictedareas."+areaKey+".world");
                double multiplier = conf.getDouble("restrictedareas."+areaKey+".multiplier", 0.0);
                World world = Bukkit.getServer().getWorld(worldName);
                if (world == null)
                    continue;
                Location point1 = new Location(world,
                        conf.getDouble("restrictedareas."+areaKey+".point1.x", 0.0),
                        conf.getDouble("restrictedareas."+areaKey+".point1.y", 0.0),
View Full Code Here

    if (FaceUtil.isAlongX(dir)) {
      radX = 0;
    } else if (FaceUtil.isAlongZ(dir)) {
      radZ = 0;
    }
    World world = info.getWorld();
    Block m = info.getRails();
    Material type;
    Block w = null;
    for (int x = -radX; x <= radX && w == null; x++) {
      for (int y = -radY; y <= radY && w == null; y++) {
View Full Code Here

  /**
   * Updates the spawning state, called in the last few seconds before spawning<br>
   * Spawns the train itself
   */
  public void updateSpawn() {
    World world = this.getWorld();
    if (world == null) {
      this.start();
    } else if (this.getRemaining() == 0) {
      this.clearWorld();
      this.loadChunks(world);
View Full Code Here

    Location result = null;

    String[] split = loc.split(":");
    if (split.length == 4)
    {
      World world = Current.Plugin.getServer().getWorld(split[0]);
      result = new Location(world, Double.parseDouble(split[1]), Double.parseDouble(split[2]), Double.parseDouble(split[3]));
    }

    return result;
  }
View Full Code Here

    }
  }

  private void ProcessAlwaysDay(GameState gs)
  {
    World world = gs.getWorld();
    if (world.getTime() > 15000 || world.getTime() < 5000)
    {
      world.setTime(5000);
    }
  }
View Full Code Here

    }
  }

  private void ProcessAlwaysNight(GameState gs)
  {
    World world = gs.getWorld();
    if (world.getTime() > 22000 || world.getTime() < 18000)
    {
      world.setTime(18000);
    }
  }
View Full Code Here

TOP

Related Classes of org.bukkit.World

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.