Vital.sandbox
GFXFog

gfx.fog.set_density

Client

The density to be set for the fog post-processing effect


Syntax

local status = gfx.fog.set_density(value)

Parameters

TypeNameDescription
floatvalueDensity value to be applied
Controls the overall thickness of the fog. Higher values produce denser, more opaque fog that obscures the scene more quickly with distance

Returns

TypeNameDescription
boolstatustrue on successful execution, or false on failure

Examples

Set a thick dense fog
--Set a thick dense fog
gfx.fog.set_density(0.05)

On this page