API:ShipConstruction

From Kerbal Space Program Wiki
Revision as of 22:52, 1 March 2013 by Skykooler (talk | contribs) (Created page.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

ShipConstruction Class

The ShipConstruction class is used to construct ships.


Properties

The following are public properties available in ShipConstruction.

Signature Description
List Backups { get; }  ?
ConfigNode ShipConfig { get; }
int ShipType { get; set; }


Methods

The following are methods included in ShipConstruction.

Signature Description
void AssembleForLaunch(ShipConstruct ship, string landedAt, FlightState sceneState) Put the ship together and prepare it for launch. landedAt can be any string; it is only used to tell the ship where it launched from.
int CheckCraftFileType(string filePath)  ?
string GetShipsSubfolderFor(GameScenes scene) Gets the folder in which ships for the current scene are stored.
ShipConstruct LoadShip(string filePath) Load a ship. If filePath is not given, load the last ship used in the VAB.
void PutShipToGround(ShipConstruct ship, UnityEngine.Transform spawnPoint) Places the bottom of the ship at the specified point.