From d57753cd6873ac279f8de163393db2c1cc6a2a00 Mon Sep 17 00:00:00 2001 From: faketruth Date: Tue, 27 Dec 2011 22:57:33 +0000 Subject: Users file was pretty messed up with mixed unix and windows line endings. The ini failed to parse correctly under cygwin. 'Fixed' a 'bug' where MCServer would seemingly endlessly calculate lighting for an entire world (and then crash), when this entire world has 'wrong' lighting. This happens when running a converted map from Vanilla. Fixed this by only allowing a maximum of 50 chunks to recalculate their lighting per tick. Fixed a small coding error in cChunkMap where it would check PakVersion twice, instead of also ChunkVersion. DeNotch converter does not need the VS2010 runtime thingies anymore git-svn-id: http://mc-server.googlecode.com/svn/trunk@138 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cChunkMap.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/cChunkMap.cpp') diff --git a/source/cChunkMap.cpp b/source/cChunkMap.cpp index 2f8339176..90b3258e7 100644 --- a/source/cChunkMap.cpp +++ b/source/cChunkMap.cpp @@ -653,7 +653,7 @@ cChunkMap::cChunkLayer* cChunkMap::LoadLayer(int a_LayerX, int a_LayerZ ) if( fread( &PakVersion, sizeof(PakVersion), 1, f) != 1 ) { LOGERROR("ERROR 1 READING FROM FILE %s", SourceFile); fclose(f); return false; } if( PakVersion != 1 ) { LOGERROR("WRONG PAK VERSION!"); fclose(f); return 0; } if( fread( &ChunkVersion, sizeof(ChunkVersion), 1, f) != 1 ) { LOGERROR("ERROR 2 READING FROM FILE %s", SourceFile); fclose(f); return false; } - if( PakVersion != 1 ) { LOGERROR("WRONG CHUNK VERSION!"); fclose(f); return 0; } + if( ChunkVersion != 1 ) { LOGERROR("WRONG CHUNK VERSION!"); fclose(f); return 0; } short NumChunks = 0; if( fread( &NumChunks, sizeof(NumChunks), 1, f) != 1 ) { LOGERROR("ERROR 3 READING FROM FILE %s", SourceFile); fclose(f); return false; } -- cgit v1.2.3