ScarDoc

Start typing to search the SCAR reference.

Function
Other

std.Assert

Makes an assertion. If the assertion turns out to be false, raises an error.

On this page
std.Assert()

Description

e.g. foo = 7; assert(foo ~= nil, 'foo should not be nil!', 'If foo is nil we don't know how many bars to spawn!'') This is intended to be a more scripter friendly version of LUA assert.

Returns

nil;nil; raises error when assert is nil or false

Source

Declared in the game's script sources at:

scar/standard.scar