Skip to main content

Vertex

A vertex object

warning

This page is a WIP. It contains all the information in Figura's documentation but we're working on adding more helpful descriptions.

For this entire page assume:

local myVertex = models:getVertices("myTexture")[1]

setPos()

Aliases: pos()

Sets the position vector of this vertex

setPos(pos)

Parameters:

NameTypeDescriptionDefault
posVector3--

Returns:

TypeDescription
VertexReturns self for chaining

Example:

myVertex:setPos(1, 2, 3)

getPos()

Returns the position vector of this vertex

getPos()

Returns:

TypeDescription
Vector3-

Example:

myVertex:getPos()

setUV()

Aliases: uv()

Sets the UV vector of this vertex

setUV(UV)

Parameters:

NameTypeDescriptionDefault
UVVector2--

Returns:

TypeDescription
VertexReturns self for chaining

Example:

myVertex:setUV(8, 8)

getUV()

Returns the UV vector of this vertex

getUV()

Returns:

TypeDescription
Vector2-

Example:

myVertex:getUV()

setNormal()

Aliases: normal()

Sets the normal vector of this vertex

setNormal(normal)

Parameters:

NameTypeDescriptionDefault
normalVector3--

**Returns:**66

TypeDescription
VertexReturns self for chaining

Example:

myVertex:setNormal(0, 1, 0)

getNormal()

Returns the normal vector of this vertex

getNormal()

Returns:

TypeDescription
Vector3-

Example:

myVertex:getNormal()