[MECH] PumpkinDiver [v0.16] [400-1240]

Discussion in 'Inactive/Unsupported Plugins' started by Afforess, Feb 3, 2011.

  1. Offline


    Pumpkin Diver
    • Wearing a pumpkin helmet extends the time allowed under water by 10x the normal length.
    • Chat prompt alerting users of air remaining at each 10% when wearing pumpkin helmet.
    • No Commands
    • No Configuration
    • No Permissions
    • No Hassle
    Known Issues:
    • Bubble GUI does not update correctly unless you use the Spoutcraft mod.
    Download Here
    Source Code

    • Version 0.10
      • Initial Release
    • Version 0.11
      • Fixed issues with air remaining chat prompt not firing 100% of the time
      • Improved efficiency by ~ 350%
    • Version 0.12
      • Fixed a rare null pointer exception when a player teleports in-between worlds.
    • Version 0.13
      • Conformed to meet Bukkit code naming standards
    • Version 0.14
      • Conformed to meet Bukkit code standards
      • Plugin Properly shuts down when disabled.
    • Version 0.15
      • Bug Fixes
    • Version 0.16
      • Minor enhancements/fixes
    Guide to Adding a Custom Pumpkin Helmet Texture to your client
    (Easy to do and totally safe!)
    • Find the pumpkinblur.png you want to use. I recommend this one by Glimmar.
    • Download it onto your desktop or some place you can remember.
    • Find your minecraft folder (in Windows it's C:\Users\YOUR_USERNAME\AppData\Roaming\.minecraft\bin).
    • Open the minecraft.jar with winrar or 7z.
    • Navigate to the misc folder.
    • Drag the pumpkinblur.png you downloaded earlier over the existing one in the misc folder. Accept the prompt that asks you to overwrite it.
    • Close winrar or 7z.
    • Launch Minecraft, go to a server, and put on a pumpkin to see your custom helmet!
    Changed your mind, and want to go back to the old one? Go back the the minecraft folder and delete the "version" file. This will force minecraft to update when you launch it next time, and revert to the default textures.
  2. Offline


    Using your source, I created a clone of your plugin but it checks for a diamond helmet instead of a pumpkinhead. Unobscured SCUBA, yay!! Good work, Afforess. Your plugin source is also helping to teach me how plugin code structures work. ^_^
  3. Offline


    More importantly, this plugin uses multi-threading, so it's an interesting study on how to do that as well.
    weasel5i2 and chibirubara like this.
  4. Offline


    What does the multi-threading do differently that you couldn't do without it?
  5. Offline


    Didn't know this used multicore, pretty interesting looking through the source
  6. Offline


    Well - nothing special, except that most plugins use the main server CPU, which can get maxed out during heavy loads. But in this case, this plugin would use mostly a secondary core that was (hopefully) underutilized. If it's a 1 core system, then it runs only on the 1 core, of course.
    --- merged: Feb 11, 2011 5:12 AM ---
    The source could definitely be cleaner, FYI, but I didn't feel like spending that much effort for such a small project.

    The new thread's are created at "new Thread() ..." (go figure).
  7. Offline


    Would it be possible to have the pumpkin take time to recharge air on surfacing?
  8. Offline


    That would be neat, but Minecraft auto-fills your air for you, and there's no way to stop it from happening.
  9. Offline


    Minecraft auto fills your first chunk of air but couldn't you make it take time before the full 10x the air is restored?
  10. Offline


    Minecraft auto-fills your entire air supply, regardless of the amount.
  11. Offline


    - I LIKE ;)
    saw Notch saying on his blog saying more underwater "stuff" will come ;)

    So this helmet will indeed come handy..
    now i just need some sort of lighting,, thinking (havent testet yet) pumping lanterns work under water ?

    Imagines a underwater castle ;D

  12. Offline



    I'm a new bukkit user and just became a forum member to say a big thank you for making this. Tried and tested and works beautifully. It's nice to be able to start work on my Nautilus dock again...the hard way...squids and all! I love the fact that there is a limited amount of oxygen, as it keeps me on my toes, but is there any intention to improve the rate at which we can mine with a shovel or pick, even though I like it's current realism? Also, how possible would an underwater breathing sound effect be?

    Yes, Notch's announcement of more underwater 'stuff' has got me intrigued.

    Pumpkin lanterns do indeed work very well underwater. Take a few down there and place them around...they reposition very easily without wastage too.

    This mod is the single best reason for pumpkins in my opinion.

    By the way, my pumpkinblur.png file was designed to be intentionally restrictive, as I always thought this added to the restrictive, claustrophobic atmosphere and the trade off for the ability to be underwater, but probably not good when there are more 'nasty' underwater mobs about! This gives me the motivation to continue work on the pumpkinblur graphic again.

    Many thanks, mate.
  13. Offline


    Hey havent tested this but i saw a player.setRemainingAir() method could that not be used to control the depletion and refilling of the player air supply? havent looked at you code yet but will soon
  14. Offline


    Yes - but I believe it automatically resets when you are out of water.
    --- merged: Feb 16, 2011 6:07 AM ---
    Updated to v0.13! Urgent update to conform to Bukkit's code naming standard. Failing to update will cause this plugin not to load with bukkit in future builds!
  15. Offline


    this is really useful thanks for yet another great plugin. keep up the good work!
  16. Offline


    Kind of an odd bug. All of my users on the server can use this with no issue, except for me. It will not work at all. It did at one point, but no longer. I refuse to use the overly complicated permissions plugin, so I have no idea if that's an issue, but I am the OP of the server. Any thoughts?
  17. Offline


    This plugin is multi-threaded, and so there is the extremely unlikely chance (< 0.001% ) that the thread for your player died unexpectedly. Stopping and restarting the server should fix it immediately if that is the problem.
  18. Offline


    I tried that, and it didn't exactly fix it. However, uninstalling and then re-installing the plugin made it work again. Like I said, really odd bug. I just wish that I wasn't in the beginning stages of coding so I could really look at what was going on and give you an idea of what went wrong.
  19. Offline


    I give up, how do you USE this? Can't wear the pumpkin on your head, can't make a helmet out of pumpkins...
  20. Offline


    You can wear a pumpkin on your head lol, there's a difference between pumpkin and jack o lantern.
  21. Offline


    Just a warning from the latest craftbukkit.

    2011-02-20 12:25:07 [WARNING] Using the stupidly long constructor com.afforess.pumpkindiver.PumpkinDiver(PluginLoader, Server, PluginDescriptionFile, File, File, ClassLoader) is no longer recommended. Go nag the plugin author of Pumpkin Diver to remove it! (Nothing is broken, we just like to keep code clean.)
    2011-02-20 12:25:07 [INFO] Hint! It's probably someone called 'Afforess'
  22. Offline


    I'm already aware. Stupid message.
  23. Offline


    Afforess, your one of the best plugin developers! You respond to questions, without having an air of importance.
    --- merged: Feb 20, 2011 10:41 PM ---
    Stupidly long? You didn't edit this at all? Laughing out loud commenced!
  24. Offline


    Well... I can't. Plugin is loaded, according to the log. This isn't a new problem either - have had it since before CB 300, never got enough pumpkins to attempt to make a helmet after we discovered we couldn't wear it on head.

    OH! Discovered you have to remove the helmet you're wearing. Nevermind.
  25. Offline


    Thanks, I think. ;)

    Plugin updated to v0.14. No longer complains in the console, and shuts down properly. (Before, disabling the plugin actually had no effect <.<)
  26. Offline


    This ought to be fun :D
  27. Offline


    I have CB323 with 0.14. is it possible that it doesnt load at serverstartup in serverconsole cause bukkit is too old? or you removed the "2011-02-21 09:32:57 [INFO] Pumpkin Diver version 0.12 is enabled!" message?
  28. Offline


    If the enabled message does not appear, your build is too old.
  29. Offline


    Anybody saw taht bug that pumpkin, when it is on your head, is vice versa?
  30. Offline


    Thank you Mr Wizard man! I was talking to a couple of friends who play with me and it was decided that breath is too short. When I told them about this it was decided unanimously that it was a fantastic idea.
  31. Offline


    Any chance you could add a permissions option if it detects permissions or groupmanager as installed on the server? I want to let users buy this ability with iConomy money and that would require setting custom permissions.

Share This Page