[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

    marinating

    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'




    Features
    • 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
    Download

    Changelog
    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

    marinating

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

    TheTennessee

    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

    marinating

    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

    TheTennessee

    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

    marinating

    Sounds plausible.
     
  7. Offline

    TheTennessee

    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

    maetthew

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

    AlexCory21

    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

    marinating

    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

    maetthew

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

    VERY VERY nice work :)
     
  12. Offline

    van_Grunz

    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

    BigTom91

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

    thank u for ur help ;)
     
  14. Offline

    marinating

    Permissions.
     
  15. Offline

    saenokda

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

    kalvinleung

  17. Offline

    Goldom_pants

    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

    Mercury

  19. Offline

    marinating

    @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

    SrJoben

    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

    marinating

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

    SrJoben

    Cool!

    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

    marinating

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

    SrJoben

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

    marinating

    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.
    @SrJoben

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

    Chaznuts

    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

    marinating

    Updated!
     
  28. Offline

    Chaznuts

    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

    marinating

    Fixed the bugs.
     
  30. Offline

    Chaznuts

    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

    marinating

    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