:
if [ `logname` != root ]
then
	[ "$1" != "-q" ] && echo "$0: can only be run by root"
	exit 1
fi
if [ ! -x /usr/games/lib/generate ] 
then
	[ "$1" != "-q" ] && echo "$0: can't find generate program"
	exit 1
fi
if [ "$1" != "-q" ]
then
	echo "$0: do you really want to wipe out the MUD? \c"; read aaa
	[ $aaa = y -o $aaa = Y ] || echo "$0: terminated" || exit 1
fi
/usr/games/lib/generate reset /usr/games/lib/amud/reset.txt /usr/games/lib/amud/reset_data
/usr/games/lib/generate world /usr/games/lib/amud/world_file
/usr/games/lib/generate uaf /usr/games/lib/amud/uaf.rand
/usr/games/lib/generate userfile /usr/games/lib/amud/user_file
[ "$1" != "-q" ] && echo "$0: MUD reset and wipeout complete"
exit 0
