HPL3/Amnesia: Rebirth/Scripting/cTerrain

From Frictional Wiki
< HPL3‎ | Amnesia: Rebirth‎ | Scripting
Revision as of 22:58, 15 November 2020 by Abion47 (talk | contribs) (Created page with "{{ScriptingStub}} Have some helpful descriptions to add to this class? Edit this page and add your insight to the Wiki! ==Fields== cTerrain has no public fields. ==Function...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Have some helpful descriptions to add to this class? Edit this page and add your insight to the Wiki!

Fields

cTerrain has no public fields.

Functions

Return Type Function And Description
void AddDynamicDecal(const tString &in asMaterial, const cVector3f &in avPosition, float afAngle, const cVector2f &in avSize, float afDepth = -1, const cColor &in aColor = 1, const cVector2f &in avMinUV = 0, const cVector2f &in avMaxUV = 1, float afFadeOutTime = -1)
float GetChangePatchLevelDist()
int GetGeometryGridNum()
int GetGeometryPatchSize()
int GetHeightMapSize()
float GetMaterialSpecularPower()
float GetMaxHeight()
void GetStartAndSizeInTextureGrid(const cVector2f &in avStart, const cVector2f &in avSize, cVector2l &out avGridStart, cVector2l &out avGridSize)
int GetTextureGridNum()
int GetTexturePatchSize()
float GetUnitSize()
bool GetWorldPosHeightAndNormal(const cVector3f &in avPosition, float &out afHeight, cVector3f &out avNormal)
void SetChangePatchLevelDist(float afX)
void SetCheapMaterial(const tString &in asCheapMaterial, float afCheapMaterialMul)
void SetGeometryPatchSize(int alX)
void SetMaxHeight(float afX)
void SetTexturePatchSize(int alX)
void SetUnitSize(float afX)

Details

AddDynamicDecal

void AddDynamicDecal(const tString &in asMaterial,
                     const cVector3f &in avPosition,
                     float afAngle,
                     const cVector2f &in avSize,
                     float afDepth = -1,
                     const cColor &in aColor = 1,
                     const cVector2f &in avMinUV = 0,
                     const cVector2f &in avMaxUV = 1,
                     float afFadeOutTime = -1)


Parameters

Returns:

  • void

GetChangePatchLevelDist

float GetChangePatchLevelDist()

Returns:

  • float

GetGeometryGridNum

int GetGeometryGridNum()

Returns:

  • int

GetGeometryPatchSize

int GetGeometryPatchSize()

Returns:

  • int

GetHeightMapSize

int GetHeightMapSize()

Returns:

  • int

GetMaterialSpecularPower

float GetMaterialSpecularPower()

Returns:

  • float

GetMaxHeight

float GetMaxHeight()

Returns:

  • float

GetStartAndSizeInTextureGrid

void GetStartAndSizeInTextureGrid(const cVector2f &in avStart,
                                  const cVector2f &in avSize,
                                  cVector2l &out avGridStart,
                                  cVector2l &out avGridSize)


Parameters

Returns:

  • void

GetTextureGridNum

int GetTextureGridNum()

Returns:

  • int

GetTexturePatchSize

int GetTexturePatchSize()

Returns:

  • int

GetUnitSize

float GetUnitSize()

Returns:

  • float

GetWorldPosHeightAndNormal

bool GetWorldPosHeightAndNormal(const cVector3f &in avPosition,
                                float &out afHeight,
                                cVector3f &out avNormal)


Parameters

Returns:

  • bool

SetChangePatchLevelDist

void SetChangePatchLevelDist(float afX)


Parameters

  • afX (float) —

Returns:

  • void

SetCheapMaterial

void SetCheapMaterial(const tString &in asCheapMaterial,
                      float afCheapMaterialMul)


Parameters

  • asCheapMaterial (tString) —
  • afCheapMaterialMul (float) —

Returns:

  • void

SetGeometryPatchSize

void SetGeometryPatchSize(int alX)


Parameters

  • alX (int) —

Returns:

  • void

SetMaxHeight

void SetMaxHeight(float afX)


Parameters

  • afX (float) —

Returns:

  • void

SetTexturePatchSize

void SetTexturePatchSize(int alX)


Parameters

  • alX (int) —

Returns:

  • void

SetUnitSize

void SetUnitSize(float afX)


Parameters

  • afX (float) —

Returns:

  • void

References

See all references...