mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
changed node metadata format to better accomodate future needs and problems
This commit is contained in:
parent
042834b09d
commit
389fe31ace
12 changed files with 192 additions and 46 deletions
|
@ -5192,14 +5192,14 @@ void ServerMap::loadBlock(std::string sectordir, std::string blockfile, MapSecto
|
|||
{
|
||||
DSTACK(__FUNCTION_NAME);
|
||||
|
||||
// Block file is map/sectors/xxxxxxxx/xxxx
|
||||
std::string fullpath = m_savedir+"/sectors/"+sectordir+"/"+blockfile;
|
||||
try{
|
||||
|
||||
// Block file is map/sectors/xxxxxxxx/xxxx
|
||||
std::string fullpath = m_savedir+"/sectors/"+sectordir+"/"+blockfile;
|
||||
std::ifstream is(fullpath.c_str(), std::ios_base::binary);
|
||||
if(is.good() == false)
|
||||
throw FileNotGoodException("Cannot open block file");
|
||||
|
||||
|
||||
v3s16 p3d = getBlockPos(sectordir, blockfile);
|
||||
v2s16 p2d(p3d.X, p3d.Z);
|
||||
|
||||
|
@ -5264,6 +5264,8 @@ void ServerMap::loadBlock(std::string sectordir, std::string blockfile, MapSecto
|
|||
"(SerializationError). Ignoring. "
|
||||
"A new one will be generated."
|
||||
<<std::endl;
|
||||
|
||||
// TODO: Backup file; name is in fullpath.
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue