1stMUD4.0/bin/
1stMUD4.0/doc/MPDocs/
1stMUD4.0/player/
1stMUD4.0/win32/
1stMUD4.0/win32/rom/
#!/bin/csh
# Written by Furey.
# With additions from Tony and Alander.

# Set the port number.
set port = 9000
if ( "$1" != "" ) set port="$1"

set shutdown = ../data/shutdown.txt

# Change to area directory.
if ( ! -d ../area ) then
	echo "Area directory not found!"
	exit 1
endif

# Set limits.
if ( -e shutdown.txt ) rm -f shutdown.txt

limit core unlimited

while ( 1 )

    # Run rom.
    ../bin/rom $port >&! /dev/null


    # Restart, giving old connections a chance to die.
    if ( -e ../data/shutdown.txt ) then
	rm -f ../data/shutdown.txt
	exit 0
    endif
    sleep 10
end