Inactive [FUN/EDIT/RPG] DungeonBuilder v0.9.7 - Player created dungeons [1.2.4-R1.0]

Discussion in 'Inactive/Unsupported Plugins' started by Zimp, Jun 23, 2011.

  1. Offline

    Zimp

    Grifhell and Kevinflu like this.
  2. Offline

    Zimp

    I can't help you with that since I have not spent much time working with javascript either. I misread one of your original posts and was under the impression you were trying to write a groovy script by editing my original one.
     
  3. Offline

    Zerockian

    Ok np, i'll try to learn Groovy then, though javascript is far more wide-spread so i'm a bit surprised you know Groovy instead of javascript :)
     
  4. Offline

    Zimp

    Groovy is actually not a far stretch from normal Java which is why I find it easier to get into. For the most part you can actually write straight java code inside groovy scripts and it will work.

    @Zerockian

    Here is your script translated to javascript:

    Code:
    importPackage(org.bukkit);
    importPackage(org.bukkit.entity);
    importPackage(org.bukkit.block);
    importPackage(org.bukkit.plugin);
    importPackage(org.bukkit.scheduler);
    importPackage(java.lang);
    
    function dungeon_start()
    {
    }
    
    function dungeon_exit()
    {
    }
    
    function torches()
    {
       loc = player.getLocation();
       scheduler = server.getScheduler();
    
       torchthread = Thread(function() {
    
            glowy = loc.getY() - 1;
            glowx = loc.getX();
    
            plugin2 = null;
            plugins = server.getPluginManager().getPlugins();
            for(i = 0; i < plugins.length; i++)
            {
                 if(plugins[i].getClass().toString().contains("DungeonBuilder"))
                     plugin2 = plugins[i];
            }
    
            if(plugin2 == null)
                    return;
    
            for(i = 0; i < 10; i++)
            {
                newloc = loc.clone();
                newloc.setY(glowy);
                newloc.setX(glowx - 2*i);
    
                b = newloc.getBlock();
    
                //SetBlock2 sb = new SetBlock2(b, Material.GLOWSTONE);
                temp = { run: function() {
                    b.setType(Material.GLOWSTONE);
                } }
                r = new Runnable(temp);
                scheduler.scheduleSyncDelayedTask(plugin2, r);
                Thread.currentThread().sleep(1000);
            }
        });
        torchthread.start();
    }
    
    
    As you can see it is considerably different than before and you have to use some unique conventions when dealing with threads. You will probably need to refer to http://www.mozilla.org/rhino/ScriptingJava.html for further documentation on how to write javascript on the JVM.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  5. Offline

    Zerockian

    Thanks for the effort but it ain't working: giving me errors about the thread, permissions and PluginClassManager. Anyway im off to learn some Groovy, thanks for your time :)
     
  6. Offline

    Zimp

    Version 0.8.5 posted and awaiting approval. Alternate download link: Here
    Highlights:
    • It is now possible to share dungeons with other players, allowing them to access it as if they were the owner.
    • It is now possible to limit how often players can run a specific dungeon
    • It is now possible to control the player's inventory when they enter and leave the dungeon
    • There is a new configuration variable to re-enable normal monster spawns inside dungeons
     
  7. Offline

    nicolos17

    Hello, i am french and i use your wonderfull plugin since some weeks.
    But i have a problem with the load of dungeons when a player start it.
    Indeed when a player start a dungeon, run a redstone circuit with a memory, if he die and another player start the dungeon, this redstone circuit is not reloaded.
    So i would like to know if you have a solution or if it is a little issue to solve.
    (I have the last version of the plugin)
     
  8. Offline

    Zimp

    @nicolos17

    Do other parts of the dungeon reload properly and its just the redstone you are having issues with?
     
  9. Offline

    nicolos17

    Yes, only with redstone memory when a player die. The player, when he die, is still considered in the dungeon ...
    So if an other player start the dungeon, the redstone memory will not be reset.

    But it is the only issue i have ^^

    So to solve this problem i have to do a dungeon into a dungeon, and like that cut my dungeon in some parts ?
     
  10. Offline

    Dyllon

    Is it possible to make the dungeons reload itself after someone completes it, or leaves it?
     
  11. Offline

    Zimp

    nicolos17

    Try the latest release to see if it fixes your redstone issues.

    Dyllon

    That is part of the default behavior of this plugin. When you create a dungeon you save a state of the contents which is then reloaded whenever the dungeon is finished.
     
  12. Offline

    Dyllon

    Oh, well are Blazes and/or fire bugged? I step on a diamond block and then finish the dungeon, then when i go back inside, the fire from the blazes are still there and spreading. But the items in the chests and stuff have reloaded. My dungeon is made out of wood btw.
     
  13. Offline

    Zimp

    Dyllon

    They may be bugged, can't say I've ever tried to save and reload a dungeon that's on fire...
     
  14. Offline

    Dyllon

    No no thats not what i meant. Okay i'll explain as clearly as i possible can lol. Okay so i made a dungeon, and i saved it. It wasn't on fire. I set blazes, zombies, and skeletons in this map. Then i played my dungeon, and then blazes set the dungeon on fire in an attempt to kill me. I reached the Diamond Block and then completed the dungeon, but then when i went back in, the map didn't reload back to it's original (unfirey) state. Only the CHESTS were reset.
     
  15. Offline

    Zimp

    Well the dungeon loads when you leave the dungeon. So I guess the situation may be that the dungeon is restored but since blazes are still in the vicinity they set it on fire again and when you go back into the dungeon it looks like it hasn't been restored.

    Does it load properly when you use the /loadDungeon command?
     
  16. Offline

    Dyllon

    Yeah it loads properly when i do that command. I noticed that its just the map that doesnt regenerate. Even from creepers, the hole from the explosion stays there until i use /loadDungeon
     
  17. Offline

    Zimp

    There should be no difference between /loadDungeon and what happens when the player steps on the exit block. Unless you turned off autoloading. Do you see this problem with every dungeon?
     
  18. Offline

    Dyllon

    Yeah i see this with every dungeon. Just tested (Sorry for the late reply)
     
  19. Offline

    Zimp

    Dyllon

    I've confirmed an issue where dungeons are not reloaded properly when no one is around. I suspect that the world/chunk deactivates when there isnt a player nearby in order to save resources.
     
  20. Offline

    Dyllon

    Thank you! I will go rebuild the dungeons to a more popular area. Hope you resolve the issue soon! ^^
     
  21. Offline

    QBcrusher

    is there anyway to make it stop when people get too close to the dungeon and it shoots u up in the air and says this area is restricted? ive had a few people die from that
     
  22. Offline

    Zimp

    QBcrusher

    The proximity check can be disabled globally through the configuration file (there is documentation for this on the bukkitdev page)

    You can also disable it on a per dungeon/player basis by making them a coowner for the dungeon (this will also give them full access to control the dungeon however).
     
  23. Offline

    Damien711

    This plugin looks really promising. I will be experimenting more with it in the next few days.
     
  24. Offline

    Zimp

    So BukkitDev came out and I deprecated this forum post in favor of that.

    Then dl.bukkit.org was released and the "Unleash the potential" link on it takes you to the "Bukkit Plugin List" which by default still displays these old forum posts.

    Which leads me to the real purpose of this post...












    Bump.
     
  25. Offline

    Zalashji

    Whenever I try to spawn mobs it says "Failed to spawn monsters - The EntityType not instance of LivingEntity.
     

Share This Page