[INACTIVE][DEV] Persistence v0.76 - Data-Driven Bukkit [677]

Discussion in 'Inactive/Unsupported Plugins' started by NathanWolf, Jan 29, 2011.

  1. Offline

    NathanWolf

    Persistence - Data-Driven Bukkit

    PLEASE NOTE
    Persistence is a developer API and framework- NOT a game or admin plugin.

    If you've come here looking for plugin/admin support for Spells, Wand, NetherGate or any other plugin that uses Persistence- please turn around and go back to that thread. Thank you for your cooperation!

    If you're a dev, then check the Persistence wiki for information on using the Persistence framework.

    View changelog on github
     
    Duccis likes this.
  2. Offline

    NathanWolf

    Actually- if you want to test it, here what you do- make the LocationId an int.

    Get that int by making a BlockVector- I'm not sure the function offhand, I can look it up, but it's something like .getHashValue() once you've created it.

    Then, use that as your id for now- that should work fine.
     
  3. Offline

    WinSock

    Sweet. And your plugin works great! just a few kinks to work out.
    --- merged: Feb 6, 2011 7:02 PM ---
    Also you sould update your main post that you need to make a lib folder and rename the sqlitejdbc.jar to sqlite.jar
     
  4. Offline

    NathanWolf

    Thanks! This one is very much WIP, but once I release NetherGate it should be much more stable- having some client code "in production" goes a long way toward getting the kinks worked out... :)

    Now, after giving you the above advice, I had some interesting thoughts and I want to wax technical for a bit.

    Once this is all working, you'd have two options for how to set up DoorObject- or, specifically, its id. I don't plan (for now) on enforcing one way over the other, but I'm going to strongly encourage one, I think...

    So, basically, BlockVector is an immutable class. In terms of persistence, this means it has a unique id that I can use to store instances of it.

    As with any full-fledged entity (does not have "contained" in its PersistClass annotation), you can either contain it or not when you reference it.

    I'm going to allow this for ids as well. Functionally, in your code, there is no difference at all- it's just a BlockVector that you deal with.

    However, the data storage mechanism would be really different. If you "contain" the BlockVector, its id as well as all of its fields will be persisted along with your door class- the data table would look much like it would now, with your contained DoorPosition. You'd basically (well, not basically, actually) have your own copy of that vector, contained within your class.

    However, this is kind of contrary to the spirit of BlockVector- they are meant to be singular at runtime. So, if a spell or another plugin or whatever looks at one of your door blocks, they're actually looking at the same instance of a BlockVector.

    Now, nobody should be writing to BlockVectors, so ultimately (again, in practice) this doesn't matter. In fact, depending on how BlockVector was implemented (I haven't looked too closely), you may end up getting the same instance at runtime anyway, in which case you're either wasting a lot of data store space, or just trying to maintain internal referential integrity*.

    Small segue: I have worked with classes before in C++ that overrode their new() operator so that they could first look for a pre-existing instance in a hashmap before ever even allocating memory... but if there is something like that in Java, I am not aware of it- so you may, in fact, get a unique instance back.

    Anyway, in terms of memory consumption (both at run-time and in the data stores), referencing is more or less always the better option.

    I don't necessarily want to restrict this, because I can think of cases where you may want to use a class both as an entity and as a contained data block... but I may change my mind in the future.

    * The note on internal consistency is actually a potential valid argument for containment. If you reference all your locations and someone deletes global.db, or wipes the vector table, your data will "break". That would be unfortunate, but generally people Shouldn't Do That, so I'm not sure what to say there.

    There's also a good argument for not referencing a vector if your object is somewhat transient, or especially if it moves around- you don't want to bloat up the vector table- I don't do "GC" on the database! :)
    --- merged: Feb 6, 2011 7:14 PM ---
    Doh! Good call!

    I think the main post needs an overall update - I'll do that next release.
    --- merged: Feb 6, 2011 7:19 PM ---
    BTW, @WinSock - I'm totally geeking out on your plugin now :)

    I currently have a "safe" room in my home on my public server- I have this complex arrangement set up where you have to leave a block on a pressure plate in the corner, then go flip a switch that's hidden and camouflaged behind some bookshelves...

    While I'm very proud of this little setup (logic gates!), it sure would be a lot easier if I could just, you know, lock the door :)

    Of course, I really need to install some sort of protection plugin for that to be relevant at all... I've been pretty wide-open there since losing hMod and Cuboid!

    No sense locking the door when they can break down the wall :)
    --- merged: Feb 6, 2011 7:20 PM ---
    Oh, also- have you thought about a physical key system?

    I'm not sure how many "unnatural" materials there are (more if you don't have a Nether), but assuming you don't let your players spawn items you could create a pretty cool system where each person can use a material as their key- only they can spawn that item, but anyone that has one can enter your door... that would be cool!
     
  5. Offline

    WinSock

    Yep the admin on my server is loving it also. he is geeking out other a feature i'm adding. Entrance fees to some doors :p People can now make money off of attractions :p
    --- merged: Feb 6, 2011 7:25 PM ---
    And i can only could 12 unobtainable items with out /item including liquids and fire :p I like the idea but the number of keys are lacking.
     
  6. Offline

    NathanWolf

    Wow, great idea! I noticed iConomy was linked, now I get why :)

    Ah, yeah... that'd work great for me on my small friends-only server, but for most public servers that'd make things complex.

    You could make a "friends" system (which should probably be its own plugin at that point), and limit groups of friends to 12 I guess :)
     
  7. Offline

    WinSock

    Also the how to use your messaging system in the main post is messed up you forgot to mention this.
    Code:
    private Messaging messaging = null;
    ....
    public void onEnable() {
    messaging = new Messaging(this, persistence);
    PluginCommand pDoorsCommand = messaging.getGeneralCommand("mycommand", "Does something cool", "mycommand <parameters>");
    PluginCommand pDoorsCreate = pDoorsCommand.getSubCommand("sweet", "Does something even better", "sweet <parameters>");
    }
    
     
  8. Offline

    NathanWolf

    Now that you mention it, I'm thinking of renaming that class- I'd be open to suggestions! "PluginUtilities" is the best I've got so far but.... I kind of hate it.

    Basically, it's going to start covering functionality that would be less and less covered by the "messaging" moniker- and I don't really see a need to break it up.

    The only reason it's there at all is that Messaging instances are per-plugin, and Persistence is global.

    Anyway- it's going to have support (soon) for Materials, Material variants, Material lists (with automatic hashmap support for quick checks), and a BlockList/BoundingBox/Undo system built-in.

    So, yeah, "Messaging" just doesn't really fit the bill anymore.

    I'll definitely update the OP next release- I'd also be happy to update your code and submit a pull request, I already took the liberty of forking it :)
     
  9. Offline

    WinSock

    Awesome :p so i should abandon the messaging system? and just use bukkit's way?

    Edit:
    Oh i see what you mean your just refactoring :p
    And don't make any changes yet i'm about to push a huge update :p
     
  10. Offline

    NathanWolf

    P.S. Have you gone and looked at the schema it's created in global.db? Explored the /phelp system? Not sure if any of that is in the latest release, but it should all be checked in to github! :)
     
  11. Offline

    amkeyte

    I will be trying this out. I like the fact that you have good documentation and this is well supported. I'll have to stick with Permissions, since all the other plugins I'm running are tied in to that already. I'll let you know if I come up with any issues.

    Thanks!
     
  12. Offline

    NathanWolf

    Oh, no, please don't! :)

    I mean, you can if you want- but I really like it, personally.

    It's not really going to change at all, unless I get any new ideas or suggestions- I like it as-is. It abstracts away the concept of the CommandSender really well. You can actually add a row to global.sender with a valid class name and it will just work. That is, if there's actually a way to send a command right now from a custom sender- I don't even know if they've implemented that yet.

    Anyway, I'm just renaming it because it's going to have more awesome functionality, is all :D
    --- merged: Feb 6, 2011 7:48 PM ---
    No, thank you! I try to provide good support because I enjoy people using this- I hope it helps you out.

    I'll definitely keep everyone updated on the status of Permissions/bukkit permissions integration. It's a bit far out on the list right now, but it's definitely On The List.

    It's not going to be a crazy foreign thing- same basic structure as Permissions and, I imagine, as the built-in system will be. So, if you implement Permissions support now, you can easily choose to transition to Persistence or the built-in when the time comes.
     
  13. Offline

    amkeyte

    It would make my day if Permissions went over to this! hahahaah I like the modified form of ACL it implements to allow inheritance and the nodes are handy as well. For my case I want to be able to add a user to a group and have it apply to everything on the server. MyWarps, WorldEdit, WorldGuard, HeroChat... its all tied in. My big complaint is that I have to use Essentials (for now) to allow admins to add and remove users from groups, or else edit and reload the Permissions config file. I think that's where a system like this will have an advantage, sense the current method just seems clunky.

    I'm also excited about the command handling.
     
  14. Offline

    WinSock

    Ok new error and i think i see the problem in your source:
    Error:
    Code:
    2011-02-06 14:48:20 [WARNING] Failed to handle packet: java.lang.NullPointerExce
    ption
    java.lang.NullPointerException
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:191)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:193)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:170)
            at com.bukkit.WinSock.ProtectedDoors.ProtectedDoors.onCommand(ProtectedD
    oors.java:329)
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:17)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:76
    )
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:1
    62)
            at net.minecraft.server.NetServerHandler.c(NetServerHandler.java:584)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:563)
            at net.minecraft.server.Packet3Chat.a(SourceFile:24)
            at net.minecraft.server.NetworkManager.a(SourceFile:232)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:71)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:104)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:283)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:209)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:512)
    
    Your Code:
    Code:
    String[] childParameters = new String[parameters.length - 1];
    for (int i = 0; i < childParameters.length; i++)
    {
    	childParameters = parameters[i + 1];
    }
    
    It looks fine to me but it freaks out when i do any commad:
    EDIT:
    It's an error on my part but idk were it is because now i cannot us any commands :(
     
  15. Offline

    NathanWolf

    Hm.. I'm hoping to get your code up and running soon, I'll try and reproduce. I know there were some errors in the command-dispatch system that I fixed- I thought I had made a release since then, but you may to try pulling from source, if you're not already (are you?).
     
  16. Offline

    WinSock

    I just pulled and compiled but now i'm getting a sqlite not found error and its in the right dir. and to be sure i copied the file everywhere :p
     
  17. Offline

    NathanWolf

    Ah- yeah, that's an annoying thing. Make sure to use the manifest file when you export! The really annoying part is that eclipse doesn't remember the last manifest used per-project, so if you switch back and forth exporting two projects a lot (like I do), it's a real hassle.

    If anyone has a better system (in Eclipse), I'd love to know it!

    Now, on a side note- I'm trying to build your code, and I think I need some of your help!

    Here's where we really see how ignorant I am of Permissions- I've never actually bound to it!

    I have the jar, I have it referenced in your project, but I've still got a ton of errors around Permissions-y looking code:

    Code:
    if (!ProtectedDoors.Permissions.has(player, "pdoors.admin"))
    Gives me:

    The method has(Player, String) is undefined for the type PermissionHandler DoorBlockListener.java /Protected-Doors/src/com/bukkit/WinSock/ProtectedDoors line 146

    Do you know what I'm doing wrong, here?

    BTW, I have a current build of Persistence put together- it's what I was going to use to test your code. I'm not done refactoring yet, but it should be stable at this point.

    For your purposes, though, it's probably worth waiting for BlockVector support once we have things working, anyway- so I may wait a bit to release.
     
  18. Offline

    WinSock

    Re checkout my code because i have changed it a lot :p
     
  19. Offline

    NathanWolf

    Oh, ok! Will do :)

    Or, rather, I will try to update my fork.... which I must say never seems to work right for me on github.

    EDIT: yeah, that didn't work. I hate github sometimes! I'll just pull a read-only copy for now, I can mail you a zip if you want the changes :)

    --- merged: Feb 6, 2011 10:47 PM ---
    I'm actually kind of wondering if I haven't already fixed this object-as-id thing. I really thought I'd covered it in the last refactor- but maybe I never released that build since it didn't really have any new features.

    I'm really curious to test your code to see, but I guess I need to get BlockVector working first, since you've probably blown away DoorLocation by now, eh? :)
     
  20. Offline

    WinSock

    Yep, i just left the code file in there until i get confirmation that BlockVector is working.
    EDIT:
    Just force an commit on your fork and do a pull request that should work.
    --- merged: Feb 6, 2011 10:59 PM ---
    ok i was able to run the latest commit on GitHub and now i get a more useful error
    Code:
    2011-02-06 16:58:35 [SEVERE] Persistence: Error invoking callback method onpDoor
    s of com.bukkit.WinSock.ProtectedDoors.ProtectedDoors
    java.lang.reflect.InvocationTargetException
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
            at java.lang.reflect.Method.invoke(Unknown Source)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:241)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:179)
            at com.bukkit.WinSock.ProtectedDoors.ProtectedDoors.onCommand(ProtectedD
    oors.java:358)
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:17)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:77
    )
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:1
    57)
            at net.minecraft.server.NetServerHandler.c(NetServerHandler.java:595)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:574)
            at net.minecraft.server.Packet3Chat.a(SourceFile:24)
            at net.minecraft.server.NetworkManager.a(SourceFile:232)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:71)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:104)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:283)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:209)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:512)
    Caused by: java.lang.NoSuchMethodError: com.elmakers.mine.bukkit.plugins.persist
    ence.dao.PluginCommand.sendHelp(Lorg/bukkit/command/CommandSender;)V
            at com.bukkit.WinSock.ProtectedDoors.ProtectedDoors.onpDoors(ProtectedDo
    ors.java:198)
            ... 19 more
    
     
  21. Offline

    NathanWolf

    Thanks, I'll try that! I'd love to know how to do this right, it'd motivate me more to work on Bukkit bugs.

    Heh- did you miss-spell "onDoor" when binding your event handler?

    The first victim of the scripty-ness of the command dispatch interface, perhaps... hmmm.... I wish you could pass a method as a parameter. (Uh, I'm assuming you can't... maybe I should try it?)
     
  22. Offline

    WinSock

    I just got it to work, it was the version of bukkit i was building on :p it all working now and im almost ready for prime time xD
    --- merged: Feb 6, 2011 11:19 PM ---
    Ohh i got a good idea make an interface
    Code:
    public interface Command
    {
        public void notify(Sender, args);
    }
    
    public class onDoor implements Command
    {
        public void notify(Sender, args)
        {
        }
    }
    
    public void notify(Command command, Sender args)
    {
        command.notify(Sender, args);
    }
    
    notify(new onDoor(), Sender, Args);
     
    NathanWolf likes this.
  23. Offline

    NathanWolf

    I like it!

    I want to think on it some more- wouldn't that get really "busy" with a lot of commands? I like to have all my command handlers in one class, if possible. It could certainly be in there, though, as an option!
    --- merged: Feb 6, 2011 11:30 PM ---
    Ok, so, @WinSock, I pulled your latest and I'm still getting the same errors I listed above- any idea what I'm doing wrong? I'm assuming it's something with linking to Permissions- do I have an outdated Permissions.jar or something?
     
  24. Offline

    WinSock

    idk, did you get the latest on from his thread? but i have one question how do you remove an object. I set it to null but im still not getting it to be removed.
     
  25. Offline

    amkeyte

    Also having the null pointer error on command. Going to update my bukkit, though its only a day old? maybe two. In any case its kicking my client off, and just issuing a warning in console.

    Code:
    2011-02-06 15:16:34 [INFO] Starting minecraft server version Beta 1.2_01
    2011-02-06 15:16:34 [INFO] Loading properties
    2011-02-06 15:16:34 [INFO] Starting Minecraft server on *:25565
    2011-02-06 15:16:34 [WARNING] **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
    2011-02-06 15:16:34 [WARNING] The server will make no attempt to authenticate us
    ernames. Beware.
    2011-02-06 15:16:34 [WARNING] While this makes the game possible to play without
     internet access, it also opens up the ability for hackers to connect with any u
    sername they choose.
    2011-02-06 15:16:34 [WARNING] To change this, set "online-mode" to "true" in the
     server.settings file.
    2011-02-06 15:16:34 [INFO] Preparing level "world"
    2011-02-06 15:16:34 [INFO] Preparing start region
    2011-02-06 15:16:35 [INFO] Preparing spawn area: 36%
    2011-02-06 15:16:36 [INFO] Preparing spawn area: 61%
    2011-02-06 15:16:37 [INFO] [AntiBuild] version [1.0] (Reborn) loaded
    LWC     [v1.49] Loading shared objects
    Config  [v1.49] Loaded 8 config entries
    LWC     [v1.49] Native library: lib/native/Windows/x86/sqlitejdbc.dll
    Updater [v1.49] Update detected for LWC
    Updater [v1.49] Latest version: 1.491
    2011-02-06 15:16:38 [INFO] [Permissions] version [2.0] (Handler) loaded
    2011-02-06 15:16:38 [INFO] WorldEdit 3.2.2 loaded.
    2011-02-06 15:16:38 [INFO] WorldEdit: Permissions plugin detected! Using Permiss
    ions plugin for permissions.
    2011-02-06 15:16:38 [INFO] WorldGuard 3.2.1 loaded.
    2011-02-06 15:16:38 [INFO] WorldGuard: Permissions plugin detected! Using Permis
    sions plugin for permissions.
    2011-02-06 15:16:38 [INFO] WorldGuard: Single session is enforced.
    2011-02-06 15:16:38 [INFO] WorldGuard: TNT ignition is PERMITTED.
    2011-02-06 15:16:38 [INFO] WorldGuard: Lighters are PERMITTED.
    2011-02-06 15:16:38 [INFO] WorldGuard: Lava fire is blocked.
    2011-02-06 15:16:38 [INFO] WorldGuard: Fire spread is UNRESTRICTED.
    2011-02-06 15:16:38 [INFO] [MYWARP]: 1 warps loaded
    2011-02-06 15:16:38 [INFO] [MYWARP] Permissions enabled.
    2011-02-06 15:16:38 [INFO] MyWarp 1.9 enabled
    BorderGuard version 2.0 is enabled!
    2011-02-06 15:16:38 [WARNING] Warps were not found in warps folder
    2011-02-06 15:16:38 [INFO] Loaded e b141 by Zenexer, ementalo, Eris, and EggRoll
    
    2011-02-06 15:16:38 [INFO] HeroChat version 2.63 enabled.
    2011-02-06 15:16:38 [INFO] WorldEdit: Permissions plugin detected! Using Permiss
    ions plugin for permissions.
    2011-02-06 15:16:38 [INFO] WorldGuard: Permissions plugin detected! Using Permis
    sions plugin for permissions.
    Updater [v1.49] Update detected for LWC
    Updater [v1.49] Latest version: 1.491
    LWC     [v1.49] Loaded command: /lwc -admin
    LWC     [v1.49] Loaded command: /lwc -create
    LWC     [v1.49] Loaded command: /lwc -free
    LWC     [v1.49] Loaded command: /lwc -info
    LWC     [v1.49] Loaded command: /lwc -p
    LWC     [v1.49] Loaded command: /lwc -modify
    LWC     [v1.49] Loaded command: /lwc -unlock
    LWC     [v1.49] -> PLAYER_QUIT
    LWC     [v1.49] -> ENTITY_EXPLODE
    LWC     [v1.49] -> BLOCK_INTERACT
    LWC     [v1.49] -> BLOCK_DAMAGED
    LWC     [v1.49] Dev mode: FALSE
    LWC     [v1.49] Using Nijikokun's permissions plugin for permissions
    LWC     [v1.49] Loading SQLite
    PhysDB  [v1.49] Creating physical tables if needed
    MemDB   [v1.49] Creating memory tables
    SQLite  [v1.49] Using: Native
    2011-02-06 15:16:39 [INFO] Persistence version 0.22 is enabled
    2011-02-06 15:16:39 [INFO] [ShirtsAndSkins] version 0.1 is enabled!
    2011-02-06 15:16:39 [INFO] Done! For help, type "help" or "?"
    ss
    2011-02-06 15:16:43 [INFO] [ShirtsAndSkins] org.bukkit.command.ConsoleCommandSen
    der@7d3050
    2011-02-06 15:16:43 [INFO] [ShirtsAndSkins] org.bukkit.command.PluginCommand@ef0
    cdb
    2011-02-06 15:16:43 [INFO] [ShirtsAndSkins] ss
    2011-02-06 15:16:43 [INFO] [ShirtsAndSkins] [Ljava.lang.String;@352d87
    2011-02-06 15:16:43 [WARNING] Unexpected exception while parsing console command
    
    java.lang.NullPointerException
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:226)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:170)
            at info.aksandbox.bukkit.shirtsandskins.ShirtsAndSkins.onCommand(ShirtsA
    ndSkins.java:99)
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:17)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:76
    )
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:1
    62)
            at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:310)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:292)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:209)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:512)
    ss help
    2011-02-06 15:16:49 [INFO] [ShirtsAndSkins] org.bukkit.command.ConsoleCommandSen
    der@7d3050
    2011-02-06 15:16:49 [INFO] [ShirtsAndSkins] org.bukkit.command.PluginCommand@ef0
    cdb
    2011-02-06 15:16:49 [INFO] [ShirtsAndSkins] ss
    2011-02-06 15:16:49 [INFO] [ShirtsAndSkins] [Ljava.lang.String;@10794d4
    2011-02-06 15:16:49 [WARNING] Unexpected exception while parsing console command
    
    java.lang.NullPointerException
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:226)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:193)
            at com.elmakers.mine.bukkit.plugins.persistence.Messaging.dispatch(Messa
    ging.java:170)
            at info.aksandbox.bukkit.shirtsandskins.ShirtsAndSkins.onCommand(ShirtsA
    ndSkins.java:99)
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:17)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:76
    )
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:1
    62)
            at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:310)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:292)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:209)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:512)
    
    I'll update when I find a fix.

    [edit]
    fixed... downloaded source and rebuilt. system checks good.
     
  26. Offline

    WinSock

    Grabbing the latest commit from his github and building it worked for me.
     
  27. Offline

    amkeyte

    murgle... I'm using Netbeans, and have no clue about Maven.
    ...manually converting to a netbeans project... Fortunately the classpath is easy to set up! :)
    ...ok tested, and yes commands are working again.

    Thanks, both!
     
  28. Offline

    NathanWolf

    As it turns out, you can not instantiate an annotation. It's a sort-of-interface, not a sort-of-class. You can't even really extend it, without warnings, at least.

    So, a bit more refactoring before I can get to BlockVector- I've now got EntityInfo and FieldInfo classes that are the run-time equivalent of the annotations. You fill these out just like in the example code I had above- though, you don't actually construct PersistedClass- you call persistence.getPersistedClass(MyClass.class, myClassInfo) (more or less, I think that's the signature.)

    Things are coming along well- it just keeps getting cleaner and cleaner. Always a good sign.
    --- merged: Feb 7, 2011 12:03 AM ---
    You have to call remove() - I think it's implemented.... !

    Basically, put(), get() and remove() are your main tools. I can't do anything with a put(null), 'cause I don't know what to remove :)
     
  29. Offline

    WinSock

    Bump that question :p
    Edit u edited as i posted that :p and i see no remove function.
     
  30. Offline

    NathanWolf

    Awesome!

    I'll hopefully have a nice jar update by tonight :)

    Doc updating... uh, well, that might take a bit. There will be a good bit of new functionality in the upcoming few releases.
    --- merged: Feb 7, 2011 12:04 AM ---
    Beat you to it :)

    Let me know if remove() doesn't work- believe it or not, I have not yet had cause to use it :)
     
  31. Offline

    WinSock

    There is not remove to test at least on you github :p
     

Share This Page