ReferenceScript nodesDevelopment
Assert
Writes an error in the log when the condition isn't true, and goes on.
ƒAssert
Condition
MessageThis should be true
Inputs
| Pin | Type | Starts at | Notes |
|---|---|---|---|
in | what happens next | – | – |
Conditioncondition | bool | true | – |
Messagemessage | text | "This should b…" | – |
Outputs
| Pin | Type |
|---|---|
then | what happens next |
The code it becomes
The graph below written as a script would write it.
// On Scene Startif (!(true)) scene.error("Assert: " + "This should be true");In a graph
◆On Scene Start
ƒAssert
Condition
MessageThis should be true
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.