Add a log message to SEnv and make it load objects if there are < 51 of them, to load blocks that were limited to 50

master
Perttu Ahola 2011-10-17 19:44:28 +03:00
parent 93f4d2b3f1
commit 9a62a909bc
1 changed files with 11 additions and 1 deletions

View File

@ -888,6 +888,16 @@ void ServerEnvironment::step(float dtime)
continue;
active_object_count_wider +=
block->m_static_objects.m_active.size();
if(block->m_static_objects.m_stored.size() != 0){
errorstream<<"ServerEnvironment::step(): "
<<PP(block->getPos())<<" contains "
<<block->m_static_objects.m_stored.size()
<<" stored objects; "
<<"when spawning objects, when counting active "
<<"objects in wide area. relative position: "
<<"("<<x<<","<<y<<","<<z<<")"<<std::endl;
}
}
v3s16 p0;
@ -1507,7 +1517,7 @@ void ServerEnvironment::activateObjects(MapBlock *block)
<<"activating objects of block "<<PP(block->getPos())
<<" ("<<block->m_static_objects.m_stored.size()
<<" objects)"<<std::endl;
bool large_amount = (block->m_static_objects.m_stored.size() >= 50);
bool large_amount = (block->m_static_objects.m_stored.size() >= 51);
if(large_amount){
errorstream<<"suspiciously large amount of objects detected: "
<<block->m_static_objects.m_stored.size()<<" in "