ReferenceScript nodesMath › Date and Time
Is Night
Whether it's dark outside (roughly), and how light, 0 to 1.
ƒIs Night
Result
Daylight
Inputs
None.
Outputs
| Pin | Type |
|---|---|
Resultout | bool |
Daylightdaylight | number |
The code it becomes
The graph below written as a script would write it.
// On Scene Startscene.log(((scene.clock.daylight <= 0)));In a graph
◆On Scene Start
ƒIs Night
Result
Daylight
ƒPrint
In Text
The node with what starts it and Print to show what it gives, as Studio draws them.
Related
Notes from the community
Written by creators and checked by the docs' editors. Not part of Motion's official reference.