diff options
author | Perttu Ahola <celeron55@gmail.com> | 2012-03-28 23:11:28 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-03-28 23:11:28 +0300 |
commit | 418041d9067319431e4b6301851da117d2f4075b (patch) | |
tree | 47729d4f5d4bc5c0aeaaa3dbef2a28c360393e0f /src/server.cpp | |
parent | a3a400992e987307d743028b60237ef0bcae533a (diff) | |
download | minetest-418041d9067319431e4b6301851da117d2f4075b.tar.gz minetest-418041d9067319431e4b6301851da117d2f4075b.tar.bz2 minetest-418041d9067319431e4b6301851da117d2f4075b.zip |
Fix on_generate minp/maxp (was broken due to chunkymapgen)
Diffstat (limited to 'src/server.cpp')
-rw-r--r-- | src/server.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/server.cpp b/src/server.cpp index d3c1218e7..ff250596d 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -280,8 +280,9 @@ void * EmergeThread::Thread() Do some post-generate stuff */ - v3s16 minp = block->getPos()*MAP_BLOCKSIZE; - v3s16 maxp = minp + v3s16(1,1,1)*(MAP_BLOCKSIZE-1); + v3s16 minp = data.blockpos_min*MAP_BLOCKSIZE; + v3s16 maxp = data.blockpos_max*MAP_BLOCKSIZE + + v3s16(1,1,1)*(MAP_BLOCKSIZE-1); scriptapi_environment_on_generated(m_server->m_lua, minp, maxp, mapgen::get_blockseed(data.seed, minp)); |