Hi!
It took me a long time to understand how to set the configuration of Visual Studio for a new project, so here I list the step I followed and that worked for Visual Studio 2015. Hope it can help:
The first step on the creation of a new module is to set the configuration for the project. The actions will depend on the Visual Studio version, so the following statements work for Visual Studio 2015:
- On orbiterroot project property file, OrbiterSDK/resources/orbiterroot, change OrbiterDir to your current Orbiter main folder.
- Open the solution for a vessel and a plugin module at Visual Studio (i.e. Flight Data and Atlantis).
- Click New/Project/Win32Project and set the destination project folder in OrbiterSDK/samples. Select .dll and empty project before finishing.
- Create a new .cpp and .h element to the project. The project must include the definition for a new Orbiter module and the Orbitersdk.h library.
- Add orbiter.lib and Orbitersdk.lib to resource files. Those are located on OrbiterSDK/samples/lib.
- For debugging, add Orbiter debug property sheet and Orbiter plugin or/and Orbiter vessel.
- Before compiling, go to project properties, change to multiprocess (/MT) in C++/Code Generator and set Linker/Output file to $(ModuleDir)\Plugin\$(ProjectName).dll.
For previous Visual Studio versions, see the configuration explanation on the following link:
.