Strange problem with unloading a world...

Discussion in 'Plugin Development' started by Pr07o7yp3, May 31, 2013.

Thread Status:
Not open for further replies.
  1. Offline


    Ok, I wrote Hunger Games plugin. It works but today I get very strange problem.
    My plugin before every game unload the HG world, copy it and load it again.

    The problem is that bukkit can't unload the world. I really don't know why.
    I tried to unload it manually with My Worlds but it said:
    Failed to unload the world (main world or online players?)

    Ok, I'm sure. There are no players there... There are no loaded chunks or entities.
    I checked with Essentials: /lag command return:
    World "HG": 0 chunks, 0 entities.

    But I can't still unload it... I'm really confused...

    Any idea why I can't unload the world?
  2. there may be conflicting plugins that cancel the world unload event
  3. Offline


    Ok, now I put this in my plugin
    @EventHandler(priority = EventPriority.HIGHEST)
        public void onWorldUnload(WorldUnloadEvent event) {
    if (event.getWorld().getName().equalsIgnoreCase(plugin.cfg.getString("hgWorld")))
    if (event.isCancelled())
    Will see if it will bug again.
  4. Offline


    If a plugin has put that world in a list or something it could prevent the world from getting unloaded.
Thread Status:
Not open for further replies.

Share This Page