[ADMN/MECH] BlockRestrictions v0.8 - Control the use of TNT and bedrock [Permissions] [1.1-R4]

Discussion in 'Inactive/Unsupported Plugins' started by jeremytrains, Jul 10, 2011.

  1. Offline


    [ADMN/MECH] Block Restrictions [Permissions] [1060] - Restrict the use of bedrock and TNT:
    Version: v0.8

    We have now moved to BukkitDev! Vist us on BukkitDev HERE!I will NO LONGER be checking and updating this page! (But please do not delete it)

    Plugin Info (open)

    Latest version: v0.8​

    This plugin allows you to restrict users of placing bedrock and TNT, and blowing up TNT. When this occurs, it will display a message to the console and user, then cancels the
    placement of the item, then sends the user to jail. It also works with permissions!I hope you enjoy it! Please post comments. I am new to java but I will try to satisfy your requests.

    • Cancels bedrock placement
    • Cancels TNT placement and TNT explosions
    • Displays a message to player and console
    • in-game enable/disable without full plugin reload (/bron and /broff)
    • Permissions is OPTIONAL!
    • Unfortunately, we have NO groupmanager support. Don't ask for help with GM. We have tested and results show GM does NOT work with BR.
    • Has an API!
    Permission Nodes:

    'BlockRestrictions.canplace.tnt' - Give to players who CAN place tnt​
    'BlockRestrictions.canplace.bedrock' - Give to players who CAN place bedrock​
    'BlockRestrictions.admin' - Give to players who can use "/bron" and "/broff"​
    'BlockRestrictions.canexplode' - Give to players who can blow up tnt​

    • Link with Permissions (or op override for non-permission server) [v0.3]
    • Fix non-permission server errors
    • Use a config file to custom restrict items
    • Send message to the console
    • Log placements in a file
    • Stop TNT explosions
    • make a config file
    • make an API for turning off and on, and adding exceptions [In progress]
    Download BlockRestrictions
    Source Code
    For Plugin Developers, check out the API!


    Version 0.8
    • Added an API
    • Fixed the plugin saying 0,1,2,3,4 on startup (sorry, forgot to take out debugging)
    • Added an informal Javadoc (check out API and Javadoc HERE)
    • NOTICE: other than RB updates, nothing will be added to this plugin from now on unless you ASK FOR IT. I have no new ideas so if you want something, ask and I can make it for you. Also, i can fix problems and suggestions with the API
    • works with 1060
    Older Versions (open)

    Version 0.7.2
    • Fixed many, MANY errors with the dev v0.7.1 and v0.7
    • Fixed weird symbols in config file
    • fixed Jail errors
    • fixed problem loading file, ERROR ERROR ERROR
    • Added a new API code, not usable yet, a page will be displayed on how to use it soon.
    • Tried to add on Git Hub, but failed. I need help on this
    Version 0.7
    • Added a config file for better control over the plugin
    • Fixed a fatal error on startup caused by 0.6
    • NOTE: In the config file, there might be some wierd things like ".../:/=..." - please ignore
    • The above will be fixed in v0.7.1 coming on 8/1/11
    Version 0.6
    • Added Jail support
    • Added 'BlockRestrictions.canexplode'
    • Fixed glitch with permissions on exploding tnt
    • Fixed glitch with '/broff' NOT controlling tnt explosions, now it does
    Version 0.5
    • Changed BlockRestrictions.override to BlockRestrictions.canplace.tnt and BlockRestrictions.canplace.bedrock
    • Disabled tnt explosions, as well as tnt placing
    • Works with build #1000
    • Fixed "/bron" and "/broff" from the console errors
    Version 0.4.1
    • Added welcome message
    • Fixed "/broff" problems
    • Fixed 'BlockRestrictions.override'
    Version 0.4
    • Fixed errors with non-permission servers
    • (Planned block-tnt-explosions will be in v0.5, along with logging)

    Version 0.3
    • Added permission support (DO NOT update if you do not use permissions)
    • permissions is currently NEEDED, need to fix this to optional (currently fixing this)
    • You can download permissions HERE

    Version 0.2
    • Sends warning message to console
    • Added /bron and /broff for ops. This enables/disables BR
    • Sends message to player and not entire server
    Version 0.1
    • Initial Release

    This is where I am supposed to place a plugin to be submitted and posted on the bukkit plugin list right? Also, could people test this out and give me feedback please?

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


    Could people who download this plugin give me some feedback on how you think it works? I am trying to make it the best that it can be, but I haven't heard from anybody else who uses it! Also, could a moderator look at this and submit it to the "official plugin list"?
  3. Offline


    guys you need this on your server :) no tht if they dont have permission to use it :) no more NABS trying to crash your server :)

    ps its easy to use to.. god i misse easy install files.. :D

    sry for my profil, i just made it :)
  4. Offline


    tell me if you find any errors, I will try my best to fix them
  5. Offline


    the title is completely wrong, see plugin submission guidelines
  6. Offline


    Fixed the title, sorry about that.
  7. Offline


    Using 953

    I also gave gold members permission for this and it didnt work. Im using GroupManager.

  8. Offline



    It looks like you issued the "/broff" command from the console. Currently I havent set up the command for that console, just ingame. If you issued the command from the console, thats the problem, I haven't set that part up yet. Otherwise, let me know and I will look at it more in-depth. Thanks for the reply btw!


    Also, i'm not quite sure how groupmanager works, but I set this up for permissions, not GroupManager. If the plugin is recognizing a permissions plugin ("[INFO] [BlockRestrictions] Found and now using plugin GroupManager v*.*"), it should be fine. Otherwise (hopefully not) it might cause errors. If it does, I will try to link to GM too.

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


    I tried it in game too but had no hope(No console error tho). I really like the idea of the plugin, giving certain ranks TNT because many people dont know how to use it right.

    Also groupmanager should work the same as Permissions i think.
  10. Offline


    Ok, thx for the feedback. I will get to work on the problem ASAP. Not quite sure why, I can reproduce the problem on my own server too. Whenever the "/broff" command is used, it gives you the usage, but does nothing. I'm on it!


    I think I fixed it. Re-download. Not sure why that was a problem. All I did was flip-flop which command it checks for first ("/broff" before "/bron") and got it to work on my test server. Try it out and tell me if it works well! I will try to get console commands soon. Hopefully this one works!!!

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


    Thanks it works! Still having permission issues tho... i add "BlockRestrictions.override" to their list but it wont work yet admins who have '*' can use it.
  12. Offline


    Hmmmmmmm... Not quite sure why. I'm new to java and plugin developing, sorry about the errors. Does the BlockRestrictions.admin work? Also make sure that it says EXACTLY: BlockRestrictions.override. Sounds like spelling problem, either code or permissions. If the '*' works, permissions is working, but something with the .override is wierd. Re-download and see if 0.4.1 works, i tried to do the best I could to fix it. PS: don't capitalize override. Again, sorry about the issues.
  13. Offline


    Still having the problem.. BlockRestrictions.override is right the admin one works tho. Still not giving up tho, i really like this.
  14. Offline



    Hmmmm... Not sure. I'm trying to post this on GitHub. That way more experienced people can look at it. I will try literally copy and paste code from admin, then change it for *.override. Maybe I mistyped some code that I am missing. I will release a 0.4.2 when i try to fix it


    I think I fixed it, try re-downloading now


    I just ran a test on my server and the 'BlockRestrictions.override' worked just fine. If it works on my server, the code is fine, the issue is with your server. Just a few things that might let me help you. Re-download right now, see if it works, do you give the BlockRestrictions.override to a certain person, or group? Try a group and not a person. (Group of people who can use the BlockRestrictions.override. Do you have it EXACTLY "BlockRestrictions.override", CAPITALS MATTER! Otherwise, I can't really help you if you I don't have your server files right in front of me. I will try my best though!! PS: try updating to permissions, maybe that makes a difference in the way nodes work.

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


    Hm Still nothing...

    Its in a group. Heres the group

        default: false
        - BlockRestrictions.override
        - choptree.chop
        - DailyBonus.getVIP
        - essentials.delwarp
        - essentials.setwarp
        - falsebook.anyic
        - vip
          prefix: '&e'
          build: true
          suffix: '&f'
    Every other command works :v i really dont see how its working for you and not me.

    I might move to permissions the only reason i dont have it is because my old group.yml didnt work right with it but groupmanager fixed it up and ran it right.
  16. Offline



    Huh. Not quite sure why, everything looks correct. Could you give me a link to GroupManager? Maybe I need to link it with GroupManager AND Permissions to work for both. That is most likely the case. Scince linking with Jail isn't going so well, I will release a v0.5 that will hopefully fix your problems. Again, thanks for testing!

    PS: sorry, computer glitched up

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


    I switched to permissions and it works :)
  18. Offline


    Ok, good! I'm glad it works!!!! YAY, a solution!!!
  19. Offline

    MLG Darren :D

    Hey this doesn't work.. Well it works but if there is a lever which is on and you place tnt near it, it goes off. Please Fix that! really important.
  20. Offline


    Is It possible that i could toggle bedrock off and leave the tnt on becuase i want to let certain people place tnt and allow know-one to place bedrock... is this the plugin or is this my permissions and i just havnt learnt very well...?
  21. Offline


    so i place a tnt.. it reads,
    you may not placed the banned item: TNT!
    yet its there...
  22. Offline


    Luckily, I have a 17 hour break here. I will address a few problems now, and the rest after the 30th.

    @mlg Darren :) -- Currently, this plugin only blocks the PLACING of tnt, not explosions. I am still working on blocking explosions. Hopefully I can get this working soon

    @Kalvirox -- Very good idea!!! I like it! I didn't think of that while making the plugin. I will get to work on that ASAP! Meanwhile, sorry, not currently a way to do that

    @craztheking -- I don't understand what you are asking. It would help if you posted more details, or a snapshot/video would be great. From what I can tell you are asking, did you give them BlockRestrictions.override, do you have another plugin allowing the placement of tnt (would need a quick plugin list). Otherwise, please give me more detail on what you are asking me

    PS: testing on #1000 now

    The plugin SHOULD work on #1000, I don't quite have the time to test it, but I will test it on the 30th ASAP, if anyone tests it and proves it works on #1000, please post for the rest of us! Thanks!

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


    Hi, cb1000 seems to be working for me with placing TNT blocking at least.
    Also... is there a permission node for EXPLODING the TNT? I'm Op and I can't.

    If there isn't a permission for that can I suggest making one? I'm migrating from BlastControl because it hasn't been updated and that permission was really helpful. Regular members can place but only admins can explode etc.

    Also, TNT can't explode even when /broff has been used.
  24. Offline


    Thanks for testing, sorry, I had about 4 hours to make this so I forgot some stuff, two weeks of summer camp can be a little too much. I will make those adjustments right now. Thanks for testing!

    Go ahead and redownload 0.6, I added your new features and JAIL!

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


    Using Bukkit RB 1000 and BlockRestrictions 0.7(It says 0.5 but i think you didnt change it when you updated :v)
    19:10:59 [SEVERE] Error occurred while enabling BlockRestrictions v0.5 (Is it up
     to date?): Plugin attempted to register BLOCK_PLACE while not enabled
    org.bukkit.plugin.IllegalPluginAccessException: Plugin attempted to register BLO
    CK_PLACE while not enabled
            at org.bukkit.plugin.SimplePluginManager.registerEvent(SimplePluginManag
            at me.jeremytrains.BlockRestrictions.BlockRestrictions.onEnable(BlockRes
            at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:126)
            at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader
            at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManage
            at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:162)
            at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:146
            at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:284)
            at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:271)
            at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:148)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:335)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
  26. Offline


    Thanks for testing. Your right, i forgot to update the plugin.yml version #, still at v0.5, will change. The error shouldn't happen, but I will test anyway. This error means it tryed to see if someone placed a block while my plugin wasn't enabled. I will look into this. Testing now.

    Just fixed it. My assumtion above was wrong. That error was caused by multiple things:
    1)error in file caused it to disable the plugin (and not the listeners) - kept listening when plugin was off
    2)trying to access the jail plugin when it hadn't loaded the jail plugin yet
    3)I made this update in under an hour.
    Update to v0.7.2, it should work. I hope that you like the new config file! PS: 0.7.2 comes out in 5 mins

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


    I've run into a bad thing... People without the permissions to place/explode TNT can do this:

    1.) Put a redstone torch down.
    2.) Place a TNT.

    It does not disallow the TNT to be placed, I've tested it.
  28. Offline


    I see what your saying, but if you have the latest version, it should also block the explosion. You will see it primed, then a split second before it explodes, it dissapears. I will look into this on my test server and get back to you.
  29. Offline


    It wont find my Permissionsbukkit :7
  30. Offline


    @Maniox Permissionsbukkit? Is that a plugin or is it the permissions.yml in your server folder? For the permissions.yml in server folder you have to use PokemonGym.useCommand. Otherwise, I only support permissions/permissionsex

    @Mikeambrose Sorry its taking a while, havent had good access to internet, I will test on wednesday/thursday.

Share This Page