Godot4 array api has changed a lot, and the meaning of end param in slice method has changed, which is the inclusive index previously and now is the exclusive index, same as the original javascript lib.
In this case, line 295-296 should be
triangles = _triangles.slice(0, triangles_len)
halfedges = _halfedges.slice(0, triangles_len)
otherwise you will got a non-3-multiply length array .triangles, which is invild.
Godot4 array api has changed a lot, and the meaning of
endparam inslicemethod has changed, which is the inclusive index previously and now is the exclusive index, same as the original javascript lib.In this case, line 295-296 should be
otherwise you will got a non-3-multiply length array
.triangles, which is invild.