Sinespace Client
2023.2.17543
Client-side scripting for Sinespace
|
Public Member Functions | |
float | GetHeight (float x, float y) |
Get an interpolated height at a point x,y. More... | |
float | GetSteepness (float x, float y) |
Get the gradient of the terrain at point (x,y). More... | |
float[,] | GetHeights () |
Get an array of heightmap samples. More... | |
void | SetHeights (float[,] data) |
Set the resolution of the detail map. More... | |
void | SetHeight (int x, int y, float value) |
Set value to height of [x,y] More... | |
SVector | GetNormal (float x, float y) |
Get an interpolated normal at a given location. More... | |
SVector | GetSlope (float x, float y) |
Get a normalized and interpolated normal at a given location. More... | |
SVector | GetContour (float x, float y) |
Get a contour of interpolated normal at a given location. More... | |
Properties | |
bool | Enabled [get, set] |
Whether the terrain component is Enabled. More... | |
Properties inherited from ScriptClassComponent< Terrain > | |
SGameObject | GameObject [get] |
Return the GameObject which component added. More... | |
SVector SineSpace.Scripting.Components.STerrain.GetContour | ( | float | x, |
float | y | ||
) |
Get a contour of interpolated normal at a given location.
x | The x offset to read from. |
y | The y offset to read from. |
float SineSpace.Scripting.Components.STerrain.GetHeight | ( | float | x, |
float | y | ||
) |
Get an interpolated height at a point x,y.
x | The x offset to read from. |
y | The y offset to read from. |
float [,] SineSpace.Scripting.Components.STerrain.GetHeights | ( | ) |
Get an array of heightmap samples.
SVector SineSpace.Scripting.Components.STerrain.GetNormal | ( | float | x, |
float | y | ||
) |
Get an interpolated normal at a given location.
x | The x offset to read from. |
y | The y offset to read from. |
SVector SineSpace.Scripting.Components.STerrain.GetSlope | ( | float | x, |
float | y | ||
) |
Get a normalized and interpolated normal at a given location.
x | The x offset to read from. |
y | The y offset to read from. |
float SineSpace.Scripting.Components.STerrain.GetSteepness | ( | float | x, |
float | y | ||
) |
Get the gradient of the terrain at point (x,y).
x | The x offset to read from. |
y | The y offset to read from. |
void SineSpace.Scripting.Components.STerrain.SetHeight | ( | int | x, |
int | y, | ||
float | value | ||
) |
Set value to height of [x,y]
x | The x offset to read from |
y | The y offset to read from |
value | the value set |
void SineSpace.Scripting.Components.STerrain.SetHeights | ( | float | data[,] | ) |
Set the resolution of the detail map.
|
getset |
Whether the terrain component is Enabled.