Small World Engine API Reference - v0.46.1
    Preparing search index...

    Interface PointLightOptions

    Configuration options for point light.

    interface PointLightOptions {
        castShadow?: boolean;
        color?: Color;
        decay?: number;
        distance?: number;
        intensity?: number;
        name?: string;
        shadowBias?: number;
        shadowNormalBias?: number;
        shadowResolution?: number;
    }

    Hierarchy (View Summary)

    Index

    Properties

    castShadow?: boolean

    Whether the light casts shadows. Defaults to false.

    color?: Color

    The color of the light. Defaults to white.

    decay?: number

    The decay factor of the light. Defaults to 2.0.

    distance?: number

    The maximum distance of the light. Defaults to 50.0.

    intensity?: number

    The intensity of the light. Defaults to 1.0.

    name?: string

    The name of the light object. Defaults to "Light".

    shadowBias?: number

    A small offset to prevent shadow acne. Defaults to 0.005.

    shadowNormalBias?: number

    An offset along the surface normal to prevent shadow acne. Defaults to 0.0.

    shadowResolution?: number

    The resolution of the shadow map for this light. Defaults to 512.