[INACTIVE][[MECH] AutoTool v1.4 - Never dig through your inventory for tools again [1337]

Discussion in 'Inactive/Unsupported Plugins' started by marinating, Jun 9, 2011.

  1. Offline


    The plugin has been taken over by joshua katz.
    Grab his version on bukkitdev!

    AutoTool - The smart, convenient tool switcher.
    Version: v1.4

    AutoTool was developed when I became tired of constantly switching between shovels and pickaxes while mining. With this plugin, simply type /autotool or /at followed by on or off to toggle. A config file is provided that lets you specify which types of items you want to set to shovels, pickaxes, or axes- the file comes default with the basic items like ores, stones, logs, sand, and the like. If a player has AutoTool on and hits a log, for example, while holding a pickaxe in their hand, AutoTool will search their inventory for an axe. If it finds one, it immediately swaps the positions of the pickaxe and axe so the player can chop some wood without having to rearrange their items. This will hopefully be a huge headache-saver for some people, namely our Yogscast adventuring duo *cough cough*.
    Placing a blocks while in AutoTool mode will disable it, because strange duplication glitches may happen (until Bukkit comes up with a suitable replacement for player.updateInventory()).
    Plans for the future include AutoSword when damaged by a monster or other player, and AutoFood when your health runs low.
    Permissions node: 'auto.tool'

    • Config file lets you manually specify which items are assigned to what tools.
    • Never waste time searching your inventory for pickaxes, shovels, and axes!
    • Toggle on and off with simple commands- /at, /at on, /at off
    • Automatically pulls up the next tool in your inventory if the one you're using breaks

    Version 0.9
    • Release
    Version 1.0
    • Added permissions - 'auto.tool'
    Version 1.1
    • Bugfix for null pointer
    Version 1.2
    • Removed spam, made it smarter (placing blocks will not go trigger a tool switch, but left clicking will)
    • No longer switches out when you're holding a sword
    • Added SuperPerms support
    Version 1.3
    • Added more items to default pickaxe items
    • Added a config option that makes autotool on by default
    Version 1.4
    • Fixed all the bugs!
    Xerial, JonasD, maetthew and 2 others like this.
  2. Offline


    Maybe. I haven't taken a look at the auto tool code in quite a while.
  3. Offline


    Not sure I quite understand. I mean... it switches to a tool even if I am not using a tool. When a creeper comes up behind me and is about to go boom while I am mining, I don't exactly want to switch my sword out for a pickaxe just because I hit some stone with it in my frenzy to kill the creeper.

    That's all I am saying. If you mean there is something in the config, then my bad. I didn't see it in there to make it only switch on tools.
  4. Offline


    Well, it's designed to do that. I don't think adding combat detection is worth the trouble... I suppose you could do a really fast /at off to solve the issue. :D
  5. Offline


    Not combat detection. What I was suggesting is that you can set a setting (either chat or in config) that makes it so you -only- switch to a tool if you were already using a tool or your fist. That way, if you were using an axe and wanted to mine stone, then you would switch to a pickaxe, but while using a torch in your hand, you would stay on a torch, no matter what you hit. And of course, if you had nothing in your hand, it would switch too.
  6. Offline


    Sounds plausible.
  7. Offline


    Cool. I think it could add alot to the mod. I'd have it always turned on then without the fears.

    It's really awesome and simple for mining. I give it a thumbs up already.
  8. Offline


    Wow really cool plugin! Will it be updated to 953 (or does it work with it)?
  9. Offline


    This is cool and all, but you should add some more rules regarding what tool is selected.

    for example, when i go mining i usually carry alot of stone pickaxes, and maybe 1 iron and/or 1 diamond pickaxe. when i go to mine stone, your addon automatically switches me to my diamond pickaxe. I dont want to waste my diamond pickaxe on a bunch of stone, I want to use my stone pickaxes on stone.

    Would it be possible to select the lowest grade tool that can break the block? aka, select stone pickaxe for iron ore, stone, coal, etc. or select iron pickaxe for gold ore and redstone ore?


    Other than that this addon is awesome :)
  10. Offline


    Should work with 953. I'll update it to select your lowest durability item / weakest item sooner or later- my hands are full with other stuff (not all plugin related) at the moment.
  11. Offline


    I can confirm that it works well with RB 1000 after about 5 minutes of testing it out

    VERY VERY nice work :)
  12. Offline


    AutoTool is a great thing, but it mixes up my inventory. My suggestion is to select the tool by switching to the hotbar place if available in the hotbar instead of exchanging. For example, I always use sword in slot 1, axe in slot 3, shovel in slot 5 and pickaxe in slot 7. When trying to mine a tree with the shovel, AutoTool could switch automatically to the axe in slot 3. If you limit AutoTool to the hotbar (maybe via config file), the users can choose manually from their inventory which tool for what to use.

    Then, I added snow a criterium for the shovel, but it doesn't work. I checked the item id 78, SNOW. It is correct implemented in the config file. But attempting to mine snow doesn't change the tool.

    Please keep up the good work! Maybe you can add shears for leaves or even sheeps if possible ;)...
  13. Offline


    Where can i configure, that other players on my server can also put autotool on?

    thank u for ur help ;)
  14. Offline


  15. Offline


    is it possible to make this happen?
    and very nice plugin btw ^^
  16. Offline


  17. Offline


    I can't get this to properly select between basic tools. Every single time it switches to pickaxe, it goes for the diamond one. You wrote above that changing the inventory order will make it pick a different one, but no matter where I put the diamond - before the stone, after the stone, above, below, whatever - it still grabs that one.
  18. Offline


  19. Offline


    @Mercury It should, I don't think there have been any API changes that affect it.
    If it's broken please tell me.
  20. Offline


    Hi, this looks really useful I hope you're still supporting it. :)

    I'm trying to use this with Bukkit build 1337, and PermissionsBukkit 1.2k

    The mod seems to work but only for OPs. If normal players have the relevant node it doesn't work. When they enter the /at commands literally nothing happens. No message of any kind ingame or in the server console and their tools don't switch.
  21. Offline


    This is using Permissions 3- I'll add Superperms support in the near future.
  22. Offline



    I have a suggestion: A list of tools never to switch from. Most essential by default it should probably never switch you away from a sword. If i miss chicken I don't want it to switch to a shovel. It's the opposite of convient, which is ironic for this mod. Nevermind the death that could easily ensue when fighting hostile mobs.
  23. Offline


    Or you could turn it off if you want to kill chickens?
  24. Offline


    Or you could not make sarcastic comments when someone points out a serious problem with your mod.
  25. Offline


    Not sarcastic. What's wrong with typing /ac off when you don't want to use it?
    Anyways, I'll add superperms and make it not switch away from swords tonight.

    Updated as promised with Superperms, and swords should no longer switch away.

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


    The items I added to activate for a pickaxe aren't working.. might be easier if you just add them in the default? (I used all caps + underscores in between the multiple-word items and spaces in between complete items)

    The items include slabs (including wooden.. mines faster but doesn't chop faster), stairs (not including wooden for some reason), and stone brick recipes (regular, mossy, stairs, etc). Shouldn't be difficult for you to add, and since they are mined faster with a pickaxe, they should be on there anyways.

    Also, a nice and simple "config" file would be great to simply make "/at on" default

    Thanks for the great plugin!
  27. Offline


  28. Offline


    Thanks for the quick reply/update! I appreciate it, but now there's a problem. :p

    I believe you messed something up in the update or forgot to redirect something.. there is nothing in the AutoTool.txt file now (along with no autotool config file, if you added another file that is) and the plugin isn't working (obviously). I fully redownloaded the plugin, so I don't believe that it's just me. And by the way, at the top of your first post it still says V1.2.

    Also one more thing you might be able to add. If I remember correctly, the Auto Tool feature did not switch tools if you were punching the block instead of hitting it with some item. Would like to see that take a swapping effect as well.

    Thanks for your active management!
  29. Offline


    Fixed the bugs.
  30. Offline


    Awesome, Thanks.

    Works for everything but Stone Brick Blocks, Stone Brick Stairs, and Mossy Stone Brick Blocks.

    It's more than functional now, though. Just letting you know in case you wish to add those.
  31. Offline


    It works by blocking the Material type, so you have to type in the name correctly- WOOD_DOOR works but WOODEN_DOOR would not. Also, certain items, like different colors of wool and different types of halfstep cannot be individually specified.

Share This Page