Crafty v0.7.6 Tested with CraftBukkit 1240, server 1.8.1 Note: Do NOT update to 0.7.6+ unless you are using Minecraft 1.8.1+ Description A server GUI for CraftBukkit. Enjoy all your standard console goodness supplemented with buttons and text boxes and so forth. Works with your existing CraftBukkit.jar. Screenshot Features Automatically starts CraftBukkit on load Properly shuts down the server on exit Stop/Restart Displays a list of active users (updated every 3 seconds) Kick/Ban/Op/DeOp/Get IP from player list (right-click) Allows you to enter console commands without the console output getting in your way (I hate it when I'm in the middle of typing a command and a bunch of text splits my text) Displays current memory and CPU usage Displays startup args, server version, and CraftBukkit version Some basic syntax highlighting (more to come) Download & Installation Download Crafty Unzip to your craftbukkit folder (the same folder as craftbukkit.jar) (Windows) Run: crafty.bat (Linux) Run: java -Xincgc -Xmx1G -jar crafty.jar -nojline (Mac) Double-click jar, OR use Linux instructions, OR set up a shell script matching the Linux instructions Commands Remember to prefix the commands below with '.crafty ' (note the space)! about - alias of .crafty version version - Shows version info for Crafty help [command] - Shows help summary or command-specific help exit - Stops the server and exits Crafty stop - Stops the server without exiting start - Attempts to start the server if the initial start failed (typically because the port wasn't open) restart - Stops the server if it's running and relaunches Crafty theme - Theme commands theme set <name> - Sets the current theme. Available themes are Default and Dark theme current - Lists the currently active theme font - Font commands font setsize <number> - Sets the current font size to a specific point value (default 14.0) font increase - Increases the font size by 2 points font decrease - Decreases the font size by 2 points Notes Uses javaw instead of java for startup Early version; please report bugs; do not stare directly into the sun; YMMV Roadmap & Wishlist [UI] Customizable text and background colors [In progress; 0.5 (partial)] [Feature] 'Give' player context menu option [Planned; 0.8?] [Feature] Minimize to tray [Planned; 0.8?] [Feature] Persist theme & font options [Planned; 0.8?] [Feature] Plugin list pane/window [Feature] Enable/Disable plugins [Feature] Auto updater or update check [UI] Alternate icons or no icons Changelog 0.1 - First version; basic CraftBukkit startup and monitoring 0.2 - Fixed some issues; added performance monitor 0.3 - Fixed CPU calculation; added args/version check 0.4 - Added context menu to player list (Kick/Ban/Op/DeOp/Get IP) 0.5 - Updated for CraftBukkit 271+; adds basic theme support 0.6 - Added restart capability via: .crafty restart 0.7 - Added font setting; fixed port check bug; other minor fixes 0.7.1 - Minor fixes; console cleanup; logging 0.7.2 - Update for RB 674 0.7.3 - Update for MS 1.5_02, CB 705 0.7.4 - Update for CPU usage issue 0.7.5 - Fix for the weird startup error, updated for CB 1000 0.7.6 - Update for CB 1240
This is the second mock-up I've seen, it seems a lot of people want a GUI... What would be really nice in a GUI, is a proper CPU/RAM monitor (the vanilla Minecraft GUI is horribly inaccurate). The GUI should also list the command the server was ran with. If the GUI could have a check box list of plugins (check box so they can be disabled), it would be a plus. It needs a way to access all of the built in server commands. Sure, you can type them out, but the CLI works really well for that already. Also, it needs to be fancier. My terminal is fancier than this currently. /rambling
This isn't a mockup. That's a screenshot of a working GUI running on my computer. I have no idea how to do this, but I'll look into it. That should be easy enough. It should all be in args[], I think. I like the idea, but is plugin disable even working yet? Do most plugins support it? Can you elaborate?
My bad, I've seen similar GUI's a few times, usually Mock-ups. Not in any specific command yet. I was thinking it could just remove the jar file (or rename it .gbak or something unique) so that it would read the list of files and if they had that extension, know they were disabled. If plugin is currently enabled, it would know to rename that jar file to .gbak on server shutdown (of vice versa). Might be more trouble than its worth, but hey, we're going for a GUI - should make everyone's life easier, right? I run a Linux terminal. I think it looks prettier, but I'm mainly just busting balls here.
Download link for anyone who wants to check it out: http://dl.dropbox.com/u/17925907/Minecraft/Crafty/Crafty-v0.1.zip Unzip crafty.jar and crafty.bat to your craftbukkit folder. Note that I've only tested this on Vista x64 with Craftbukkit 218.
Can you fill me in on what that Crafty.jar does? The bat file is easy enough to understand, but how is the server launched? Does the craft.jar launch the server with the commands you entered in the bat file?
Yes. It basically replicates the server load process in CraftBukkit's Main.java file (loads configs, passes args to the MinecraftServer main()). Crafty redirects System.in, System.out, and System.err to control the console I/O. It uses the method outlined at http://forums.bukkit.org/threads/send-commands-to-console.3241 to send commands to the server.
@DerpinLlama Yeah I saw that. I like the syntax highlighting. The admin/mod/user flags in the user list are probably impractical though; that would tie the GUI to specific plugin(s). Detecting Ops should be doable though. I think I've found out how to get memory usage as well. --- merged: Feb 3, 2011 5:09 PM --- It's doable but apparently only with the Oracle/Sun JVM, not as part of the standard API. I'm not sure whether that is likely to cause trouble for most users or not.
Couldnt u just tell them to download sun JVM? i rly do think that almost every people here got it ^^ hmm.. could also be nice with a "loaded Plugins" thing.. so instead of posting up in the console window(or whatever its called) it just shows the Loaded Plugins in a seperate little window like with the online users? but that would prob be alot of coding ^^
Added memory and CPU usage monitor: http://dl.dropbox.com/u/17925907/Minecraft/Crafty/Crafty-v0.2.zip Maybe a Linux user can tell me if it explodes horribly. I did attempt to add a safety check on the non-standard code, but I can't really test it on the standard JVM. If you're on Linux and it doesn't crash and it says the CPU usage is 0.00, then that's fine.
how do i make it run with more than 109 mb? coz its using 65/109 oO? my server is constantly spamming: 2011-02-03 19:08:51 [WARNING] Can't keep up! Did the system time change, or is the server overloaded?
@Daniel Bang I'm not seeing that behavior. Mine is at 80/171mb with 1 player (myself) on the server. It was at 60/103 when I joined, and after warping once, it reached about 98 before allocating more memory (up to 171). I assume you're using the included .bat file, which uses an alternate garbage collector. It doesn't allocate memory the same way the regular GC does, so you'll see lower memory usage numbers until more memory is needed. If it's at 65/109, it doesn't need to allocate more memory yet, and the problem you're experiencing is unrelated to memory. More likely you're seeing normal warnings the server tends to toss up when joining/warping or otherwise loading/unloading chunks. --- merged: Feb 3, 2011 7:45 PM --- I just now noticed the "Bukkit Tools" subforum. Why it's a sub of "Discussion and Support" is a mystery to me. --- merged: Feb 4, 2011 8:31 AM --- Thanks to whichever mod moved this. --- merged: Feb 4, 2011 11:17 AM --- Updated! v0.3 fixes CPU calculation, adds version and args information, and adds some preliminary syntax highlighting.
Suggestions: 1. Making a new window for "plugins" so u can see whats loaded, just like the window for players, CPU usage and command window, and if possible, remove the loading spam when starting the server (so they only show up in the plugin(s) loaded) 2. maybee add an option so that you can customize the look on it? (background, text colours, etc. etc) remember its just suggestions
Plugin list is a nice idea. By 'loading spam' do you mean the plugin load messages? I don't think removing those is a good idea; it's important to see that info in some cases to make sure things were loaded properly. Not all plugins use the same format for their startup/load text, and that's the only time the version # is reported for most plugins. The GUI is meant to make certain management tasks easier; not obscure information. Probably at some point; there's some stuff I'd like to figure out with syntax highlighting first.
Updated! v0.4 adds a context menu (right-click) the player list with: Kick, Ban, Op, DeOp, and Get IP.
Very nice, but is it customizable? I'd like to make the text smaller Also, I don't think the buttons/icons (for the GUI) make sense. Simple grey ones will do!
I like a dash of color in my GUIs. It's not customizable yet, but it's only in its infancy. Some kind of customization for the console itself is very likely.
getting error 'unable to find jar file crafty.jar' i did put .jar and .bat to the directory what should i do to make it work??
Fair enough, it's your plugin Great job, it'd be great if in the future it can become more advanced, like MCadmin, and configure the server within the program. But just so that I shut up I might just figure out how to edit the images D:
No harm no foul. I'm just prioritizing the basics right now. I'm not familiar with MCadmin. What specifically would you like to see supported in Crafty?
What happens if you open a command prompt (make sure the path is pointing to the folder with crafty.jar in it) and enter: java -jar crafty.jar If you get the same error, you likely have a Java misconfiguration of some kind.