12 #include "../clib/fileutil.h" 13 #include "../clib/logfacility.h" 14 #include "../clib/stlutil.h" 15 #include "../plib/systemstate.h" 35 std::string filepart =
"map" + std::to_string( mapid ) +
"LegacyMUL.uop";
39 <<
". Searching for old map[N].mul files.\n";
50 FILE* fp = fopen( filename.c_str(),
"rb" );
53 ERROR_PRINT <<
"Unable to open UO datafile: " << filename <<
"\n" 54 <<
"POL.CFG specifies UODataFileRoot as '" 56 <<
" The following files must be present in that directory:\n" 57 <<
" map0.mul OR map0LegacyMUL.uop\n" 63 <<
" verdata.mul (optional - only if present on client install)\n";
65 throw std::runtime_error(
"Error opening UO datafile." );
77 ERROR_PRINT <<
"Unable to find UO file: " << filename
78 <<
", reading " + name +
"0.mul instead.\n";
79 filename = name +
"0.mul";
void open_uo_data_files(void)
char * binary(unsigned int val, int nbits)
bool open_uopmap_file(const int mapid)
FILE * open_map_file(std::string name, int map_id)
std::string tostring(const Bscript::BTokenType &v)
unsigned short uo_map_height
FILE * open_uo_file(const std::string &filename_part)
unsigned short uo_map_width
std::string uo_datafile_root
bool FileExists(const char *filename)