Skip to content

rjSetCurrentContext

Shaddatic edited this page Apr 21, 2026 · 1 revision

Prototype

void rjSetCurrentContext( Int n )

API

void (*SetCurrentContext)( Int n )

Ninja

 N/A - In binary, but not part of the API headers

Parameters

Int n

 Ninja context slot

Name Value Usage
NJD_SYSTEM_CTX 0 Ninja system context slot (default)
NJD_DEBUG_CTX 1 Context slot for debugging
NJD_NINDOWS_CTX 2 Context slot for 'Nindows' (Ninja Windows)
NJD_USER0_CTX 3 Context slot for user purpose
NJD_USER1_CTX 3 Context slot for user purpose
NJD_USER2_CTX 4 Context slot for user purpose

Returns

No return value.

Description

Change the current Ninja Context slot

Example

This example will change the context slot to USER0, allowing changes to be made to the Ninja context temporally, before restoring the context slot to SYSTEM.

// change context
rjSetCurrentContext( NJD_USER0_CTX ); // <<<<<<<<

// change context parameters without applying changes to the main context

// restore default context, effectively undoing all changes
rjSetCurrentContext( NJD_SYSTEM_CTX ); // <<<<<<<<

Related Functions

History

  • 1.5.0.0:
    • Introduced to the 'Ninja' API module

Clone this wiki locally