1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

VoxelArea: add_{x,y,z,p} must be static

Fix some documentations issues
Use getNodeNoCheck(v3s16, ...) in some cases instead of getNodeNoCheck(x, y, z, ...)
This commit is contained in:
Loic Blot 2018-03-09 08:49:00 +01:00 committed by Loïc Blot
parent 3b27cf30d9
commit 12d1e4ff04
11 changed files with 72 additions and 61 deletions

View file

@ -1111,7 +1111,7 @@ void blit_back_with_light(ServerMap *map, MMVManip *vm,
for (relpos.Y = a.MinEdge.Y; relpos.Y <= a.MaxEdge.Y; relpos.Y++) {
// Get old and new node
MapNode oldnode = block->getNodeNoCheck(relpos.X, relpos.Y, relpos.Z, &is_valid);
MapNode oldnode = block->getNodeNoCheck(relpos, &is_valid);
const ContentFeatures &oldf = ndef->get(oldnode);
MapNode newnode = vm->getNodeNoExNoEmerge(relpos + offset);
const ContentFeatures &newf = oldnode == newnode ? oldf :
@ -1240,7 +1240,7 @@ void repair_block_light(ServerMap *map, MapBlock *block,
for (relpos.Y = a.MinEdge.Y; relpos.Y <= a.MaxEdge.Y; relpos.Y++) {
// Get node
MapNode node = block->getNodeNoCheck(relpos.X, relpos.Y, relpos.Z, &is_valid);
MapNode node = block->getNodeNoCheck(relpos, &is_valid);
const ContentFeatures &f = ndef->get(node);
// For each light bank
for (size_t b = 0; b < 2; b++) {