Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void ParsMapFiles()
- {
- char fn[512];
- //char id_filename[64];
- char id[10];
- for (unsigned int i=0; i<map_count; ++i)
- {
- sprintf(id,"%03u",map_ids[i].id);
- sprintf(fn,"World\\Maps\\%s\\%s.wdt", map_ids[i].name, map_ids[i].name);
- WDTFile WDT(fn,map_ids[i].name);
- if(WDT.init(id, map_ids[i].id))
- {
- // ################ Crash goes at this part here #################
- printf("Processing Map %u\n[", map_ids[i].id);
- for (int x=0; x<64; ++x)
- {
- for (int y=0; y<64; ++y)
- {
- if (ADTFile *ADT = WDT.GetMap(x,y))
- {
- //sprintf(id_filename,"%02u %02u %03u",x,y,map_ids[i].id);//!!!!!!!!!
- ADT->init(map_ids[i].id, x, y);
- delete ADT;
- }
- }
- printf("#");
- fflush(stdout);
- }
- printf("]\n");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement