VESSEL2::clbkLoadStateEx
From OrbiterWiki
Callback function to read the current vessel state from a scenario file.
[edit] Syntax
virtual void clbkLoadStateEx(FILEHANDLE scn, void* vs);
- scn
- File handle to the current scenario file
- vs
- VESSELSTATUS2 structure with the current default state, used for processing default parameters.
[edit] Example
void MAYFLY::clbkLoadStateEx(FILEHANDLE scn, void* vs)
{
char* pLine;
while(oapiReadScenario_nextline(scn, pLine))
{
if(!strnicmp(pLine, "LIFETIME", 8))
{
sscanf(pLine + 8, "%lf", &fRemainingLifeTime);
}
else
{
ParseScenarioLineEx(pLine, vs);
}
}
}
[edit] See also
- Vessel module sequence diagram
- ovcLoadStateEx
- ovcLoadState
- VESSEL::ParseScenarioLineEx
- oapiReadScenario_nextline

