summaryrefslogtreecommitdiffstats
path: root/src/SetChunkData.h (unfollow)
Commit message (Collapse)AuthorFilesLines
2018-07-23Optimise chunk set (#4260)peterbell101-19/+6
Closes #1244 Initially I was just going to add the cChunkData to cSetChunkData but profiling revealed that the copying wasn't even the biggest slowdown. Much more time was being spent in cChunk::CreateBlockEntities and cChunk::WakeUpSimulators than was in memcpy so I've made those significantly faster as well. Optimisations performed: * cSetChunkData now stores blocks in a cChunkData object * cChunkData objects can now perform moves even if they are using different pools * cChunk::CreateBlockEntities now iterates in the correct order and only over present chunk sections * Similarly for cChunk::WakeUpSimulators * cSetChunkData::CalculateHeightMap now shortcuts to the highest present chunk section before checking blocks directly
2017-08-07Changed entity ownership model to use smart pointersTiger Wang1-8/+0
2017-07-21Remove smart pointer macrospeterbell101-1/+1
2017-05-22Store cChunk::m_BlockEntities in a map (#3717)peterbell101-4/+4
* Store block entities in a map from block index * Cleanup ForEachBlockEntity * Cleanup DoWithBlockEntityAt
2016-02-05Bulk clearing of whitespaceLogicParrot1-16/+16
2015-04-27cSetChunkData constructor explicitly requires std::move() instead ofWoazboat1-4/+6
unsafely stealing data
2014-10-23En masse NULL -> nullptr replaceTiger Wang1-1/+1
2014-10-20En masse NULL -> nullptr replaceTiger Wang1-1/+1
2014-08-29Rewritten block entity loading.Mattes D1-0/+3
Block entities are now loaded based on the blocktype at the coords they specify; before loading, their type ("id" NBT tag) is checked. The chunk now expects that all block entities given to it via cChunk::SetAllData() have their valid blocktype; asserts if they don't. Fixes #1354.
2014-07-24Added a queue for setting chunk data.madmaxoft1-0/+120
Fixes #1196.