s&
About
The Project
infoAbout s&box mapRoadmap monitoringMetricsEngine startup and usage numbers
Updates
newspaperLatest News published_with_changesChangesRelease-by-release changelog
Games
Browse Games Discover Games

Gamejams

Date
Theme

Date announced very soon. Theme revealed when the jam starts.

$50,000
prizepool
Workshop
Playable
sports_esportsGamesStandalone games and gamemodes
Assets
landscapeMaps view_in_arModels textureMaterials apparelClothing
appsEverythingEvery asset type in one list
Forum
Learn
Documentation
docsDocumentation apiAPI Reference
Resources
schoolTutorials manage_searchCode Search
inputLog in with Steam chevron_leftChange Language
简体中文EnglishРусскийEspañolPortuguês-BrasilDeutsch日本語FrançaisPolskiTürkçe한국어PirateItalianoไทย繁體中文УкраїнськаČeštinaNederlandsMagyarDanskSuomiSvenskaNorskΕλληνικάRomânăБългарскиTiếng ViệtBahasa IndonesiaEspañol-Latinoaméricaالعربية
Api
Classes
DirectionalLight
chevron_left Classes
class
DirectionalLight

Constructors

functionsDirectionalLight

Properties

data_objectContactShadowsdata_objectShadowCascadeCountdata_objectShadowCascadeSplitRatiodata_objectSkyColordata_objectVisualizer

Methods

lockCreateSceneObjectlockDrawGizmoslockOnAwake
DirectionalLight
A directional light that casts shadows, like the sun.
class Sandbox .account_tree extends Light
Sandbox.Engine

build Constructors 1

DirectionalLight ()

data_object Properties 5

ContactShadows
bool
Add small-scale screen-space contact shadows on top of the cascaded shadow maps. Captures fine contact detail the shadow maps miss, at some GPU cost.
ShadowCascadeCount
int
Number of cascades to split the view frustum into for the whole scene dynamic shadow. More cascades result in better shadow resolution, but adds significant rendering cost. User settings will set a maximum.
ShadowCascadeSplitRatio
float
Controls how cascades 2+ are distributed between the first cascade boundary and the far clip. 0 is uniform, 1 is fully logarithmic.
SkyColor
Color
Color of the ambient sky color This is kept for long term support, the recommended way to do this is with an Ambient Light component.
Visualizer
CascadeVisualizer

functions Methods 3

CreateSceneObject ()
SceneLight
DrawGizmos ()
OnAwake ()

Inheritance

Component
Light
DirectionalLight
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.
Facepunch
  • News
  • Docs
  • Metrics
  • FAQ
  • Forum
  • Discord
  • Twitter