Moved some code to the right place.

This commit is contained in:
The Wobbler 2024-08-29 15:27:02 +02:00
parent 5a9224bdae
commit ec8ba98b56

View file

@ -12,18 +12,18 @@ Thanks to this "compression", there are no zero values on places where there is
class Node:
def __init__(self):
def __init__(self, data=None):
self.children = [None] * 8
self.leaf = True
self.data = data
class SparseVoxelOctree:
def __init__(self, data=None):
def __init__(self):
self.root_node = Node()
self.origin = (0, 0, 0)
self.data = data
def _get_child_index(self, x, y, z, size):
index = 0