Inactive [MECH] Backpack v2.2.0 (The Ultimate Inventory Expander!) [953]

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

     
  1. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Backpack
    Because One is never enough!

    Preface:
    Backpack is the ultimate salvation in inventory management. Your standard minecraft inventory has 36 slots in it, just enough to be handy, but terrible for long journeys or mining expeditions to the other side of the map. Backpack nonatuples your existing inventory space. (For those of you not familiar with latin, that's 9x the space).

    How is this massive inventory boost possible? The mouse wheel. (Thanks to Edward Hand for the idea!) Sneaking while Scrolling through each of the quickslots switches you to a new inventory page. This gives you freedom to scroll through NINE different pages. Scrolling without sneaking allows you to scroll through your inventory like normal.


    If you don't quite get it, I've made a short video demonstrating:




    FAQ:

    Is there a way to change the number of pages? I only want certain users to have x amount of pages.
    Yes, see the next question down!

    Is there permission or group manager support!
    Nope! There is however a configuration file (aptly named "config.xml") that is created on the first run and allows you to customize the amount of extra inventory pages, and who gets to use them.

    Are your inventories saved between logins and server restarts?
    Yes. Backpack saves the inventories in the same file notch does, in the "player".dat file.

    Updating all those files must be slow/I heard that I/O operations are slow.
    They are. Backpack is multithreaded, so if you have more than 1 core, you won't notice any lag.

    This mod doesn't have anything to do with Minecarts, why the Minecart Mania dependency?
    Minecart Mania offers a useful interface for a lot of things I needed in writing Backpack, and 70% of the code is actually in MM. If you really hate Minecart Mania, you can just install core, and disable all of the features from it's configuration file.

    Dependencies:



    Commands:

    • /open <page number>
      • Opens a dialog with your current inventory, and the inventory from that page so you can easily swap items between pages. Quick slots are numbered 1-10, with 1 on the leftmost side.
    • /backpack
      • Toggles your backpack on or off.

    Permissions:
    (Permissions is optional, but will be used if installed)
    • backpack.toggle
      • Allows the use of the /backpack command
    • backpack.open
      • Allows the use of the /open command
    • backpack.saveactionbar
      • Saves the action bar in-between pages
    • backpack.maxpages.# (where # is a number 1-9 [e.g backpack.maxpages.6])
      • The maximum pages allowed for the players
    Changelog:
    • Version 0.10
      • Initial Release!
    • Version 0.11
      • Swapped the role of sneaking around
    • Version 0.12
      • Player death is handled correctly
      • When your current inventory page is full, nearby items on the ground will be added to empty slots in other inventory pages.
    • Version 0.13
      • Added a first time login message. Only is triggered once for each player.
    • Version 0.14
      • Added customizable amount of inventory players, through XML.
    • Version 0.15-0.20
      • Bug Fixes
    • Version 0.21
      • Added /open command
    • Version 0.23
      • Reduced I/O operations from being continuous to once per minute
      • Fixed a bug which could cause player inventory pages to be lost if the server shut down in such a way that MM unloaded before the I/O operations finished.
    • Version 1.0
      • Fixed lag caused by I/O operations
      • Player Data now saves correctly, and will not become corrupt during server shutdowns
      • Improved Error Handling
      • Improved Console Log of Information for admins
    • Version 1.0a-1.0g
      • Bug fixes
    • Version 1.1
      • More robust inventory backups
      • /backpack command
    • Version 2.0
      • Supports MC 1.4
      • Action bar no longer switches with new inventory pages
      • Backpack saves with rest of inventory in player.dat file
      • Other plugins can access and correctly see a player's larger inventory w/o being Backpack Aware
    • Version 2.0.1
      • Backpack's work correctly after death
    • Version 2.0.2
      • Small Backpacks work correctly
    • Version 2.0.3
      • Players can choose to save the action bar or have separate action bars via the config
      • Bug fixes
    • Version 2.0.4
      • Improved Error Handling
    • Version 2.0.5
      • Fixed /open command crashing clients
    • Version 2.0.6
      • Fixed item duping on death
    • Version 2.0.7
      • Bug Fixes
    • Version 2.0.8
      • Permissions Support
      • Efficiency Changes
      • Bug Fixes
    • Version 2.0.9
      • Updated to MC 1.5
    • Version 2.1.0
      • Minor fixes/Cleanup
    • Version 2.2.0
      • New saving system
      • Lots of cleanup
      • Lots of bug fixes
  2.  
  3. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Can't detect keypresses from the server - I had to use workarounds for the sneaking press and scrolling through items.
    [MERGETIME="1299606744"][/MERGETIME]
    @ScittSpittle

    Thanks - harmless sense the player is offline, but annoying. Fixed in 1.oc.
    [MERGETIME="1299615864"][/MERGETIME]
    Fixed in 1.0e. ;)
  4. Offline

    sintri

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Well using it for a bit and shift 1-9 does the same thing for those with a trackball, unfortunately I often switch tool slots while crouching so that sort of gets in the way of it. Though sorta sucks can't really do anything about the keypresses.

    Other than that, the auto collection without having to switch pages is nice, filled 5 pages while redigging a subway with movecraft's drill. Would be nice if quickstash worked with backpack, was a bit of pain stashing all the blocks into storage.
  5. Offline

    ScottSpittle

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I still get this error with version e


    2011-03-10 09:17:23 [SEVERE] Could not pass event PLAYER_ITEM_HELD to Backpack
    java.lang.NullPointerException
    at com.afforess.backpack.BackpackPlayer.getInventoryPage(BackpackPlayer.java:22)
    at com.afforess.backpack.BackpackPlayer.updateInventoryWindow(BackpackPlayer.java:61)
    at com.afforess.backpack.BackpackPlayer.setInventoryPage(BackpackPlayer.java:37)
    at com.afforess.backpack.BackpackManager.initializeBackPack(BackpackManager.java:181)
    at com.afforess.backpack.BackpackPlayerListener.onItemHeldChange(BackpackPlayerListener.java:17)
    at org.bukkit.plugin.java.JavaPluginLoader$15.execute(JavaPluginLoader.java:200)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:59)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:225)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:573)
    at net.minecraft.server.Packet16BlockItemSwitch.a(SourceFile:24)
    at net.minecraft.server.NetworkManager.a(SourceFile:230)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:70)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:338)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:253)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)

    CB 458.
  6. Offline

    GammahGotz

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Hi, just started using Bukkit yesterday, and I was wondering, after I downloaded the plugin, I ran the server and everything worked normally just like you said.
    However, after disconnecting from, and rebooting, the server, an older version of my first inventory (version came from DIRECTLY before i started adding items into second) replaced the newer version; while hte newer first inventory was moved into the second inventory. Second Inentory dissapeared forever...
    Any ideas for how to retrieve second inventory/fixes for whatever caused this would be much appreciated.
    Thank you!
  7. Offline

    morikubo

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    which bukkit, did you restart server before exiting?
  8. Offline

    buckeT.de

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Hey Afforess,

    and again, a damn usefull nice awesome plugin :)

    One suggestion: Could you make the "normal" scroll configuralable?
    So I want to configure if I have to sneak or to walk to change my current items or inventory.

    Would be nice.

    Greetz,
    buckeT
  9. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Updated to 1.0f, now supports the latest recommended build.
    [MERGETIME="1299784368"][/MERGETIME]
    QuickStash should work with it.
  10. Offline

    Taeir

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    if someone kicks people i still get the "Could not pass event PLAYER_MOVE to Backpack" error.
  11. Offline

    woodzy

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    getting this error at server start up
    00:11:41 [SEVERE] [BACKPACK] Failed to read contents of backpack!
    >
  12. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Please post the error log.
    [MERGETIME="1299966080"][/MERGETIME]
    Happens when Backpack can't read the data from one of the data files.
  13. Offline

    woodzy

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    is there a way to fix it? its at all most every startup and look at the conve i started with you
  14. Offline

    Taeir

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    When a player is kicked, i sometimes get this error. Using kick and ban system of essentials.
    Code:
    2011-03-12 19:20:41 [SEVERE] Could not pass event PLAYER_MOVE to Backpack
    java.lang.NullPointerException
     at com.afforess.backpack.PlayerInventorySorter.<init>(PlayerInventorySorter.java:21)
     at com.afforess.backpack.BackpackPlayerListener.onPlayerMove(BackpackPlayerListener.java:52)
     at org.bukkit.plugin.java.JavaPluginLoader$7.execute(JavaPluginLoader.java:192)
     at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:59)
     at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:255)
     at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:123)
     at net.minecraft.server.Packet10Flying.a(SourceFile:126)
     at net.minecraft.server.NetworkManager.a(SourceFile:230)
     at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
     at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
     at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:357)
     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:272)
     at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)
    
  15. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Fixed for next release.
    [MERGETIME="1300056258"][/MERGETIME]
    I've included a much more descriptive error message in 1.0g. Once you see the error again in the latest version, please give me a copy of the console logs.

    Thanks.

    Backpack Updated to 1.0g
    -Fixed exception when players are kicked
    -More descriptive log when failed to read item
  16. Offline

    woodzy

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    i will do that for you, it would seem that im a "tester" for you
    XD
  17. Offline

    gazius

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Would it be possible to add a configuration to disable the crouch + scroll switch and only use a command like /i1-9? I really like this mod but when working around lava it gets kind of inconvenient to have.
  18. Offline

    iarspider

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    It would be nice (and quite logical, in fact) if backpack data is stored in the "world" folder(s), instead of a plugin folder.
  19. Offline

    Linaks

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Nice plugin :)
    One question..
    Is this plugin dynamic? I mean, i dont want to restart my server every minute if I want to add an user into the config list where i add him pages. Maybe you can add a command where we can add players with optional pages into the config list, like /bpadd Linaks [pageamount]

    /bpadd Linaks 9
    /bpadd mikel21 3
    etc..

    bp = backpack
    Linaks = Playername
    [pageamount] no description necessary :)


    Thanks <3

    //Edit:

    Bugreport: If I restart the server, all items in the backpack are lost..
    PLEASE FIX THAT.
  20. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    "/i" (as are many of the single letter command names) are already commonly used. I also want to keep this plugin as simple as possible, since I find that commands often take away from the minecraft experience, and fragment gameplay. So no. ;)
  21. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I'm pretty sure most people would cringe and run in panic at any plugin that touched the world folder. I know I wouldn't want any plugin that modifies that directory.
  22. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    There's a "default" setting, but having a command to add players is a pretty decent idea. I'll add something like that next release.

    Backpack saves items on server restarts, but remember to use the "stop" command, and not just kill the process. Backpack also auto-saves every 5 minutes, but if you added items recently, and killed the server, they will be lost.
  23. Offline

    Stephen92

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    can someone please post ur users config i cant seem to be able to configure it.
  24. Offline

    DJHenjin

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    hello I am having a problem with starting up my server where it hangs on backpack version 1.0g usign CB build 556 no error messages just takes forever to start.
  25. Offline

    Jessicadawn

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Quick question. Anyway you can make it /backpack off /backpack on

    and maybe use arrow keys not the scroll thing because it goes 2 fast
  26. Offline

    wierd

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Love this plugin, been using it for a while.
    I've got a couple issues I'd like to call attention to:
    1) There is a duplication/lost item bug having to do with /open
    if you /open a page, and put items into it, or take items out of it, then close the page with 'i', then without moving, use /open to open the same page again, the page will be what it was before you added or removed items from it. allowing you to duplicate items or accidetnally lose items (man, that sucks)
    you have to move after using /open or the changes wont save (can anyone else confirm this, or is it just my server?)
    I guess this means you save changes to backpack on a players move event.
    2) if a server is being unstable, it can cause the entire backpack file for a single user to be wiped, erasing all items except the ones on the page that already had open (im assuming its cause the active page is also stored in the player dat file)
    I really do not know the best way to handle either problem, but I figured I needed to say something to be sure you were aware of these problems.

    Thanks for the wonderful plugin.

    Just found another bug...
    3) If a player logs in then logs out without moving, if the server then shuts down, you get this error message.
    Code:
    09:27:03 [INFO] [BACKPACK] Saving Player Data!
    09:27:03 [SEVERE] java.lang.NullPointerException
    09:27:03 [SEVERE] at com.afforess.backpack.BackpackPlayer.getInventoryPage(BackpackPlayer.java:23)
    09:27:03 [SEVERE] at com.afforess.backpack.PlayerInventoryUpdater.<init>(PlayerInventoryUpdater.java:16)
    09:27:03 [SEVERE] at com.afforess.backpack.Backpack.onDisable(Backpack.java:45)
    09:27:03 [SEVERE] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:120)
    09:27:03 [SEVERE] at org.bukkit.plugin.java.JavaPluginLoader.disablePlugin(JavaPluginLoader.java:465)
    09:27:03 [SEVERE] at org.bukkit.plugin.SimplePluginManager.disablePlugin(SimplePluginManager.java:229)
    09:27:03 [SEVERE] at org.bukkit.plugin.SimplePluginManager.disablePlugins(SimplePluginManager.java:223)
    09:27:03 [SEVERE] at org.bukkit.craftbukkit.CraftServer.disablePlugins(CraftServer.java:81)
    09:27:03 [SEVERE] at net.minecraft.server.MinecraftServer.g(MinecraftServer.java:227)
    09:27:03 [SEVERE] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:302)
    09:27:03 [SEVERE] at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)
    09:27:03 [SEVERE] [BACKPACK] Failed to save --nameremoved--'s inventory data!
    as you can see, thats bad =) the backpack data for that player is wiped.
    if a player makes sure to move before logging back out, no problems when the server shuts down
  27. Offline

    Badzilla

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Well, this is certainly not funny at all. I just lost all of my inventory from every one of the slots but the first slot. Why would it do this? Is there any way to get it back?
  28. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Please upload your entire backpack data folder.
  29. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Yeah, I'll add that next release.
  30. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Wow, thanks for the detailed report.

    1.) Yes, you have the problem dead on. I check for moving or scrolling to detect when the player has exited the window, but it seems you found a way around that. I've changed the plugin so the /open command will also update the inventory correctly too.

    2.) I've done almost everything I can to minimize data loss, since I realize it's a critical issue. For the next release, I'm going to have Backpack back up the data file when it writes a new one, and restore it if something goes wrong. Hopefully that will help mitigate issues.

    3.) Ouch! And such an easy bug to fix too.
  31. Offline

    Afforess

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    By lost - you mean your items are gone?

    First - are you sure you didn't just scroll to a new page by mistake?
    Second - If you're items really ARE gone, what were you doing around the time they disappeared? Item loss should only occur at server restarts, if at all. Does your console report anything unusual?
  32. Offline

    Badzilla

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Gone means gone. The first time it was all slots except the main one. When I got up this morning, there was more messages in the console about the issue with MM vehicle or something like that. It has been reported in the MM thread many times. This caused the client to disconnect. I closed the client and did a stop on the server. Started both back up and I had absolutely no items in any slot.

    I say slot meaning page. So all pages all slots gone.

Share This Page