FANDOM


TRUE is a constant in NWScript that is convenient to use when a function needs to return a yes/no type of answer, and that will be interpreted as truth in a conditional or loop. Using this constant tends to make for more understandable code than using an explicit numeric value.

The actual definition of this constant is the integer value "1", but this fact should never be used within a script.


Example: A chest that uses the following script to handle the OnOpen event will lock itself once opened.

//Script in OnOpen

void main()
{
    SetLocked(OBJECT_SELF, TRUE)
}

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.