Graphical compass for MUSHClient

by Arundor

Back to Mechanic's Corner.

Arundor2006-05-05 06:17:29
I used to use the Nexus client, and fell in love with the graphical compass and health/mana/etc gauges. So when I switched to MUSHClient, I hacked together a GUI.

To my knowledge, a free Lusternia GUI for MUSHClient isn't already available, so I decided to share.

Screenshot: http://magma.ca/~carl2/arundor/compass_screen.jpg

If you want it, get the attachment.

It works with CONFIG PROMPT STATS and CONFIG PROMPT ALL prompt styles. If you have a different prompt style, you can edit the plugin file and add a new trigger to handle it.


Instructions for use:

1. Unzip to any directory you want.
2. If you don't already have it, download the Java runtime environment. http://www.java.com/en/download/index.jsp
3. In MUSHClient, go to File > Plugins > Add and choose "LusterGUI.xml".
4. To run, use "LusterGUI.bat".
5. To change the colors, edit file "config.txt". It should be fairly easy to figure out.


Some notes:

1. The plugin captures your current health/mana/etc from the prompt, but can only capture your maximum health/etc. when you use SCORE. So, when you first start playing or anytime your maximum health/mana/etc. changes, use SCORE to update the GUI.
2. GLANCEing can screw up the compass. After you glance, either move, LOOK or QL to get the compass working again.
3. Avator's tutorial on creating GUI extras for MUSHClient got me started on this. So, thank you Avator.
4. I didn't make the compass graphics. They are taken from Lusternia's java client, so credit goes to the artist who made that.
5. I'm not that great at coding, so don't yell at me if the scripting is bad. At least it works! smile.gif

LusterGUI end-user version (if you just want to use the GUI, get this one):


Source code:

A note regarding the source code: This is fairly amateur work. Don't try to use it as a model of expert programming or the like. wink.gif
Mirk2006-05-05 20:24:45
THANK YOU!!!!!
um, unfortunatly, it isn't working, and I get this error: Line 154: Elements terminated out of sequence, expected , got (problem in this file)
Arundor2006-05-05 21:26:51
Apologies for that. I guess I should have actually tested it after converting it to plugin format. smile.gif

I updated the file attachment with a fixed version.
Mirk2006-05-05 21:48:57
Stupide question, but how exactly does one get it to work?
Arundor2006-05-05 21:56:21
Based on the error you found, I'm guessing you got as far as adding the plugin to MUSHClient.

From there, just double click the "LusterGUI2.bat" file to run it.

You have to start moving around for the GUI to update. It detects your prompt and the "You see exits leading " lines, so you have to see one of those before the GUI shows anything.
Mirk2006-05-05 21:59:09
well, where exactly is the file I'm supposed to run?
Arundor2006-05-05 22:02:30
"LusterGUI2.bat". It was in the zip file.
Mirk2006-05-05 22:06:11
um, well I don't see it...
Arundor2006-05-05 22:09:56
I've re-downloaded the attachment to make sure it's actually there. Everything seems find to me.

The zip file should contain:

"images2" folder, containing a few image files.
"LusterGUI2.bat"
"LusterGUI2.class"
"LusterGUI2.xml"

Are you able to find any of those?

If it helps, you could also try going by the Windows icons. "LusterGUI2.bat" should have the gear icon.
Mirk2006-05-06 14:08:28
I feel stupid, I was searching for the actual .bat after the thing...
Apparently, my computer didn't feel like putting it in the name. It's supposed to be an ms-dos batch thingy, right?

If that's true, when I open it, it just pops up, types something in really fast, and dissappears...
Unknown2006-05-06 14:42:19
I probably won't use it, but it's good to see graphical things for MUSHclient. Requires some coding skills too.

Thumbsup.
Arundor2006-05-07 01:05:44
QUOTE(Mirk @ May 6 2006, 10:08 AM) 285749

I feel stupid, I was searching for the actual .bat after the thing...
Apparently, my computer didn't feel like putting it in the name. It's supposed to be an ms-dos batch thingy, right?


That's right.

QUOTE

If that's true, when I open it, it just pops up, types something in really fast, and dissappears...


I'm sorry to hear you're having so much trouble.

One possible cause is that you don't have the Java runtime environment. If you're sure you have it, try opening a command prompt in the directory where you unzipped the files, and enter this:

java -classpath . LusterGUI2

It will give the same error as before, but the window won't disappear. Let me know what message it gives, and I'll see if I can help.



Also, a note for any other interested people who have been following the thread. By request, an additional version for people who use CONFIG PROMPT STATS is now available. Check the first post in the thread for details on that.

Also by request, I'll be attempting to create a version where users can edit the colors of the health/mana/etc gauges. If I can get that to work, I'll soonbe uploading a new version with that feature.
Mirk2006-05-07 01:36:56
QUOTE(Arundor @ May 6 2006, 08:05 PM) 285843

That's right.
I'm sorry to hear you're having so much trouble.

One possible cause is that you don't have the Java runtime environment. If you're sure you have it, try opening a command prompt in the directory where you unzipped the files, and enter this:

java -classpath . LusterGUI2

Um...
You're talking to someone who has no idea what the command prompt thingy is, and I'm pretty sure I have java (but don't know for sure).
Would you need the java thing to run the nexus client? (if so, I definatly have it...)
And probably what's going wrong is something I'm doing, and I have to thank you for all the help you've given me so far.
Arundor2006-05-07 02:31:22
The command prompt can be tricky for people without experience using it, so I'll try to make it as easy as I can.

1. Go to Start > Run and enter "cmd".
2. Type in the drive letter on which you unzipped the file.
3. Enter "cd \\" followed by the directory path in which you unzipped the file.
4. Enter this: java -classpath . LusterGUI2

So, for example. Suppose you have your C drive, and on it is a folder called "MyStuff". Inside "MyStuff" is another folder called "Lusternia", and you unzipped the files in there. You would do this:

C:
cd \\mystuff\\lusternia
java -classpath . LusterGUI2

And let me know what the error message says.

I hope I explained that properly. smile.gif
Mirk2006-05-07 23:07:25
IT WORKS!!! THANKS FOR YOUR HELP!!!!!
Arundor2006-05-08 01:57:56
Heh, I wasn't expecting that to fix it, I just thought it would help diagnose the problem.

Still, I'm glad to hear it works now. Hope you like it. smile.gif
Mirk2006-05-08 02:34:47
erm, well, it said I was using an outdated java thingy...
so I downloaded the new one
Arundor2006-05-08 05:59:46
QUOTE(Arundor @ May 6 2006, 09:05 PM) 285843

Also by request, I'll be attempting to create a version where users can edit the colors of the health/mana/etc gauges. If I can get that to work, I'll soonbe uploading a new version with that feature.


Just to let readers know, in case anyone was waiting, this update is done. Get the updated file attachment on the first post of the thread.
Unknown2006-05-18 22:53:38
I'm sorry but I have stupid question: Does this work like the the first interface (I can click on it), or do I still need to input all of my commands on the prompt?
Arundor2006-05-18 23:57:53
You'll still have to enter your commands with the keyboard.