ACTMUD version 1.0

A MUD example built using ACT


This is a fairy simple example on how to use the ACT ORB. It is intended to be a MUD application in the end (Multi User Dimension) but currently is more of a chat application. The ACT MUD contains two executable classes, one for the server and one for the client.

Compiling ACTMUD

DISCIPLE ACT comes with all the classes already compiled. In case you want to rebuild ACTMUD, follow the instructions on "How to Get It". But just in case you want to recompile only the ACT MUD example there is a way to that. Under UNIX systems simply launch "makeall" by typing

What happens is the following: first the IDL (Interface Definition Language) is used to compile the file 'Mud.idl' describing the public objects. Next, the hand-written classes are compiled. Finally the generated classes are compiled.

Don't forget, it is very important you set the DISCIPLE variable to the directory where disciple is installed (see the "How to Get It" section).

Launching the Server

The server is launched by typing

example:

The server creates a file named 'ior.txt' which has to be in the same directory where the client is launched.

Launching the client

Upon launching the client you should first copy the text file 'ior.txt' which the server creates. This file tells the client about the location of the server, and is necessary as ACT ORB does not currently have a naming service. However, if you launch both the client and the server classes from the same directory copying the 'ior.txt' file won't be necessary anymore. Notice that this file is a plain text file and can be safely sent over email.

After copying the file, the client can be launched by typing

Facts

The server is multithreaded, using the thread per request policy. The client does not need to know where the server is located. The IIOP protocol is implicitly used, since the ACT ORB "speaks" IIOP natively.