/****************************************************************************
 *    $Id:    plugin_ejl_listmaps.sma      v1.0 02/13/02 $ - October 26, 2002 
 *     Originally  $Id: plugin_listmaps.sma,v 1.0 05/04/01 PetitMorte(?) $
 *	 Re-written for easier use by Eric Lidman      ejlmozart@hotmail.com
 *	 Upgrade: http://lidmanmusic.com/cs/plugins.html
 *
 *    Fixed: 10/26/02  Mistake in code that reported the same map twice.
 *
 *    Please note that file_access_read must be changed to 1 in the adminmod.cfg  
 *
 *	This plugin allows users to search thru all the maps on your server.
 *	 You will need to create a file called "tmaps.txt" and place it in your
 *	 Mod directory.  This file should contain a list of all the maps you
 *	 have available to play.  The easiest way to create this file is to copy
 *	 your maps.ini file, rename the copy to tmaps.txt. Add 8 blank lines to
 *	 the end of tmaps.txt and save it in your mod directory.
 *
 *    Commands:
 *     admin_maplist <number>   returns a list of 9 maps starting from <number> 
 *     admin_search <target>   returns up to 9 maps containing the search target
 *     admin_map_help   instructs on the use of ejl_listmaps
 *
 *    Maps are listed in the chat to the player who requests them. If the chat
 *     is moving too fast. The player can still see the list in the console as
 *     the chat moves up.  
 *
 *    All the above commands will work as if working under plugin_dio_lazy 
 *     (with less typing), just remove the "admin_"  from them. Also, the
 *     commands can be issued in that shortcut form from the chat mode.
 *     For example:     say: maplist <number>
 *   
 *    In the original plugin_listmaps, if a search returned too many results,
 *     it flooded and crashed the server. Eric's server had 455 maps on it
 *     available for play. Eric fixed this by limitimg the number of search
 *     results returned to 9. 
 *
 *    Eric Lidman thanks the above original writer of plugin_listmaps
 *     for the essential guts of the code, Luke Sanky for code from
 *     plugin_sank_ai, and dio for code from plugin_dio_lazy.
 *
 ***************************************************************************/