Skip to main content

MarchingCubesPlugin.GeneratedMesh

A class in Root.Township, Alta.Caves.

Mesh made by the marching cubes plugin for one map chunk. Holds either an existing mesh or raw vertices and indices to build one from later.

Constructors​

MemberWhat it is
GeneratedMesh(Mesh existing)Creates a MarchingCubesPlugin.GeneratedMesh from vertices and indices.
GeneratedMesh(List<Vector3> vertices, int[] indices)Creates a MarchingCubesPlugin.GeneratedMesh from vertices and indices.

Fields​

3 private and internal fields
MemberWhat it is
private int[] indicesTriangle indices for the mesh to build.
private Mesh meshThe mesh, once it exists. Built meshes are marked not to save.
private List<Vector3> verticesVertices for the mesh to build.

Methods​

MemberWhat it is
Mesh GetOrCreateMesh(CaveLayerManager manager, int layer, out bool wasGenerated)Returns the mesh, building it from the stored vertices and indices the first time. wasGenerated says if it was just built.

Used in​

Members of other types that take, return or hold a GeneratedMesh: