NOTE: October 22, 2003. I've been seeing failed connection attempts on the custom client port for several months now. I don't know if that is people trying to use the Java client, or whether people are trying to use other MUD clients to connect to that port. Only the Java client, and a Mac OS/X client by Marn, can use that port. Others should use one of the telnet ports (16666 for Unix-style telnet clients, 16668 for dumb telnet-like programs that don't do any of the protocol, or 16669 which ought to work reasonably with clients designed for LPMuds). Since the Java client is quite old now, its possible that it isn't working properly with newer Java implementations. Let me know if that is happening to you, and I'll add a note here.
There are several different Java interpreters for most systems. Some, if not all (I just don't know) Microsoft Windows systems come with a Java interpreter installed as part of Internet Explorer. The official site for Java material is here. The CGMud client requires only Java 1.1 technology - it does not require or use newer 1.2 or 1.3 features. Sun's JDK (Java Developers Kit) page for Java 1.1 is here. This page contains download links for versions for Solaris, Linux and Windows. A page full of information on other ports is here.
#! /bin/sh cd /home/cg/MUD/Client CLASSPATH=cgmud.jar java -DImageDir=Images cgmud.main.Main -f mud.graysage.com 16667You can grab this and put it into a file called "cgmud" in your home directory. Then, just change the "/home/cg/MUD/Client" to be a path to where you have put the CGMud client stuff, and you should be ready to go, by simply typing "cgmud" into a shell. For example, if you have put the CGMud client files (the ".jar" file and the directory of images) into a directory called "cgmud" in your home directory, and your home directory is "/nfs/users/fred", then you would just need to change the "cd" line to be:
Like on Linux, you can setup the CGMud client to run from a shell (command window or CLI). Those that wish to do that should know enough to be able to do it themselves, using the information in the Linux section. If you normally use the desktop you should be able to install an icon on the desktop that will startup the CGMud client. The procedure is something like this (I don't have a Windows machine to try this on, so if this is wrong or misleading, someone please correct me):
java.exe -cp cgmud.jar -DImageDir=Images cgmud.main.Main mud.graysage.com 16667This line will be the "target" of the shortcut.
You should now be able to activate (normally double-click) the new icon to run the CGMud client. You should likely rename the shortcut to be something like "CGMud".
In general, the shell usage line for the Java interpreter is like:
java -Dvar=value ... classpath-to-main parameters ...i.e. some settings for Java environment variables, followed by the name of the 'main' function to run, relative to the CLASSPATH, and then followed by any parameters the specific program needs. The Windows form gets the "CLASSPATH" from the "-cp" parameter, and the Linux form gets it from a shell environment variable. In the case of the CGMud client, you are required to specifiy the name of the machine to connect to, and the port on that machine to connect to.
|On startup, the CGMud client should present a window something like this: =>||.|
Note that clicking *in* the text output window puts Java's idea of that window's cursor at the point at which you click. From then on, Java will want to keep that point visible, and so the window will stop scrolling. Manually scroll to the bottom and click at the end to unfreeze it. Note also that, depending on your system settings, etc., it may be necessary to hit your "Num Lock" key to get the numeric keypad to work with the CGMud client.
Asside from the required server name and port number, there are some flags that can be given to the CGMud client. These must be given before the server name and port number.
-fflag controls how the client attempts to control the mouse focus. When you are typing characters into the text input box at the bottom of the window, that input box must be the current mouse focus. That can be done by clicking in the box. However, if you use the mouse a lot for moving, by clicking in the map window or on mouse buttons, the focus will move elsewhere. I find that very annoying. So, Don and I attempted to make the client always put the focus back on the text input box after anything else happened. With some systems and window managers, that works fine. On others, that code in the client fights with the mouse focussing that the window manager or system wants to do, making the client very sluggish and hard to work with. So, the
-fflag was introduced to control the CGMud client's mouse focus activities. By default, the client will not try to keep the focus on the text input box, so the user has to do that manually. If you give the
-fflag, the client will attempt to do the focus control. This may or may not work for you.
-2flag tells the client to build the initial login interface, discarding the first and using the second. This is used to work around some problems (possibly due to lack of full understanding of and conformance to the details of Java GUI programming) with the display of the initial login window. If the initial login display doesn't appear to look right (e.g. the text output panel is too big or too small), try using this flag.
-sflag, which requires a number to be given immediately after the 's', sets the size of the font used in the CGMud client. The default size is 7. Larger numbers make a larger font. Experiment to see which works best for you and your system.
-tis also accepted, but it is not really of any use - it controls the height of the text output window, but only for the initial login dialog.
Some quick, short notes for those who don't want to read more:
|cgmud.jar||This file is a "jar" (Java ARchive) file. It contains the Java bytecode for the CGMud client. You need to download this to your local computer. You should not change the name of the file, and you should likely put it in a directory of its own, typically called "cgmud". If you are using Netscape as your browser, do *not* simply click on the link to the "jar" - Netscape will try to run it as a Java Applet (which is the form of Java that browsers use), and will fail. Instead, hold down a shift key, and then click on the link - Netscape will ask you where you want to put the file, and will not try to run it. I can't test with Internet Explorer, but I'm told it doesn't do that, although it may depend on system and user settings.|
|Images.zip||This ZIP file contains the images that the CGMud client will attempt to use, as directed by the scenario running on the server. If you don't have the images, or the CGMud client can't find them, the scenario will generate alternate graphics where needed, or simply not show anything. Simply download this file, and unzip it in the directory you created for the CGMud client (typically called "cgmud"). The unzip will create a directory called "Images", and put the images there. The graphics here are very poor - I welcome improved versions. Basically, the graphics were originally done (some by me, a non-artist programmer, and some by others) for the old Amiga system, and so they are only 160x100 in resolution, and use only 32 colours. The Java CGMud client uses 320x256 (or 320x200, depending on the panel) for graphics, and has 256 colours available, so much better images are possible.|
|ClientSource.zip||This zip file contains the Java sources to the CGMud client. It is not used when playing the game. The sources are useful only to those who want to see how the client works, or who want to try to improve the client.|
|AmigaClient.zip||This zip file contains the source to the old Amiga client, written in my Draco programming language. Only extreme geeks will want to look at this, although, buried in it, is information on how to add more functionality to the Java client.|