Beispiel #1
0
bool _Pool::deallocatePage(_Page* page) {
    _Chunk* chunk = getContainingChunk(page);
    if (!chunk)
        return false;

    bool deallocated = chunk->deallocatePage(page);
    if (!deallocated)
        return false;
    if (chunk->isEmpty()) {
        chunk->dispose();
        chunks->remove(chunk);
    }
    return true; }
Beispiel #2
0
v3s16 EmergeManager::getContainingChunk(v3s16 blockpos)
{
	return getContainingChunk(blockpos, params.chunksize);
}