1
0

Lighting: Fixed underwater lighting (FS #369)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1444 0a769ca7-a7f5-676a-18bf-c427514a06d6
This commit is contained in:
madmaxoft@gmail.com
2013-05-05 14:48:18 +00:00
parent d303a60e11
commit 1e350218cc
3 changed files with 82 additions and 50 deletions

View File

@@ -29,6 +29,11 @@
/** If defined, the BlockSkyLight values will be copied over to BlockLight upon chunk saving,
thus making skylight visible in Minutor's Lighting mode
*/
// #define DEBUG_SKYLIGHT
/** Maximum number of MCA files that are cached in memory.
Since only the header is actually in the memory, this number can be high, but still, each file means an OS FS handle.
*/
@@ -416,7 +421,11 @@ bool cWSSAnvil::SaveChunkToNBT(const cChunkCoords & a_Chunk, cFastNBTWriter & a_
int SliceSizeNibble = SliceSizeBlock / 2;
const char * BlockTypes = (const char *)(Serializer.m_BlockTypes);
const char * BlockMetas = (const char *)(Serializer.m_BlockMetas);
const char * BlockLight = (const char *)(Serializer.m_BlockLight);
#ifdef DEBUG_SKYLIGHT
const char * BlockLight = (const char *)(Serializer.m_BlockSkyLight);
#else
const char * BlockLight = (const char *)(Serializer.m_BlockLight);
#endif
const char * BlockSkyLight = (const char *)(Serializer.m_BlockSkyLight);
for (int Y = 0; Y < 16; Y++)
{