Fix wrong condition
This commit is contained in:
parent
b21ca8e0f7
commit
40ee3697e1
@ -1467,7 +1467,7 @@ void VoxelTerrain::apply_data_block_response(VoxelEngine::BlockDataOutput &ob) {
|
||||
}*/
|
||||
|
||||
// Create or update block data
|
||||
const bool was_not_loaded = _data->has_block(block_pos, 0);
|
||||
const bool was_not_loaded = !_data->has_block(block_pos, 0);
|
||||
VoxelDataBlock *block = _data->try_set_block_buffer(
|
||||
block_pos, 0, ob.voxels, ob.type == VoxelEngine::BlockDataOutput::TYPE_LOADED, true);
|
||||
if (block == nullptr) {
|
||||
|
@ -10,7 +10,7 @@ namespace zylann {
|
||||
class RefCount {
|
||||
public:
|
||||
RefCount() {}
|
||||
RefCount(unsigned int initial_count): _count(initial_count) {}
|
||||
RefCount(unsigned int initial_count) : _count(initial_count) {}
|
||||
|
||||
inline void add() {
|
||||
++_count;
|
||||
|
Loading…
x
Reference in New Issue
Block a user