Difference between revisions of "Module Tips and Tricks"

From Kerbal Space Program Wiki
Jump to: navigation, search
m (Syntax correction of new section)
(Automatically Copy to KSP For Testing)
Line 21: Line 21:
 
#* You can add more stuff for copying over parts, too.
 
#* You can add more stuff for copying over parts, too.
  
-- [[User:N3X15|N3X15]] ([[User talk:N3X15|talk]]) 19:16, 6 March 2012 (UTC)=== Checking Compatability with Multi-platform === You can use MoMA from the Mono project to check that you did not use any .Net specific code.It will report all modules not shipped with Mono.  Remember, the main KSP binary provides your Unity namespaces, so those are taken care of.  However, routines any other namespaces should be found in the standard libraries found in Mono.
+
=== Checking Compatability with Multi-platform === You can use MoMA from the Mono project to check that you did not use any .Net specific code.It will report all modules not shipped with Mono.  Remember, the main KSP binary provides your Unity namespaces, so those are taken care of.  However, routines any other namespaces should be found in the standard libraries found in Mono.
  
 
[[Category:Modding Tutorials]]
 
[[Category:Modding Tutorials]]

Revision as of 06:18, 16 April 2013

Visual Studio Tips

Package As You Build

I frequently set up my plugins so they are shoved into MyKSPSolution/bin/Plugins after being compiled so it's much easier to package, and so I can create parts in bin/Parts.

  1. Right-click on your plugin project (NOT the solution) and choose Properties.
  2. Click on the Build tab.
  3. Change Output Path to ..\bin\Plugins\.
  4. Create YourKSPSolution\bin\Plugins and YourKSPSolution\bin\Parts.

Visual Studio should now place compiled binaries into bin\Plugins for packaging. -- N3X15 (talk) 19:16, 6 March 2012 (UTC)

Automatically Copy to KSP For Testing

The repetitive process of copying your plugins to KSP really sucks, so I have a simple modification that makes things quite a bit easier.

  1. Right-click on your plugin project (NOT the solution) and choose Properties.
  2. Open the Build Events tab
  3. In the Post-build event box, type copy "$(TargetPath)" "C:\path\to\KSP\Plugins\" (Yes, the quotes are needed!)
    • You can add more stuff for copying over parts, too.

=== Checking Compatability with Multi-platform === You can use MoMA from the Mono project to check that you did not use any .Net specific code.It will report all modules not shipped with Mono. Remember, the main KSP binary provides your Unity namespaces, so those are taken care of. However, routines any other namespaces should be found in the standard libraries found in Mono.