Documentation index for AI agents (llms.txt) A Markdown version of every page is available: request the page's source under /docs/, follow the "alternate" link in this page's head, or start from /llms.txt.
Visual Script logo Manual

Set Render Settings Ambient Mode#

Rendering / Render Settings / Set Render Settings Ambient Mode

Description#

Changes where the scene ambient light comes from

Parameters#

Name Description
Ambient Mode Skybox samples the skybox, Trilight blends the sky, equator and ground colors and Flat uses the ambient light color

Code#

using System;
using UnityEngine;
using UnityEngine.Rendering;
using VisualScript.Icons;

namespace VisualScript.Runtime
{
    [Title("Set Render Settings Ambient Mode")]
    [Category("Rendering/Render Settings/Ambient Mode")]
    [Description("Changes where the scene ambient light comes from")]

    [Image(typeof(IconPicture), ColorTheme.Type.TextLight, typeof(BadgeSettings))]
    [Keywords("Environment", "Ambient", "Lighting", "Skybox", "Gradient", "Color")]

    [Parameter("Ambient Mode", "Skybox samples the skybox, Trilight blends the sky, equator and ground colors and Flat uses the ambient light color")]

    [Serializable]
    public class InstructionRenderSettingsSetAmbientMode : Instruction
    {
        [SerializeField] private AmbientMode m_AmbientMode = AmbientMode.Skybox;

        protected override string GetTitle(GameObject source)
        {
            string className = TextUtils.ThemeAsKeyword("Render Settings");
            string member = TextUtils.ThemeAsKeyword("Ambient Mode");
            return $"{className} {member} = {this.m_AmbientMode}";
        }

        protected override Awaitable Run(Args args)
        {
            RenderSettings.ambientMode = this.m_AmbientMode;
            return Done;
        }
    }
}
Visual Script logoVisual Script © Catsoft Works 2026. All rights reserved.