Class TTerrainCasScript

Unit

Declaration

type TTerrainCasScript = class(TCastleTerrainData)

Description

Warning: this symbol is deprecated: using CastleScript to define terrain is deprecated due to low usage

Terrain (height for each X, Y) data calculated from CastleScript expression. At construction, pass FunctionExpression, that is CastleScript language expression calculating height based on X, Y.

See https://castle-engine.io/castle_script.php for CastleScript syntax. Try e.g. function like

- sin(x) + sin(y)

- Sum sinusoides of various frequencies and amplitudes:

(sin(x) + sin(x*2) / 2 + sin(x*4) / 4)  *
(sin(y) + sin(y*2) / 2 + sin(y*4) / 4)

Hierarchy

Overview

Methods

Public constructor Create(const FunctionExpression: string); reintroduce;
Public destructor Destroy; override;
Public function Height(const Coord, TexCoord: TVector2): Single; override;

Description

Methods

Public constructor Create(const FunctionExpression: string); reintroduce;
 
Public destructor Destroy; override;
 
Public function Height(const Coord, TexCoord: TVector2): Single; override;
 

Generated by PasDoc 0.16.0.