Inactive [SEC/ADMN] OwnBlocksX v0.2.3 - Protect your blocks (MySQL, iConomy 5) [1000]

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

  1. Offline

    cvenomz

    OwnBlocksX - (OwnBlocks eXtended)
    Version: v0.2.3

    OwnBlocksX is a branch off the original OwnBlocks plugin. OwnBlocksX is intended to add support for many features which may not be suitable for the original plugin. Such features include MySQL support (completed), iConomy 5 support (completed), and group project support (in progress).

    See original plugin thread for more information

    Features:
    • Blocks you place cannot be broken by others
    • Ability to exclude certain blocks from being protected
    • Support for Permissions AND non-Permissions servers
    • Add (pre-placed) blocks to the database manually
    Notable Changes:

    -MySQL is now required
    -If you are migrating from OwnBlocks, you will need to convert your database unless you are starting fresh. Here is a helpful link
    -Permissions nodes are now OwnBlocksX.* (note the X)
    -toggle command is now /obx or /ownblocksx
    -New configuration file name and path
    -If you are upgrading from the test builds (OwnBlocksMySQL) then you need to rename your database table from OwnBlocks to OwnBlocksX.If you are using MySQL, the command is:
    "RENAME TABLE OwnBlocks TO OwnBlocksX"

    Download OwnBlocksX v0.2.3
    Source Code
    OwnBlocks is released under the WTFPL License.

    Other Notes:
    If you are having problems, you may need to have the MySQL JDBC driver installed

    Config File Options:
    Please note that at any time you may move/rename/delete you config file, and restart your server to produce the example/default config file with these options pre-filled along with descriptions. Also remember that lines preceded by a '#' are comments, and are ignored.

    host - enter the MySQL database host. 'localhost' unless you are running the database on a separate server
    databaseName - name of the MySQL database you will use on the MySQL server
    username - the MySQL user with which OwnBlocksX will authenticate with the MySQL database
    password - password for the MySQL user
    exclude - enter comma separated integers of block-ids you wish to exclude from being protected and entered into the database. An example would be to enter the block-id for saplings, so planted trees do not have a single log at the bottom that is protected when a tree is harvested by another player.
    iConomy - enter an integer greater than '0' (zero) to enable. The number entered becomes the 'Basic Rate' at which players are charged to place protected blocks. Players will not be able to place blocks if they have insufficient funds.
    debug - If you are experiencing errors, and want to post them here to resolve them, or just want to spam your server log with information, set debug equal to 'true'
    status-message - Set this to 'disable' to not receive the message "[Username] - OwnBlocks is now activated for you....". Set this to 'simple' to receive a simple "OwnBlocks activated/deactivated" instead. Lastly, set this to 'disable' to disable messages entirely. Now that I think of it, disabling status-messages seems like a really bad idea......but the choice is yours.
    info-id - Enter the integer representing the ID of the material or tool you would like to use as your "information tool" which will display the Owner of a block you right click with specified tool. Default is 269, which is the wooden shovel.
    add-id - Enter the integer representing the ID of the material or tool you would like to use as your "add tool" which will add the block you left click with the tool to the database. Default is 268, which is the wooden sword.
    enabled-on-login - True means that OwnBlocks is automatically activated for every player as soon as they log in. False means that OwnBlocks must be activated manually by each player when they want to start building protected blocks.

    Permissions Nodes:
    You will need to add these nodes to your Permissions configurations if your server uses Permissions:
    'OwnBlocksX.ignoreOwnership' - Allows player to break blocks placed by others. This node is typically given to admins.
    'OwnBlocksX.use' - Allows a player to even use OwnBlocks. If you want everyone to be able to protect blocks with OwnBlocks, and assuming you have a "normal" Permissions configuration, then add this node to your "default" class.
    'OwnBlocksX.info' - Allows a player to use the info-tool to display who owns a protected block.
    'OwnBlocksX.add' - Allows a player to use the add-tool to add blocks to the database for protection.

    Changelog:

    • Version 0.2.3 (8-7-2011)
      • Fixed another permissions bug (OwnBlocksX.ignoreOwnership) [Thanks MineJob!]
    • Version 0.2.2 (8-7-2011)
      • Fixed permissions bug (OwnBlocksX.use) [Thanks Worlther!]
    • Version 0.2.1 (8-3-2011)
      • Fixed bug where enable-on-login did not function
    • Version 0.2 (7-15-2011)
      • Implemented MySQL connection timeout workaround [Thanks ghost15!]
      • Moved tracking of enabled/disabled players to MySQL
    • Version 0.1.1 (7-11-2011)
      • Added message when player tries to break block not owned by them
    • Version 0.1 (7-10-2011)
      • Initial release
      • Added MySQL support
      • Added iConomy 5 support
     
    dark_hunter, Lunthus, Hacr and 3 others like this.
  2. Offline

    Yason

    Hey, what about adding some kind of admin option/command that would remove protection in xx radius ( filtered by player name ) ? Atm only way to get rid of grieefers spamming with protected blocks is just checking block after block. Other ways like regenerating terrain or even replacing those blocks with air and then back to anything else doesnt work, they ll be still protected.
     
  3. Offline

    kahlilnc

    Cannot wait until I get mysql set up I am instantly switching to this :D
     
  4. To get the OwnBlocksX.jar file you have to click on the 0.2 link below "ChangeLog" in the description, as the "download" link only leads to the source files, which I guess need to be compiled into a .jar but I'm not really a developer.
     
  5. Offline

    skech1080

    Same Problem! D:

    Me Too.

    Same
    Stooph.

    Yes, Please Help Us With Or Fix This Problem. (Me, Chains, Eiminam, & Emil Dosen.)

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

    Mathiasbk

    Can you make it work with World edit ?:)
     
  7. Offline

    alexg2k1

    Does this support CB 1000?
     
  8. Offline

    alfskan

    plugin abandoned?
     
  9. Offline

    yaitsbilly


    I hope not,But it looks that way.
     
  10. Offline

    Mercury

    It would be disaster.
     
    skech1080 likes this.
  11. Offline

    kahlilnc

    Does this work? If not I will stay with the original. . .
     
  12. Offline

    Aina

    It works but autoenable didn't work.
     
  13. Offline

    IIIEXOCETIII

    Not sure what has happened here as the Dev appears to have bailed. Currently i am having a huge issue with plugin as it is not being auto enabled upon logging in on the server. That being said if you do not remember to turn it on, nothing you have done is protected unless manually added. An update to this issue would be appreciated however i feel were a bit lost on this one.
     
  14. Offline

    cvenomz

    Nope, not abandoned :) I just went on a long trip, and had a period of time where my dev server was powered off :\

    Anyway, updated to v0.2.1 to fix the enabled-on-login issue.
     
  15. Offline

    hnrch02

    Can you please add multi-world support? That would be great! :D
     
  16. Offline

    IIIEXOCETIII

    Awesome so glad your back!! ;) Was getting tired of this banana protect. Doesn't work to well and still has a few bugs the dev needs to work out
     
  17. Offline

    smc

    enable-on-login did not function. 0.2.1
     
  18. Offline

    Lefty1211

    Hi, Im interested in using your plugin, but is there anyway i can port my Data from banana protect to Ownblocks?
     
  19. How can I disable the MYSQL Database
    I became this error:

    Code:
    2011-08-05 13:24:53 [SEVERE] [OwnBlocksX] Cant initialize MySQL
    2011-08-05 13:24:53 [SEVERE] com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
    
    The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.lang.reflect.Constructor.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.Util.handleNewInstance(Util.java:407)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1116)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:343)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2334)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2371)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2163)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:794)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47)
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.lang.reflect.Constructor.newInstance(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.Util.handleNewInstance(Util.java:407)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:378)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:305)
    2011-08-05 13:24:53 [SEVERE]     at java.sql.DriverManager.getConnection(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.sql.DriverManager.getConnection(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at me.cvenomz.OwnBlocks.MysqlDatabase.establishConnection(MysqlDatabase.java:39)
    2011-08-05 13:24:53 [SEVERE]     at me.cvenomz.OwnBlocks.OwnBlocks.yesMysqlEnable(OwnBlocks.java:107)
    2011-08-05 13:24:53 [SEVERE]     at me.cvenomz.OwnBlocks.OwnBlocks.onEnable(OwnBlocks.java:86)
    2011-08-05 13:24:53 [SEVERE]     at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:126)
    2011-08-05 13:24:53 [SEVERE]     at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:878)
    2011-08-05 13:24:53 [SEVERE]     at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:272)
    2011-08-05 13:24:53 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:162)
    2011-08-05 13:24:53 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:146)
    2011-08-05 13:24:53 [SEVERE]     at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:284)
    2011-08-05 13:24:53 [SEVERE]     at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:271)
    2011-08-05 13:24:53 [SEVERE]     at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:148)
    2011-08-05 13:24:53 [SEVERE]     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:335)
    2011-08-05 13:24:53 [SEVERE]     at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    2011-08-05 13:24:53 [SEVERE] Caused by: java.net.ConnectException: Connection refused: connect
    2011-08-05 13:24:53 [SEVERE]     at java.net.DualStackPlainSocketImpl.connect0(Native Method)
    2011-08-05 13:24:53 [SEVERE]     at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.PlainSocketImpl.connect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.SocksSocketImpl.connect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.Socket.connect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.Socket.connect(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.Socket.<init>(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at java.net.Socket.<init>(Unknown Source)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:254)
    2011-08-05 13:24:53 [SEVERE]     at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:292)
    2011-08-05 13:24:53 [SEVERE]     ... 27 more
    2011-08-05 13:24:53 [INFO] [OwnBlocksX] version 0.2.1 initialized with MySQL
    2011-08-05 13:24:53 [INFO] [OwnBlockX] hooked into iConomy.
    I have this plugins:

     
  20. Offline

    cvenomz

    Are you sure OwnBlocksX does not already support it?
    Can you please confirm your configuration file specifies enabled-on-login as true?
    Probably not easily. Unless the other dev has made a tool for it
    OwnBlocksX requires MySQL. See my original plugin, OwnBlocks, if you need similar functionality without the MySQL backend. This route is not recommended however
     
  21. Offline

    Worlther

    I'm added OwnBlocksX.use to permissions and players still cant use this. I have 0.2.1 version of OwnBlocksX and use PermissionsEx 1.1.3 for permissions. Someone know why?
     
  22. Offline

    cvenomz

    PermissionsEx isnt supported. Maybe try Permissions instead?
     
  23. Offline

    Worlther

    PermissionsEx must be supported if Permissions is supported.

    Code:
    public void addPlayer(String name)
        {
            if (hasPermission(name, "OwnBlocks.use"))
            {
                /*if (!activatedPlayers.contains(name))
                {
                    activatedPlayers.add(name);
                    if (configManager.getStatusMessage() == StatusMessage.ENABLE)
                        getServer().getPlayer(name).sendMessage(ChatColor.GREEN + name + ": OwnBlocks activated; Blocks you build will be protected");
                    else if (configManager.getStatusMessage() == StatusMessage.SIMPLE)
                        getServer().getPlayer(name).sendMessage(ChatColor.GREEN + "OwnBlocks activated");
    
                }*/
                if (!mysqlDatabase.hasPlayer(name))
                    mysqlDatabase.addPlayer(name);
                mysqlDatabase.setActivated(name, true);
    
                if (configManager.getStatusMessage() == StatusMessage.ENABLE)
                    getServer().getPlayer(name).sendMessage(ChatColor.GREEN + name + ": OwnBlocks activated; Blocks you build will be protected");
                else if (configManager.getStatusMessage() == StatusMessage.SIMPLE)
                    getServer().getPlayer(name).sendMessage(ChatColor.GREEN + "OwnBlocks activated");
            }
        }
    it's just wrong permission in source ;p
     
  24. Offline

    TomTom1997

    Can you add support for WorldEdit plugin (//set and //stack)?
     
  25. Offline

    cvenomz

    Thanks for that. No idea how that slipped through...
    I fixed the source, and Ill try to put up the new build later tonight
     
  26. Offline

    MineJob

    Would this lag my server? I'd love to still be able to use BigBrother. Also. I have 10 gb of ram and 120 slots.
     
  27. Offline

    cvenomz


    No. Last time I checked, there would really be no easy way of doing this. World Edit didnt seem to have a plugin API for its functions

    Probably not, now that OwnBlocksX uses MySQL.

    EDIT: Oh yeah, also updated to v0.2.2
     
  28. Offline

    yaitsbilly

    Yaa its back. thank you so much so many people on my server were asking for this.
     
  29. Offline

    MineJob

    Permission node for ignore ownership is also wrong. Its ownblocks.ignoreownership
    I tested it on my server
     
  30. Offline

    cvenomz

    Glad to hear it. Thanks
    bugs bugs bugs. Thanks for pointing this out. I think that is the last of those transition typos. I fixed it and updated to v0.2.3
     
    MineJob likes this.
  31. Offline

    MineJob

    This is a problem I ran into right away though so it kinda surprised me that you didn't notice it at first...
     

Share This Page