Skip to content

llGetNumberOfSides

integer llGetNumberOfSides()

Returns the number of faces (or sides) of the prim.

Returns the number of sides of the prim which has the script.

default
{
state_entry()
{
// Set the hovertext to indicate the number of sides
integer numOfSides = llGetNumberOfSides();
llSetText( "I have " + (string)numOfSides + " sides.", <1,1,1>, 1 );
}
}

See the Face documentation for more information about faces and the conditions that control the number of faces a prim will have.