- Joined
- Apr 1, 2008
- Messages
- 2,064
- Reaction score
- 507
- Points
- 113
Thanks a lot for the information!Using "GetModuleFileName (oapiGetOrbiterInstance (), ptrToOutputCharBuffer, charBufferLength);" will get you path to orbiter.exe in Modules/Server and not its root dir (because that's where the loaded orbiter.exe is located), and Spacecraft3 has GetModuleFileName in its import table.
Hopefully I don't memorize it when coding Orbiter modules
While being at this "path issue": I know that the PathRoot enumeration in OrbiterAPI.h is used at several places in the API to set the path origin when loading files for example (e.g. oapiOpenFile ).
Shouldn't we ask Mr. Schweiger (martins) to introduce a function like
Code:
OAPIFUNC const char *oapiGetFullPath (PathRoot root = ROOT);
Or is it already available somewhere and I just didn't found it yet?
/Kuddel