Roblox Wiki
Roblox Wiki
38,932
pages

The DynamicMesh class, added in 582 (June 2023), inherits from DataModelMesh (originally from Light blank iconDark blank iconFileMesh). It was removed in version 602 (November 2023), replaced by EditableMesh light iconEditableMesh dark iconEditableMesh.

Properties

MeshVersion: int

  • HiddenThis property is not shown in the object browser and properties window.
This class member is missing documentation. Create or add to its subpage at Class:DynamicMesh/MeshVersion.
  • Category: Appearance.
  • Write security: NotAccessibleSecurity.
  • Serialization: can save and load.
  • Thread safety: read safe

Methods

AddTriangle(vertexId0: int, vertexId1: int, vertexId2: int): int

Parameters
NameType
vertexId0int
vertexId1int
vertexId2int
  • Thread safety: unsafe

AddVertex(p: Vector3): int

Parameters
NameType
pVector3
  • Thread safety: unsafe

CreateMeshPartAsync(collisionFidelity: CollisionFidelity): MeshPart

  • YieldsThis function can yield the script it is used in.
Parameters
NameType
collisionFidelityCollisionFidelity
  • Thread safety: unsafe

FindClosestPointOnSurface(point: Vector3): Tuple

Parameters
NameType
pointVector3
  • Thread safety: unsafe

FindClosestVertex(toThisPoint: Vector3): int

Parameters
NameType
toThisPointVector3
  • Thread safety: unsafe

FindVerticesWithinSphere(center: Vector3, radius: float): Array

Parameters
NameType
centerVector3
radiusfloat
  • Thread safety: unsafe

GetAdjacentTriangles(triangleId: int): Array

Parameters
NameType
triangleIdint
  • Thread safety: unsafe

GetAdjacentVertices(vertexId: int): Array

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetPosition(vertexId: int): Vector3

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetTriangleVertices(triangleId: int): Tuple

Parameters
NameType
triangleIdint
  • Thread safety: unsafe

GetTriangles(): Array

This class member is missing documentation. Create or add to its subpage at Class:DynamicMesh/GetTriangles.
  • Thread safety: unsafe

GetUV(vertexId: int): Vector2

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetVertexColor(vertexId: int): Color3

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetVertexColorAlpha(vertexId: int): float

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetVertexNormal(vertexId: int): Vector3

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

GetVertices(): Array

This class member is missing documentation. Create or add to its subpage at Class:DynamicMesh/GetVertices.
  • Thread safety: unsafe

Raycast(origin: Vector3, direction: Vector3): Tuple

Parameters
NameType
originVector3
directionVector3
  • Thread safety: unsafe

RemoveTriangle(triangleId: int): null

Parameters
NameType
triangleIdint
  • Thread safety: unsafe

RemoveVertex(vertexId: int): null

Parameters
NameType
vertexIdint
  • Thread safety: unsafe

SetPosition(vertexId: int, p: Vector3): null

Parameters
NameType
vertexIdint
pVector3
  • Thread safety: unsafe

SetUV(vertexId: int, uv: Vector2): null

Parameters
NameType
vertexIdint
uvVector2
  • Thread safety: unsafe

SetVertexColor(vertexId: int, color: Color3): null

Parameters
NameType
vertexIdint
colorColor3
  • Thread safety: unsafe

SetVertexColorAlpha(vertexId: int, alpha: float): null

Parameters
NameType
vertexIdint
alphafloat
  • Thread safety: unsafe

SetVertexNormal(vertexId: int, vnormal: Vector3): null

Parameters
NameType
vertexIdint
vnormalVector3
  • Thread safety: unsafe

Removed members

External links[]