fsVarsGetAircrafVarId

The fsVarsGetAircraftVarId function can be used to get the FsSimVarId of a specific SimVar using its name.

 

Syntax
FsSimVarId fsVarsGetAircraftVarId(
    const char* simVarName
);

 

Parameters
Parameters Description
simVarName

The name of the simvar.


Return Values

The function returns the right Id associated to the given name. If an error occurred, the function will return 0 (SIMVAR_NONE).

 

Example
FsSimVarId simvarId = fsVarsGetAircraftVarId("ATTITUDE INDICATOR PITCH DEGREES"); // valid
FsSimVarId wrongSimVarId = fsVarsGetAircraftVarId("toto"); // returns -1