.. default-domain:: c .. highlight:: c .. _cnano-api-parts: Parts ===== The following classes allow interaction with a vessel's individual parts. .. seealso:: The :std:ref:`parts guide ` walks the tree of parts, and explains fuel lines, stage numbers and part modules. .. contents:: :local: Parts ----- .. type:: krpc_SpaceCenter_Parts_t Instances of this class are used to interact with the parts of a vessel. An instance can be obtained by calling :func:`krpc_SpaceCenter_Vessel_Parts`. .. macro:: KRPC_CLASS_SPACECENTER_PARTS The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Parts_All(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all of the vessels parts. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Root(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Parts_t instance) The vessels root part. .. note:: See the discussion on :rst:ref:`user-guide-parts-tree`. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Controlling(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Parts_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Parts_set_Controlling(krpc_connection_t connection, krpc_SpaceCenter_Parts_t instance, krpc_SpaceCenter_Part_t value) The part from which the vessel is controlled. Returns ``nullptr`` if the vessel has no control point, in which case it is oriented by its root part. :Game Scenes: Flight .. note:: A vessel gets no control point when it is created by a decoupler or an undocking and none of its parts is a command module with crew aboard. A probe core does not give it one either. Assign this property to choose the control point, which is equivalent to "Control From Here" in game. .. function:: krpc_error_t krpc_SpaceCenter_Parts_WithName(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance, const char * name) A list of parts whose :func:`krpc_SpaceCenter_Part_Name` is *name*. :Parameters: * **name** -- The name of the part. .. function:: krpc_error_t krpc_SpaceCenter_Parts_WithTitle(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance, const char * title) A list of all parts whose :func:`krpc_SpaceCenter_Part_Title` is *title*. :Parameters: * **title** -- The title of the part. .. function:: krpc_error_t krpc_SpaceCenter_Parts_WithTag(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance, const char * tag) A list of all parts whose :func:`krpc_SpaceCenter_Part_Tag` is *tag*. :Parameters: * **tag** -- The name tag of the part. .. function:: krpc_error_t krpc_SpaceCenter_Parts_WithModule(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance, const char * moduleName) A list of all parts that contain a :type:`krpc_SpaceCenter_Module_t` whose :func:`krpc_SpaceCenter_Module_Name` is *moduleName*. :Parameters: * **moduleName** -- The name of the module. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ModulesWithName(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance, const char * moduleName) A list of modules (combined across all parts in the vessel) whose :func:`krpc_SpaceCenter_Module_Name` is *moduleName*. :Parameters: * **moduleName** -- The name of the module. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Antennas(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all antennas in the vessel. .. note:: A part with several antennas has an entry for each. If RemoteTech is installed, this will always return an empty list. To interact with RemoteTech antennas, use the RemoteTech service APIs. .. function:: krpc_error_t krpc_SpaceCenter_Parts_CargoBays(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all cargo bays in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ControlSurfaces(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all control surfaces in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Decouplers(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all decouplers in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_DockingPorts(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all docking ports in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Engines(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all engines in the vessel. .. note:: This includes any part that generates thrust. This covers many different types of engine, including liquid fuel rockets, solid rocket boosters, jet engines and RCS thrusters. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Experiments(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all science experiments in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Fairings(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all fairings in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Intakes(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all intakes in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Legs(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all landing legs attached to the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_LaunchClamps(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all launch clamps attached to the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Lights(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all lights in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Parachutes(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all parachutes in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Radiators(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all radiators in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ResourceDrains(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all resource drains in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RCS(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all RCS blocks/thrusters in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ReactionWheels(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all reaction wheels in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ResourceConverters(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all resource converters in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_ResourceHarvesters(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all resource harvesters in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RoboticControllers(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all robotic controllers in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RoboticHinges(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all robotic hinges in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RoboticPistons(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all robotic pistons in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RoboticRotations(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all robotic rotations in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_RoboticRotors(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all robotic rotors in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Sensors(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all sensors in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_SolarPanels(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all solar panels in the vessel. .. function:: krpc_error_t krpc_SpaceCenter_Parts_Wheels(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Parts_t instance) A list of all wheels in the vessel. Part ---- .. type:: krpc_SpaceCenter_Part_t Represents an individual part. Vessels are made up of multiple parts. Instances of this class can be obtained by several methods in :type:`krpc_SpaceCenter_Parts_t`. .. macro:: KRPC_CLASS_SPACECENTER_PART The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Part_t instance) Internal name of the part, as used in `part cfg files `_. For example "Mark1-2Pod". .. function:: krpc_error_t krpc_SpaceCenter_Part_Title(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Part_t instance) Title of the part, as shown when the part is right clicked in-game. For example "Mk1-2 Command Pod". .. function:: krpc_error_t krpc_SpaceCenter_Part_Config(krpc_connection_t connection, krpc_SpaceCenter_ConfigNode_t * returnValue, krpc_SpaceCenter_Part_t instance) The static configuration of the part, as found in its `part cfg file `_. This provides access to data that is not exposed elsewhere, such as the configuration of the part's modules. Returns ``nullptr`` if the part has no associated configuration node. .. function:: krpc_error_t krpc_SpaceCenter_Part_Tag(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Part_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Part_set_Tag(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, const char * value) The name tag for the part. Can be set to a custom string using the in-game user interface. Throws an exception if no name tag part module is installed. .. note:: Requires KSPCommunityPartModules 0.5 or later, or kOS, which share one name tag. .. function:: krpc_error_t krpc_SpaceCenter_Part_FlagURL(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Part_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Part_set_FlagURL(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, const char * value) The asset URL for the part's flag. .. function:: krpc_error_t krpc_SpaceCenter_Part_Highlighted(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Part_set_Highlighted(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, bool value) Whether the part is highlighted. :Game Scenes: Flight .. note:: The highlighting is removed when the client that enabled it disconnects. .. function:: krpc_error_t krpc_SpaceCenter_Part_HighlightColor(krpc_connection_t connection, krpc_StdLib_ColorRGB_t * returnValue, krpc_SpaceCenter_Part_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Part_set_HighlightColor(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, const krpc_StdLib_ColorRGB_t * value) The color used to highlight the part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Cost(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The cost of the part with its resources full, in units of funds. .. function:: krpc_error_t krpc_SpaceCenter_Part_Vessel(krpc_connection_t connection, krpc_SpaceCenter_Vessel_t * returnValue, krpc_SpaceCenter_Part_t instance) The vessel that contains this part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Parent(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Part_t instance) The parts parent. Returns ``nullptr`` if the part does not have a parent. This, in combination with :func:`krpc_SpaceCenter_Part_Children`, can be used to traverse the vessels parts tree. .. note:: See the discussion on :rst:ref:`user-guide-parts-tree`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Children(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Part_t instance) The parts children. Returns an empty list if the part has no children. This, in combination with :func:`krpc_SpaceCenter_Part_Parent`, can be used to traverse the vessels parts tree. .. note:: See the discussion on :rst:ref:`user-guide-parts-tree`. .. function:: krpc_error_t krpc_SpaceCenter_Part_AxiallyAttached(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is axially attached to its parent, i.e. on the top or bottom of its parent. If the part has no parent, returns ``false``. .. note:: See the discussion on :rst:ref:`user-guide-parts-attachment-modes`. .. function:: krpc_error_t krpc_SpaceCenter_Part_RadiallyAttached(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is radially attached to its parent, i.e. on the side of its parent. If the part has no parent, returns ``false``. .. note:: See the discussion on :rst:ref:`user-guide-parts-attachment-modes`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Stage(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Part_t instance) The stage in which this part will be activated. Returns -1 if the part is not activated by staging. .. note:: See the discussion on :rst:ref:`user-guide-parts-staging`. .. function:: krpc_error_t krpc_SpaceCenter_Part_DecoupleStage(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Part_t instance) The stage in which this part will be decoupled. Returns -1 if the part is never decoupled from the vessel. .. note:: See the discussion on :rst:ref:`user-guide-parts-staging`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Massless(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is `massless `_. .. function:: krpc_error_t krpc_SpaceCenter_Part_Mass(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The current mass of the part, including resources it contains, in kilograms. Returns zero if the part is massless. .. function:: krpc_error_t krpc_SpaceCenter_Part_DryMass(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The mass of the part, not including any resources it contains, in kilograms. Returns zero if the part is massless. .. function:: krpc_error_t krpc_SpaceCenter_Part_Shielded(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is shielded from the exterior of the vessel, for example by a fairing. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_DynamicPressure(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The dynamic pressure acting on the part, in Pascals. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_StaticPressure(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The static pressure acting on the part, in Pascals. Below the waterline this includes the pressure of the water. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Displacement(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The volume of water the part displaces when fully submerged, in :math:`\mathrm{m^{3}}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: See :func:`krpc_SpaceCenter_Part_DisplacedVolume` for the volume it is displacing now. .. function:: krpc_error_t krpc_SpaceCenter_Part_BuoyancyMultiplier(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The multiplier applied to the buoyant force on the part. One for most parts. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_BuoyantForceAt(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance, double density, double gravity) The buoyant force on the part when fully submerged in a fluid of the given density, in Newtons. :Parameters: * **density** -- The density of the fluid, in :math:`\mathrm{kg/m^{3}}`. * **gravity** -- The acceleration due to gravity, in :math:`\mathrm{m/s^{2}}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Applies :func:`krpc_SpaceCenter_BuoyancyScalar` and :func:`krpc_SpaceCenter_Part_BuoyancyMultiplier`, so the result is what the game would do to the part rather than what `Archimedes' principle `_ alone gives. .. function:: krpc_error_t krpc_SpaceCenter_Part_Splashed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is in contact with water. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_SubmergedPortion(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The fraction of the part below the waterline, between 0 and 1. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_DisplacedVolume(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The volume of water the part is displacing, in :math:`\mathrm{m^{3}}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Depth(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The depth of the part below the waterline, in meters, measured at :func:`krpc_SpaceCenter_Part_CenterOfDisplacement`. Negative above the waterline. Returns zero if the body the vessel is at has no ocean. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_MinDepth(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The depth of the shallowest point of the part below the waterline, in meters. Returns zero if the body the vessel is at has no ocean. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_MaxDepth(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The depth of the deepest point of the part below the waterline, in meters. Returns zero if the body the vessel is at has no ocean. :Game Scenes: Flight .. note:: The game ramps the buoyant force in over the first fraction of a meter of this depth. .. function:: krpc_error_t krpc_SpaceCenter_Part_SubmergedDynamicPressure(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The dynamic pressure of the water acting on the part, in Pascals. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_SubmergedDragMultiplier(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The multiplier applied to the drag on the part while it is submerged. :Game Scenes: Flight .. note:: The game sets this high on splashdown and eases it down as the part moves through the water. It climbs back once the part slows to a crawl, so a hull under way reads lower than one lying still. .. function:: krpc_error_t krpc_SpaceCenter_Part_SubmergedLiftMultiplier(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The multiplier applied to the lift on the part while it is submerged. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_WaterAngularDragMultiplier(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The multiplier applied to the angular drag on the part while it is submerged. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Part of the part's configuration rather than a live readout, so it reads the same in the editor and at a body with no ocean. .. function:: krpc_error_t krpc_SpaceCenter_Part_ImpactTolerance(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The crash tolerance of the part, in :math:`\mathrm{m/s}`. .. function:: krpc_error_t krpc_SpaceCenter_Part_BreakingForce(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The breaking force of the part's attachments, in :math:`\mathrm{kN}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: The joint to the parent part takes the lower breaking force of the two parts, scaled by the size of the attachment node. See :func:`krpc_SpaceCenter_Part_JointBreakForce`. .. function:: krpc_error_t krpc_SpaceCenter_Part_BreakingTorque(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The breaking torque of the part's attachments, in :math:`\mathrm{kN \cdot m}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: The joint to the parent part takes the lower breaking torque of the two parts, scaled by the size of the attachment node. See :func:`krpc_SpaceCenter_Part_JointBreakTorque`. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointBreakForce(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The force that breaks the joint to the parent part, in :math:`\mathrm{kN}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints. It is infinite for a short time after the vessel loads, such as just after launch. The root part and a physicsless part have no joint to their parent. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointBreakTorque(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The torque that breaks the joint to the parent part, in :math:`\mathrm{kN \cdot m}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints. It is infinite for a short time after the vessel loads. On a stack node of size 2 or more, the physics joints sit apart around the node. A bending moment then breaks the joint when one physics joint's force exceeds its share of :func:`krpc_SpaceCenter_Part_JointBreakForce`, usually at a much larger moment than this torque. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointSpring(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The spring constant of the joint to the parent part against translation, in :math:`\mathrm{kN/m}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints. A rigid attachment locks the joint, and this spring then has no effect. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointDamper(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The damping constant of the joint to the parent part against translation, in :math:`\mathrm{kN \cdot s/m}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints. The stock game sets it to zero, and mods such as Kerbal Joint Reinforcement change it. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointAngularSpring(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The spring constant of the joint to the parent part against bending, in :math:`\mathrm{kN \cdot m/rad}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints, about the two axes perpendicular to the joint axis. The joint is far stiffer against twisting about its axis. On a stack node of size 2 or more, the physics joints sit apart around the node, and the joint bends much less than this spring gives. A rigid attachment makes it infinite. .. function:: krpc_error_t krpc_SpaceCenter_Part_JointAngularDamper(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The damping constant of the joint to the parent part against bending, in :math:`\mathrm{kN \cdot m \cdot s/rad}`. Throws an exception if the part has no joint to its parent part. :Game Scenes: Flight .. note:: The sum over the joint's physics joints. The stock game sets it to zero, and mods such as Kerbal Joint Reinforcement change it. .. function:: krpc_error_t krpc_SpaceCenter_Part_Temperature(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) Temperature of the part, in Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_SkinTemperature(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) Temperature of the skin of the part, in Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_MaxTemperature(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) Maximum temperature that the part can survive, in Kelvin. .. function:: krpc_error_t krpc_SpaceCenter_Part_MaxSkinTemperature(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) Maximum temperature that the skin of the part can survive, in Kelvin. .. function:: krpc_error_t krpc_SpaceCenter_Part_MaxPressure(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) Maximum pressure that the part can survive, in Pascals. .. note:: With part pressure limits enabled in the difficulty settings, the part is destroyed when :func:`krpc_SpaceCenter_Part_StaticPressure` plus :func:`krpc_SpaceCenter_Part_DynamicPressure` exceeds this. .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalMass(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) A measure of how much energy it takes to increase the internal temperature of the part, in Joules per Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalSkinMass(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) A measure of how much energy it takes to increase the skin temperature of the part, in Joules per Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalResourceMass(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) A measure of how much energy it takes to increase the temperature of the resources contained in the part, in Joules per Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalConductionFlux(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which heat energy is conducting into or out of the part via contact with other parts. Measured in energy per unit time, or power, in Watts. A positive value means the part is gaining heat energy, and negative means it is losing heat energy. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalConvectionFlux(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which heat energy is convecting into or out of the part from the surrounding atmosphere. Measured in energy per unit time, or power, in Watts. A positive value means the part is gaining heat energy, and negative means it is losing heat energy. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalRadiationFlux(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which heat energy is radiating into or out of the part from the surrounding environment. Measured in energy per unit time, or power, in Watts. A positive value means the part is gaining heat energy, and negative means it is losing heat energy. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalInternalFlux(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which heat energy is begin generated by the part. For example, some engines generate heat by combusting fuel. Measured in energy per unit time, or power, in Watts. A positive value means the part is gaining heat energy, and negative means it is losing heat energy. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_ThermalSkinToInternalFlux(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which heat energy is transferring between the part's skin and its internals. Measured in energy per unit time, or power, in Watts. A positive value means the part's internals are gaining heat energy, and negative means its skin is gaining heat energy. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_CrewCapacity(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Part_t instance) The number of crew members that can occupy the part. .. function:: krpc_error_t krpc_SpaceCenter_Part_Crew(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Part_t instance) The crew members occupying the part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_AvailableSeats(krpc_connection_t connection, uint32_t * returnValue, krpc_SpaceCenter_Part_t instance) How many open seats the part has. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Resources(krpc_connection_t connection, krpc_SpaceCenter_Resources_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Resources` object for the part. .. function:: krpc_error_t krpc_SpaceCenter_Part_Crossfeed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether this part is crossfeed capable. .. function:: krpc_error_t krpc_SpaceCenter_Part_IsFuelLine(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether this part is a fuel line. .. function:: krpc_error_t krpc_SpaceCenter_Part_FuelLinesFrom(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Part_t instance) The parts that are connected to this part via fuel lines, where the direction of the fuel line is into this part. :Game Scenes: Flight .. note:: See the discussion on :rst:ref:`user-guide-parts-fuel-lines`. .. function:: krpc_error_t krpc_SpaceCenter_Part_FuelLinesTo(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Part_t instance) The parts that are connected to this part via fuel lines, where the direction of the fuel line is out of this part. :Game Scenes: Flight .. note:: See the discussion on :rst:ref:`user-guide-parts-fuel-lines`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Modules(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Part_t instance) The modules for this part. .. function:: krpc_error_t krpc_SpaceCenter_Part_Antenna(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t * returnValue, krpc_SpaceCenter_Part_t instance) An :func:`krpc_SpaceCenter_Part_Antenna` if the part is an antenna, otherwise ``nullptr``. .. note:: For a part with several antennas, this is the first. :func:`krpc_SpaceCenter_Parts_Antennas` lists them all. If RemoteTech is installed, this will always return ``nullptr``. To interact with RemoteTech antennas, use the RemoteTech service APIs. .. function:: krpc_error_t krpc_SpaceCenter_Part_CargoBay(krpc_connection_t connection, krpc_SpaceCenter_CargoBay_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_CargoBay` if the part is a cargo bay, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_ControlSurface(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_ControlSurface` if the part is an aerodynamic control surface, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Decoupler(krpc_connection_t connection, krpc_SpaceCenter_Decoupler_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Decoupler` if the part is a decoupler, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_DockingPort(krpc_connection_t connection, krpc_SpaceCenter_DockingPort_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_DockingPort` if the part is a docking port, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Engine(krpc_connection_t connection, krpc_SpaceCenter_Engine_t * returnValue, krpc_SpaceCenter_Part_t instance) An :func:`krpc_SpaceCenter_Part_Engine` if the part is an engine, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Experiment(krpc_connection_t connection, krpc_SpaceCenter_Experiment_t * returnValue, krpc_SpaceCenter_Part_t instance) An :func:`krpc_SpaceCenter_Part_Experiment` if the part contains a single science experiment, otherwise ``nullptr``. .. note:: Throws an exception if the part contains more than one experiment. In that case, use :func:`krpc_SpaceCenter_Part_Experiments` to get the list of experiments in the part. .. function:: krpc_error_t krpc_SpaceCenter_Part_Experiments(krpc_connection_t connection, krpc_list_object_t * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Part_t instance) A list of :func:`krpc_SpaceCenter_Part_Experiment` objects that the part contains. .. function:: krpc_error_t krpc_SpaceCenter_Part_Fairing(krpc_connection_t connection, krpc_SpaceCenter_Fairing_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Fairing` if the part is a fairing, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Intake(krpc_connection_t connection, krpc_SpaceCenter_Intake_t * returnValue, krpc_SpaceCenter_Part_t instance) An :func:`krpc_SpaceCenter_Part_Intake` if the part is an intake, otherwise ``nullptr``. .. note:: This includes any part that generates thrust. This covers many different types of engine, including liquid fuel rockets, solid rocket boosters and jet engines. For RCS thrusters see :func:`krpc_SpaceCenter_Part_RCS`. .. function:: krpc_error_t krpc_SpaceCenter_Part_Leg(krpc_connection_t connection, krpc_SpaceCenter_Leg_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Leg` if the part is a landing leg, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_LaunchClamp(krpc_connection_t connection, krpc_SpaceCenter_LaunchClamp_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_LaunchClamp` if the part is a launch clamp, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Light(krpc_connection_t connection, krpc_SpaceCenter_Light_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Light` if the part is a light, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Parachute(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Parachute` if the part is a parachute, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Radiator(krpc_connection_t connection, krpc_SpaceCenter_Radiator_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Radiator` if the part is a radiator, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_ResourceDrain(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_ResourceDrain` if the part is a resource drain, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RCS(krpc_connection_t connection, krpc_SpaceCenter_RCS_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RCS` if the part is an RCS block/thruster, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_ReactionWheel(krpc_connection_t connection, krpc_SpaceCenter_ReactionWheel_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_ReactionWheel` if the part is a reaction wheel, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_ResourceConverter(krpc_connection_t connection, krpc_SpaceCenter_ResourceConverter_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_ResourceConverter` if the part is a resource converter, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_ResourceHarvester(krpc_connection_t connection, krpc_SpaceCenter_ResourceHarvester_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_ResourceHarvester` if the part is a resource harvester, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RoboticController(krpc_connection_t connection, krpc_SpaceCenter_RoboticController_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RoboticController` if the part is a robotic controller, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RoboticHinge(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RoboticHinge` if the part is a robotic hinge, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RoboticPiston(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RoboticPiston` if the part is a robotic piston, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RoboticRotation(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RoboticRotation` if the part is a robotic rotation servo, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_RoboticRotor(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_RoboticRotor` if the part is a robotic rotor, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Sensor(krpc_connection_t connection, krpc_SpaceCenter_Sensor_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Sensor` if the part is a sensor, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_SolarPanel(krpc_connection_t connection, krpc_SpaceCenter_SolarPanel_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_SolarPanel` if the part is a solar panel, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Wheel(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t * returnValue, krpc_SpaceCenter_Part_t instance) A :func:`krpc_SpaceCenter_Part_Wheel` if the part is a wheel, otherwise ``nullptr``. .. function:: krpc_error_t krpc_SpaceCenter_Part_Position(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position of the part in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: This is a fixed position in the part, defined by the parts model. It s not necessarily the same as the parts center of mass. Use :func:`krpc_SpaceCenter_Part_CenterOfMass` to get the parts center of mass. .. function:: krpc_error_t krpc_SpaceCenter_Part_CenterOfMass(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position of the parts center of mass in the given reference frame. If the part is physicsless in flight, this is equivalent to :func:`krpc_SpaceCenter_Part_Position`. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_BoundingBox(krpc_connection_t connection, krpc_SpaceCenter_BoundingBox_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The axis-aligned bounding box of the part in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vectors are in. :returns: The positions of the minimum and maximum vertices of the box. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: This is computed from the meshes that make up the parts model, and covers only this part - the models of any child parts are excluded. If the part has no visible model, the box has zero volume and is centered on the :func:`krpc_SpaceCenter_Part_CenterOfMass` of the part. .. function:: krpc_error_t krpc_SpaceCenter_Part_Direction(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The direction the part points in, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned direction is in. :returns: The direction as a unit vector. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_Velocity(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The linear velocity of the part in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned velocity vector is in. :returns: The velocity as a vector. The vector points in the direction of travel, and its magnitude is the speed of the body in :math:`\mathrm{m/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_Rotation(krpc_connection_t connection, krpc_tuple_double_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The rotation of the part, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned rotation is in. :returns: The rotation as a quaternion of the form ``(x, y, z, w)``. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_Lift(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The aerodynamic `lift `_ currently acting on the part. :Parameters: * **referenceFrame** -- The reference frame that the returned vector is in. :returns: A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. :Game Scenes: Flight .. note:: Not available when Ferram Aerospace Research is installed. .. function:: krpc_error_t krpc_SpaceCenter_Part_Drag(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The aerodynamic `drag `_ currently acting on the part. :Parameters: * **referenceFrame** -- The reference frame that the returned vector is in. :returns: A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. :Game Scenes: Flight .. note:: Not available when Ferram Aerospace Research is installed. .. function:: krpc_error_t krpc_SpaceCenter_Part_CenterOfBuoyancy(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The point the buoyant force on the part acts at, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: A submerged part reports the point the game applied the force at, which it shifts towards the submerged part of the hull. Any other part reports its configured center of buoyancy. .. function:: krpc_error_t krpc_SpaceCenter_Part_CenterOfDisplacement(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The point the depth of the part is measured at, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_BuoyantForce(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The buoyant force currently acting on the part. :Parameters: * **referenceFrame** -- The reference frame that the returned vector is in. :returns: A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. :Game Scenes: Flight .. note:: The buoyant force on its own. The water drag and lift the game applies alongside it are reported by :func:`krpc_SpaceCenter_Part_SubmergedDragMultiplier` and :func:`krpc_SpaceCenter_Part_SubmergedLiftMultiplier`. .. function:: krpc_error_t krpc_SpaceCenter_Part_MomentOfInertia(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Part_t instance) The moment of inertia of the part in :math:`\mathrm{kg \cdot m^{2}}` around its center of mass in the parts center of mass reference frame (:func:`krpc_SpaceCenter_Part_CenterOfMassReferenceFrame`). :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_InertiaTensor(krpc_connection_t connection, krpc_list_double_t * returnValue, krpc_SpaceCenter_Part_t instance) The inertia tensor of the part around its center of mass, in the parts center of mass reference frame (:func:`krpc_SpaceCenter_Part_CenterOfMassReferenceFrame`). Returns the 3x3 matrix as a list of elements, in row-major order. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Part_ReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_ReferenceFrame_t * returnValue, krpc_SpaceCenter_Part_t instance) The reference frame that is fixed relative to this part, and centered on a fixed position within the part, defined by the parts model. * The origin is at the position of the part, as returned by :func:`krpc_SpaceCenter_Part_Position`. * The axes rotate with the part. * The x, y and z axis directions depend on the design of the part. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: For docking port parts, this reference frame is not necessarily equivalent to the reference frame for the docking port, returned by :func:`krpc_SpaceCenter_DockingPort_ReferenceFrame`. .. figure:: /images/reference-frames/part.png :align: center Mk1 Command Pod reference frame origin and axes .. function:: krpc_error_t krpc_SpaceCenter_Part_CenterOfMassReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_ReferenceFrame_t * returnValue, krpc_SpaceCenter_Part_t instance) The reference frame that is fixed relative to this part, and centered on its center of mass. * The origin is at the center of mass of the part, as returned by :func:`krpc_SpaceCenter_Part_CenterOfMass`. * The axes rotate with the part. * The x, y and z axis directions depend on the design of the part. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: For docking port parts, this reference frame is not necessarily equivalent to the reference frame for the docking port, returned by :func:`krpc_SpaceCenter_DockingPort_ReferenceFrame`. .. function:: krpc_error_t krpc_SpaceCenter_Part_AddForce(krpc_connection_t connection, krpc_SpaceCenter_Force_t * returnValue, krpc_SpaceCenter_Part_t instance, const krpc_tuple_double_double_double_t * force, const krpc_tuple_double_double_double_t * position, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) .. warning:: Deprecated. Use ``Debug.AddForce`` instead. Exert a constant force on the part, acting at the given position. :Parameters: * **force** -- A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. * **position** -- The position at which the force acts, as a vector. * **referenceFrame** -- The reference frame that the force and position are in. :returns: An object that can be used to remove or modify the force. :Game Scenes: Flight .. note:: The force is removed when the client that added it disconnects. .. function:: krpc_error_t krpc_SpaceCenter_Part_InstantaneousForce(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, const krpc_tuple_double_double_double_t * force, const krpc_tuple_double_double_double_t * position, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) .. warning:: Deprecated. Use ``Debug.InstantaneousForce`` instead. Exert an instantaneous force on the part, acting at the given position. :Parameters: * **force** -- A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. * **position** -- The position at which the force acts, as a vector. * **referenceFrame** -- The reference frame that the force and position are in. :Game Scenes: Flight .. note:: The force is applied instantaneously in a single physics update. .. function:: krpc_error_t krpc_SpaceCenter_Part_set_Glow(krpc_connection_t connection, krpc_SpaceCenter_Part_t instance, bool value) Whether the part is glowing. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Part_AutoStrutMode(krpc_connection_t connection, krpc_SpaceCenter_AutoStrutMode_t * returnValue, krpc_SpaceCenter_Part_t instance) Auto-strut mode. .. function:: krpc_error_t krpc_SpaceCenter_Part_HasRealFuelsTank(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the part is a fuel tank managed by RealFuels. The remaining properties in this section are only available when it is. .. function:: krpc_error_t krpc_SpaceCenter_Part_HighlyPressurized(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Part_t instance) Whether the tank is highly pressurized, which is what a pressure-fed engine needs to draw from (see :func:`krpc_SpaceCenter_Engine_PressureFed`). Throws an exception if the part is not a RealFuels fuel tank (see :func:`krpc_SpaceCenter_Part_HasRealFuelsTank`). .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Part_BoiloffRate(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Part_t instance) The rate at which the tank's cryogenic contents are boiling off, in kilograms per second of in-game time, measured over the last update RealFuels computed it in. The contents keep boiling off under time warp, where that update covers a much longer span of in-game time than a physics frame does. The rate is zero for a tank holding nothing cryogenic, for one still being fed by a launch clamp, whose temperature RealFuels holds down instead, and in the editor. Throws an exception if the part is not a RealFuels fuel tank (see :func:`krpc_SpaceCenter_Part_HasRealFuelsTank`). .. note:: Requires RealFuels. .. type:: krpc_SpaceCenter_AutoStrutMode_t The state of an auto-strut. :func:`krpc_SpaceCenter_Part_AutoStrutMode` .. macro:: KRPC_ENUMERATION_SPACECENTER_AUTOSTRUTMODE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_OFF Off .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_ROOT Root .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_HEAVIEST Heaviest .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_GRANDPARENT Grandparent .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_FORCEROOT ForceRoot .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_FORCEHEAVIEST ForceHeaviest .. macro:: KRPC_SPACECENTER_AUTOSTRUTMODE_FORCEGRANDPARENT ForceGrandparent .. type:: krpc_SpaceCenter_Force_t Obtained by calling ``Debug.AddForce``. .. macro:: KRPC_CLASS_SPACECENTER_FORCE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Force_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Force_t instance) The part that this force is applied to. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Force_ForceVector(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Force_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Force_set_ForceVector(krpc_connection_t connection, krpc_SpaceCenter_Force_t instance, const krpc_tuple_double_double_double_t * value) The force vector, in Newtons. :returns: A vector pointing in the direction that the force acts, with its magnitude equal to the strength of the force in Newtons. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Force_Position(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Force_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Force_set_Position(krpc_connection_t connection, krpc_SpaceCenter_Force_t instance, const krpc_tuple_double_double_double_t * value) The position at which the force acts, in reference frame :func:`krpc_SpaceCenter_Force_ReferenceFrame`. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Force_ReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_ReferenceFrame_t * returnValue, krpc_SpaceCenter_Force_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Force_set_ReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_Force_t instance, krpc_SpaceCenter_ReferenceFrame_t value) The reference frame of the force vector and position. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Force_Remove(krpc_connection_t connection, krpc_SpaceCenter_Force_t instance) Remove the force. :Game Scenes: Flight .. note:: Any further use of this object throws an exception. Module ------ .. type:: krpc_SpaceCenter_Module_t This can be used to interact with a specific part module. This includes part modules in stock KSP, and those added by mods. In KSP, each part has zero or more `PartModules `_ associated with it. Each one contains some of the functionality of the part. For example, an engine has a "ModuleEngines" part module that contains all the functionality of an engine. .. macro:: KRPC_CLASS_SPACECENTER_MODULE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Module_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Module_t instance) Name of the PartModule. For example, "ModuleEngines". .. function:: krpc_error_t krpc_SpaceCenter_Module_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Module_t instance) The part that contains this module. .. function:: krpc_error_t krpc_SpaceCenter_Module_Config(krpc_connection_t connection, krpc_SpaceCenter_ConfigNode_t * returnValue, krpc_SpaceCenter_Module_t instance) The static configuration of the module, as found in the part's `cfg file `_. This provides access to data that is not exposed as a field, such as the resources produced by a generator. Returns ``nullptr`` if the module's configuration node cannot be found. .. function:: krpc_error_t krpc_SpaceCenter_Module_FieldList(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Module_t instance) A list of all the fields of the module, including those not visible in the right-click menu of the part. Filter by :func:`krpc_SpaceCenter_PartField_Visible` to get just the visible ones. .. function:: krpc_error_t krpc_SpaceCenter_Module_EventList(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Module_t instance) A list of all the events of the module, including those not currently visible or active. Events are the clickable buttons visible in the right-click menu of the part. Filter by :func:`krpc_SpaceCenter_PartEvent_Visible` and :func:`krpc_SpaceCenter_PartEvent_Active` to get just the ones shown in the menu. .. function:: krpc_error_t krpc_SpaceCenter_Module_ActionList(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Module_t instance) A list of all the actions of the module. These are the parts actions that can be assigned to action groups in the in-game editor. .. type:: krpc_SpaceCenter_PartField_t A field of a part module. Obtained by calling :func:`krpc_SpaceCenter_Module_FieldList`. .. note:: Setting a field runs the callbacks that the right-click menu of the part runs. .. macro:: KRPC_CLASS_SPACECENTER_PARTFIELD The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_PartField_Module(krpc_connection_t connection, krpc_SpaceCenter_Module_t * returnValue, krpc_SpaceCenter_PartField_t instance) The part module that contains this field. .. function:: krpc_error_t krpc_SpaceCenter_PartField_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartField_t instance) The identifier of the field. This is stable and does not change between game versions, unlike :func:`krpc_SpaceCenter_PartField_GuiName`. .. function:: krpc_error_t krpc_SpaceCenter_PartField_GuiName(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartField_t instance) The name of the field, as displayed in the right-click menu of the part. This may be empty for fields that are not visible in the menu. .. function:: krpc_error_t krpc_SpaceCenter_PartField_Visible(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_PartField_t instance) Whether the field is visible in the right-click menu of the part, in the current scene (flight or editor). .. function:: krpc_error_t krpc_SpaceCenter_PartField_Type(krpc_connection_t connection, krpc_SpaceCenter_FieldType_t * returnValue, krpc_SpaceCenter_PartField_t instance) The type of the field. .. function:: krpc_error_t krpc_SpaceCenter_PartField_Value(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartField_t instance) .. function:: krpc_error_t krpc_SpaceCenter_PartField_set_Value(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance, const char * value) The value of the field, as a string. This works for fields of any type, and returns the same string that is shown in the right-click menu of the part. .. note:: Setting the value using this property is only permitted for string fields. Use the typed properties (:func:`krpc_SpaceCenter_PartField_BoolValue`, :func:`krpc_SpaceCenter_PartField_IntValue`, :func:`krpc_SpaceCenter_PartField_FloatValue`, :func:`krpc_SpaceCenter_PartField_DoubleValue`) to set fields of other types. .. function:: krpc_error_t krpc_SpaceCenter_PartField_BoolValue(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_PartField_t instance) .. function:: krpc_error_t krpc_SpaceCenter_PartField_set_BoolValue(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance, bool value) The value of a boolean field. .. note:: The getter throws an exception if the field is not a boolean field (see :func:`krpc_SpaceCenter_PartField_Type`). .. function:: krpc_error_t krpc_SpaceCenter_PartField_IntValue(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_PartField_t instance) .. function:: krpc_error_t krpc_SpaceCenter_PartField_set_IntValue(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance, int32_t value) The value of an integer field. .. note:: The getter throws an exception if the field is not an integer field (see :func:`krpc_SpaceCenter_PartField_Type`). .. function:: krpc_error_t krpc_SpaceCenter_PartField_FloatValue(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_PartField_t instance) .. function:: krpc_error_t krpc_SpaceCenter_PartField_set_FloatValue(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance, float value) The value of a single precision floating point field. .. note:: The getter throws an exception if the field is not a single precision floating point field (see :func:`krpc_SpaceCenter_PartField_Type`). .. function:: krpc_error_t krpc_SpaceCenter_PartField_DoubleValue(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_PartField_t instance) .. function:: krpc_error_t krpc_SpaceCenter_PartField_set_DoubleValue(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance, double value) The value of a double precision floating point field. .. note:: The getter throws an exception if the field is not a double precision floating point field (see :func:`krpc_SpaceCenter_PartField_Type`). .. function:: krpc_error_t krpc_SpaceCenter_PartField_Reset(krpc_connection_t connection, krpc_SpaceCenter_PartField_t instance) Set the value of the field to its original value. .. note:: The original value is the value the field had when the part was loaded. Works for any field, including those not visible in the right-click menu. .. type:: krpc_SpaceCenter_FieldType_t The type of a part module field. See :func:`krpc_SpaceCenter_PartField_Type`. .. macro:: KRPC_ENUMERATION_SPACECENTER_FIELDTYPE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_BOOLEAN A boolean field. Access using :func:`krpc_SpaceCenter_PartField_BoolValue`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_INTEGER An integer field. Access using :func:`krpc_SpaceCenter_PartField_IntValue`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_FLOAT A single precision floating point field. Access using :func:`krpc_SpaceCenter_PartField_FloatValue`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_DOUBLE A double precision floating point field. Access using :func:`krpc_SpaceCenter_PartField_DoubleValue`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_STRING A string field. Access using :func:`krpc_SpaceCenter_PartField_Value`. .. macro:: KRPC_SPACECENTER_FIELDTYPE_UNKNOWN A field whose type is not one of the above. Its value can still be read as a string using :func:`krpc_SpaceCenter_PartField_Value`. .. type:: krpc_SpaceCenter_PartEvent_t An event of a part module. Events are the clickable buttons visible in the right-click menu of the part. Obtained by calling :func:`krpc_SpaceCenter_Module_EventList`. .. macro:: KRPC_CLASS_SPACECENTER_PARTEVENT The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_Module(krpc_connection_t connection, krpc_SpaceCenter_Module_t * returnValue, krpc_SpaceCenter_PartEvent_t instance) The part module that contains this event. .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartEvent_t instance) The identifier of the event. This is stable and does not change between game versions, unlike :func:`krpc_SpaceCenter_PartEvent_GuiName`. .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_GuiName(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartEvent_t instance) The name of the event, as displayed in the right-click menu of the part. .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_Visible(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_PartEvent_t instance) Whether the event is visible in the right-click menu of the part, in the current scene (flight or editor). .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_PartEvent_t instance) Whether the event is currently active. .. function:: krpc_error_t krpc_SpaceCenter_PartEvent_Trigger(krpc_connection_t connection, krpc_SpaceCenter_PartEvent_t instance) Trigger the event. Equivalent to clicking the button in the right-click menu of the part. .. type:: krpc_SpaceCenter_PartAction_t An action of a part module. These are the part actions that can be assigned to action groups in the in-game editor. Obtained by calling :func:`krpc_SpaceCenter_Module_ActionList`. .. macro:: KRPC_CLASS_SPACECENTER_PARTACTION The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_PartAction_Module(krpc_connection_t connection, krpc_SpaceCenter_Module_t * returnValue, krpc_SpaceCenter_PartAction_t instance) The part module that contains this action. .. function:: krpc_error_t krpc_SpaceCenter_PartAction_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartAction_t instance) The identifier of the action. This is stable and does not change between game versions, unlike :func:`krpc_SpaceCenter_PartAction_GuiName`. .. function:: krpc_error_t krpc_SpaceCenter_PartAction_GuiName(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_PartAction_t instance) The name of the action, as displayed in the in-game editor. .. function:: krpc_error_t krpc_SpaceCenter_PartAction_set_Activated(krpc_connection_t connection, krpc_SpaceCenter_PartAction_t instance, bool value) Activate or deactivate the action. Equivalent to triggering the action from an action group. Set to ``true`` to activate the action, or ``false`` to deactivate it. Config Node ----------- .. type:: krpc_SpaceCenter_ConfigNode_t Represents a configuration node, as found in a part's configuration file. A node has a name, a set of named values and a set of child nodes. This is used to access the static configuration of a part or part module, for example via :func:`krpc_SpaceCenter_Part_Config` and :func:`krpc_SpaceCenter_Module_Config`. .. macro:: KRPC_CLASS_SPACECENTER_CONFIGNODE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_ConfigNode_t instance) The name of the configuration node. For example "MODULE". .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_Values(krpc_connection_t connection, krpc_dictionary_string_string_t * returnValue, krpc_SpaceCenter_ConfigNode_t instance) The values stored in the node, as a dictionary mapping names to values. .. note:: If a name appears more than once, only the first value is included. Use :func:`krpc_SpaceCenter_ConfigNode_FindValues` to get all of the values with a given name. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_HasValue(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns ``true`` if the node has a value with the given name. :Parameters: * **name** -- Name of the value. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_GetValue(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns the value with the given name. If there is more than one value with the given name, the first is returned. Throws an exception if there is no value with the given name. :Parameters: * **name** -- Name of the value. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_FindValues(krpc_connection_t connection, krpc_list_string_t * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns all of the values with the given name, as a list. :Parameters: * **name** -- Name of the values. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_Nodes(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_ConfigNode_t instance) The child nodes contained in this node. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_HasNode(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns ``true`` if the node has a child node with the given name. :Parameters: * **name** -- Name of the child node. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_GetNode(krpc_connection_t connection, krpc_SpaceCenter_ConfigNode_t * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns the child node with the given name. If there is more than one child node with the given name, the first is returned. Throws an exception if there is no child node with the given name. :Parameters: * **name** -- Name of the child node. .. function:: krpc_error_t krpc_SpaceCenter_ConfigNode_FindNodes(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_ConfigNode_t instance, const char * name) Returns all of the child nodes with the given name, as a list. :Parameters: * **name** -- Name of the child nodes. Specific Types of Part ---------------------- The following classes provide functionality for specific types of part. .. contents:: :local: Antenna ^^^^^^^ .. note:: If RemoteTech is installed, use the RemoteTech service APIs to interact with antennas. This class covers stock and RealAntennas antennas. .. type:: krpc_SpaceCenter_Antenna_t An antenna. Obtained by calling :func:`krpc_SpaceCenter_Part_Antenna`. .. macro:: KRPC_CLASS_SPACECENTER_ANTENNA The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Antenna_t instance) The part object for this antenna. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Antenna_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_Antenna_t instance) The current state of the antenna. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Deployable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) Whether the antenna is deployable. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, bool value) Whether the antenna is deployed. :Game Scenes: Flight .. note:: Fixed antennas are always deployed. Throws :macro:`KRPC_EXCEPTION_KRPC_INVALIDOPERATIONEXCEPTION` if set on a fixed antenna. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_CanTransmit(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) Whether data can be transmitted by this antenna. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Transmit(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance) Transmit data. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Cancel(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance) Cancel current transmission of data. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Antenna_AllowPartial(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_AllowPartial(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, bool value) Whether partial data transmission is permitted. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Power(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The power of the antenna. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Not used by RealAntennas, which replaces the stock range model. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Combinable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) Whether the antenna can be combined with other antennae on the vessel to boost the power. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Not used by RealAntennas, which replaces the stock range model. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_CombinableExponent(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) Exponent used to calculate the combined power of multiple antennae on a vessel. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Not used by RealAntennas, which replaces the stock range model. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_PacketInterval(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Antenna_t instance) Interval between sending packets in seconds. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Antenna_PacketSize(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Antenna_t instance) Amount of data sent per packet in Mits. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Antenna_PacketResourceCost(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) Units of electric charge consumed per packet sent. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Gain(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Antenna_t instance) The gain of the antenna, in :math:`\mathrm{dBi}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TransmitPower(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_TransmitPower(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, float value) Returns the transmit power of the antenna, in :math:`\mathrm{dBm}`, and sets it in the editor. Throws an exception if set in flight, or outside zero to :func:`krpc_SpaceCenter_Antenna_MaxTransmitPower`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_MaxTransmitPower(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Antenna_t instance) The largest transmit power the antenna can be set to, in :math:`\mathrm{dBm}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TechLevel(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_TechLevel(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, int32_t value) Returns the tech level of the antenna, and sets it in the editor. Throws an exception if set in flight, or outside zero to :func:`krpc_SpaceCenter_Antenna_MaxTechLevel`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_MaxTechLevel(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Antenna_t instance) The highest tech level the antenna can be set to. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Band(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Antenna_t instance) The name of the radio frequency band the antenna uses, e.g. ``"S"``. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Frequency(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The frequency of the antenna's band, in Hz. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_DataRate(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The highest data rate the antenna supports, in bits per second. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Beamwidth(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The half-power beamwidth of the antenna, in degrees. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_IdlePowerDraw(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The power the antenna draws while idle, in watts. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_ActivePowerDraw(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Antenna_t instance) The power the antenna draws while transmitting, in watts. This includes :func:`krpc_SpaceCenter_Antenna_IdlePowerDraw`. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_Enabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_Enabled(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, bool value) Returns whether the antenna is enabled, and sets it in the editor. Throws an exception if set in flight. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealAntennas. A disabled antenna does not communicate and draws no power. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_DisablePermanently(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance) Disable the antenna for the rest of the flight. It then draws no power. :Game Scenes: Flight .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_CanTarget(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Antenna_t instance) Whether the antenna can be pointed at a target. Omnidirectional antennas cannot. :Game Scenes: Flight .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TargetMode(krpc_connection_t connection, krpc_SpaceCenter_AntennaTargetMode_t * returnValue, krpc_SpaceCenter_Antenna_t instance) The kind of target the antenna points at. :Game Scenes: Flight .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TargetVessel(krpc_connection_t connection, krpc_SpaceCenter_Vessel_t * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_TargetVessel(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, krpc_SpaceCenter_Vessel_t value) Returns the vessel the antenna points at, and sets the vessel to point at. :Game Scenes: Flight .. note:: Requires RealAntennas. ``nullptr`` if the antenna does not point at a vessel. Throws an exception if set to ``nullptr``, or if the antenna cannot be pointed (see :func:`krpc_SpaceCenter_Antenna_CanTarget`). .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TargetBody(krpc_connection_t connection, krpc_SpaceCenter_CelestialBody_t * returnValue, krpc_SpaceCenter_Antenna_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Antenna_set_TargetBody(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, krpc_SpaceCenter_CelestialBody_t value) Returns the body the antenna points at, and sets the body to point at the center of. :Game Scenes: Flight .. note:: Requires RealAntennas. Also the body of a position the antenna points at, or ``nullptr`` if it points at neither. Throws an exception if set to ``nullptr``, or if the antenna cannot be pointed (see :func:`krpc_SpaceCenter_Antenna_CanTarget`). .. function:: krpc_error_t krpc_SpaceCenter_Antenna_TargetDirection(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Antenna_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The direction the antenna points in, in the given reference frame. Throws an exception if the antenna has no target (see :func:`krpc_SpaceCenter_Antenna_TargetMode`). :Parameters: * **referenceFrame** -- The reference frame that the returned direction is in. :returns: The direction as a unit vector. :Game Scenes: Flight .. note:: Requires RealAntennas. .. function:: krpc_error_t krpc_SpaceCenter_Antenna_SetTargetPosition(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, krpc_SpaceCenter_CelestialBody_t body, double latitude, double longitude, double altitude) Point the antenna at a position on or above a body. :Parameters: * **body** -- The body. * **latitude** -- The latitude, in degrees. * **longitude** -- The longitude, in degrees. * **altitude** -- The altitude above sea level, in meters. :Game Scenes: Flight .. note:: Requires RealAntennas. Throws an exception if the antenna cannot be pointed (see :func:`krpc_SpaceCenter_Antenna_CanTarget`). .. function:: krpc_error_t krpc_SpaceCenter_Antenna_SetTargetAzimuthElevation(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, double azimuth, double elevation) Point the antenna in a direction relative to the vessel's position on the surface. :Parameters: * **azimuth** -- The azimuth, in degrees clockwise from north, from 0 to 360. * **elevation** -- The elevation above the horizon, in degrees, from -90 to 90. :Game Scenes: Flight .. note:: Requires RealAntennas. Throws an exception if the antenna cannot be pointed (see :func:`krpc_SpaceCenter_Antenna_CanTarget`). .. function:: krpc_error_t krpc_SpaceCenter_Antenna_SetTargetOrbitRelative(krpc_connection_t connection, krpc_SpaceCenter_Antenna_t instance, double deflection, double elevation) Point the antenna in a direction relative to the vessel's orbital velocity. :Parameters: * **deflection** -- The angle from the orbital velocity in the orbital plane, in degrees, from -180 to 180. * **elevation** -- The angle out of the orbital plane, in degrees, from -90 to 90. :Game Scenes: Flight .. note:: Requires RealAntennas. Throws an exception if the antenna cannot be pointed (see :func:`krpc_SpaceCenter_Antenna_CanTarget`). .. type:: krpc_SpaceCenter_AntennaTargetMode_t The kind of target a RealAntennas antenna points at. See :func:`krpc_SpaceCenter_Antenna_TargetMode`. .. macro:: KRPC_ENUMERATION_SPACECENTER_ANTENNATARGETMODE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_NONE The antenna has no target. Omnidirectional antennas have none. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_VESSEL A vessel. See :func:`krpc_SpaceCenter_Antenna_TargetVessel`. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_BODY The center of a body. See :func:`krpc_SpaceCenter_Antenna_TargetBody`. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_POSITION A position on or above a body. See :func:`krpc_SpaceCenter_Antenna_SetTargetPosition`. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_AZIMUTHELEVATION An azimuth and elevation from the vessel's position. See :func:`krpc_SpaceCenter_Antenna_SetTargetAzimuthElevation`. .. macro:: KRPC_SPACECENTER_ANTENNATARGETMODE_ORBITRELATIVE A direction relative to the vessel's orbital velocity. See :func:`krpc_SpaceCenter_Antenna_SetTargetOrbitRelative`. Cargo Bay ^^^^^^^^^ .. type:: krpc_SpaceCenter_CargoBay_t A cargo bay. Obtained by calling :func:`krpc_SpaceCenter_Part_CargoBay`. .. macro:: KRPC_CLASS_SPACECENTER_CARGOBAY The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_CargoBay_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_CargoBay_t instance) The part object for this cargo bay. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_CargoBay_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_CargoBay_t instance) The state of the cargo bay. :Game Scenes: Flight .. note:: This describes where the bay's doors are, which is not the same as whether the parts inside are sheltered: a bay whose open end has nothing attached to it never shelters anything, however tightly shut it is. Use :func:`krpc_SpaceCenter_Part_Shielded` for that. A cargo bay is never :macro:`KRPC_SPACECENTER_DEPLOYABLESTATE_BROKEN`, as the game does not track damage for them. .. function:: krpc_error_t krpc_SpaceCenter_CargoBay_Open(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_CargoBay_t instance) .. function:: krpc_error_t krpc_SpaceCenter_CargoBay_set_Open(krpc_connection_t connection, krpc_SpaceCenter_CargoBay_t instance, bool value) Whether the cargo bay is open. :Game Scenes: Flight Control Surface ^^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_ControlSurface_t An aerodynamic control surface. Obtained by calling :func:`krpc_SpaceCenter_Part_ControlSurface`. .. macro:: KRPC_CLASS_SPACECENTER_CONTROLSURFACE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The part object for this control surface. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_PitchEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_PitchEnabled(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface has pitch control enabled. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_YawEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_YawEnabled(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface has yaw control enabled. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_RollEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_RollEnabled(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface has roll control enabled. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_AuthorityLimiter(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_AuthorityLimiter(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, float value) The authority limiter for the control surface, which controls how far the control surface will move. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_Inverted(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_Inverted(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface movement is inverted. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface has been fully deployed. Throws an exception if set while :func:`krpc_SpaceCenter_ControlSurface_DeflectionOverride` is enabled, which holds the surface deployed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_DeployAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_DeployAngle(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, float value) The deploy angle of the control surface, in degrees. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Applied when :func:`krpc_SpaceCenter_ControlSurface_Deployed` is true, and clamped to the range given by :func:`krpc_SpaceCenter_ControlSurface_MinDeployAngle` and :func:`krpc_SpaceCenter_ControlSurface_MaxDeployAngle`. While :func:`krpc_SpaceCenter_ControlSurface_DeflectionOverride` is enabled, :func:`krpc_SpaceCenter_ControlSurface_Deflection` drives the angle. A value set here takes effect when the override is released. .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_MinDeployAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The minimum :func:`krpc_SpaceCenter_ControlSurface_DeployAngle` of the control surface, in degrees. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_MaxDeployAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The maximum :func:`krpc_SpaceCenter_ControlSurface_DeployAngle` of the control surface, in degrees. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_DeflectionOverride(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_DeflectionOverride(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, bool value) Whether the control surface deflection is being set directly, bypassing the vessel's normal flight control. When enabled, the surface holds the deflection set by :func:`krpc_SpaceCenter_ControlSurface_Deflection` instead of responding to pitch, yaw and roll control inputs. The prior state is restored when the override is released, when the controlling client disconnects, or when the vessel changes. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_Deflection(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_set_Deflection(krpc_connection_t connection, krpc_SpaceCenter_ControlSurface_t instance, float value) The deflection command applied when :func:`krpc_SpaceCenter_ControlSurface_DeflectionOverride` is enabled, as a value between -1 and 1, mapped onto the surface's deploy angle range. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_DeflectionAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The current angle of the control surface from its neutral position, in degrees. Includes the :func:`krpc_SpaceCenter_ControlSurface_DeployAngle` while the surface is deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_ControlRange(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The angle the control surface deflects by for a full control input, in degrees, before the :func:`krpc_SpaceCenter_ControlSurface_AuthorityLimiter` is applied. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_ActuatorSpeed(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The rate the control surface deflects at, in degrees per second. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_SurfaceArea(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ControlSurface_t instance) Surface area of the control surface in :math:`\mathrm{m^{2}}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ControlSurface_AvailableTorque(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_ControlSurface_t instance) The available torque, in :math:`\mathrm{N \cdot m}`, that can be produced by this control surface, in the positive and negative pitch, roll and yaw axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. :Game Scenes: Flight Decoupler ^^^^^^^^^ .. type:: krpc_SpaceCenter_Decoupler_t A decoupler. Obtained by calling :func:`krpc_SpaceCenter_Part_Decoupler` .. macro:: KRPC_CLASS_SPACECENTER_DECOUPLER The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Decoupler_t instance) The part object for this decoupler. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_Decouple(krpc_connection_t connection, krpc_SpaceCenter_Vessel_t * returnValue, krpc_SpaceCenter_Decoupler_t instance) Fires the decoupler. Returns the new vessel created when the decoupler fires. Throws an exception if the decoupler has already fired. :Game Scenes: Flight .. note:: When called, the active vessel may change. It is therefore possible that, after calling this function, the object(s) returned by previous call(s) to :func:`krpc_SpaceCenter_ActiveVessel` no longer refer to the active vessel. .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_Decoupled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Decoupler_t instance) Whether the decoupler has fired. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_Staged(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Decoupler_t instance) Whether the decoupler is enabled in the staging sequence. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_Impulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Decoupler_t instance) The impulse that the decoupler imparts when it is fired, in :math:`\mathrm{N \cdot s}`. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_IsOmniDecoupler(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Decoupler_t instance) Whether the decoupler is an omni-decoupler (e.g. stack separator) :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Decoupler_AttachedPart(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Decoupler_t instance) The part attached to this decoupler's explosive node. :Game Scenes: Flight, Editor Vab, Editor Sph Deployable State ^^^^^^^^^^^^^^^^ The deployment state shared by antennas, cargo bays, landing legs, radiators, resource harvesters, solar panels and wheels. .. type:: krpc_SpaceCenter_DeployableState_t The state of a deployable part. :func:`krpc_SpaceCenter_Antenna_State`, :func:`krpc_SpaceCenter_CargoBay_State`, :func:`krpc_SpaceCenter_Leg_State`, :func:`krpc_SpaceCenter_Radiator_State`, :func:`krpc_SpaceCenter_ResourceHarvester_State`, :func:`krpc_SpaceCenter_SolarPanel_State`, :func:`krpc_SpaceCenter_Wheel_State` .. macro:: KRPC_ENUMERATION_SPACECENTER_DEPLOYABLESTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_DEPLOYABLESTATE_DEPLOYED The part is fully deployed. A cargo bay in this state is fully open. Parts that cannot be retracted, such as fixed radiators, solar panels, antennas, landing legs and wheels, are always in this state. .. macro:: KRPC_SPACECENTER_DEPLOYABLESTATE_RETRACTED The part is fully retracted. A cargo bay in this state is closed and locked. .. macro:: KRPC_SPACECENTER_DEPLOYABLESTATE_DEPLOYING The part is being deployed. A cargo bay in this state is opening. .. macro:: KRPC_SPACECENTER_DEPLOYABLESTATE_RETRACTING The part is being retracted. A cargo bay in this state is closing. .. macro:: KRPC_SPACECENTER_DEPLOYABLESTATE_BROKEN The part is broken. Cargo bays and resource harvesters never report this state, as the game does not track damage for them. Docking Port ^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_DockingPort_t A docking port. Obtained by calling :func:`krpc_SpaceCenter_Part_DockingPort` .. macro:: KRPC_CLASS_SPACECENTER_DOCKINGPORT The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_DockingPort_t instance) The part object for this docking port. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_State(krpc_connection_t connection, krpc_SpaceCenter_DockingPortState_t * returnValue, krpc_SpaceCenter_DockingPort_t instance) The current state of the docking port. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_DockedPart(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_DockingPort_t instance) The part that this docking port is docked to. Returns ``nullptr`` if this docking port is not docked to anything. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Undock(krpc_connection_t connection, krpc_SpaceCenter_Vessel_t * returnValue, krpc_SpaceCenter_DockingPort_t instance) Undocks the docking port and returns the new :type:`krpc_SpaceCenter_Vessel_t` that is created. This method can be called for either docking port in a docked pair. Throws an exception if the docking port is not docked to anything. :Game Scenes: Flight .. note:: When called, the active vessel may change. It is therefore possible that, after calling this function, the object(s) returned by previous call(s) to :func:`krpc_SpaceCenter_ActiveVessel` no longer refer to the active vessel. .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_ReengageDistance(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_DockingPort_t instance) The distance a docking port must move away when it undocks before it becomes ready to dock with another port, in meters. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_HasShield(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_DockingPort_t instance) Whether the docking port has a shield. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Shielded(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_DockingPort_t instance) .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_set_Shielded(krpc_connection_t connection, krpc_SpaceCenter_DockingPort_t instance, bool value) The state of the docking ports shield, if it has one. Returns ``true`` if the docking port has a shield, and the shield is closed. Otherwise returns ``false``. When set to ``true``, the shield is closed, and when set to ``false`` the shield is opened. If the docking port does not have a shield, setting this attribute has no effect. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_CanRotate(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_DockingPort_t instance) Whether the docking port can be commanded to rotate while docked. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_MaximumRotation(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_DockingPort_t instance) Maximum rotation angle in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_MinimumRotation(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_DockingPort_t instance) Minimum rotation angle in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_RotationTarget(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_DockingPort_t instance) .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_set_RotationTarget(krpc_connection_t connection, krpc_SpaceCenter_DockingPort_t instance, float value) Rotation target angle in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_RotationLocked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_DockingPort_t instance) .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_set_RotationLocked(krpc_connection_t connection, krpc_SpaceCenter_DockingPort_t instance, bool value) Lock rotation. When locked, allows auto-strut to work across the joint. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Position(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_DockingPort_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position of the docking port, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Direction(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_DockingPort_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The direction that docking port points in, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned direction is in. :returns: The direction as a unit vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_Rotation(krpc_connection_t connection, krpc_tuple_double_double_double_double_t * returnValue, krpc_SpaceCenter_DockingPort_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The rotation of the docking port, in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned rotation is in. :returns: The rotation as a quaternion of the form ``(x, y, z, w)``. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_DockingPort_ReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_ReferenceFrame_t * returnValue, krpc_SpaceCenter_DockingPort_t instance) The reference frame that is fixed relative to this docking port, and oriented with the port. * The origin is at the position of the docking port. * The axes rotate with the docking port. * The x-axis points out to the right side of the docking port. * The y-axis points in the direction the docking port is facing. * The z-axis points out of the bottom off the docking port. :Game Scenes: Flight .. note:: This reference frame is not necessarily equivalent to the reference frame for the part, returned by :func:`krpc_SpaceCenter_Part_ReferenceFrame`. .. figure:: /images/reference-frames/docking-port.png :align: center Docking port reference frame origin and axes .. figure:: /images/reference-frames/docking-port-inline.png :align: center Inline docking port reference frame origin and axes .. type:: krpc_SpaceCenter_DockingPortState_t The state of a docking port. See :func:`krpc_SpaceCenter_DockingPort_State`. .. macro:: KRPC_ENUMERATION_SPACECENTER_DOCKINGPORTSTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_READY The docking port is ready to dock to another docking port. .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_DOCKED The docking port is docked to another docking port, or docked to another part (from the VAB/SPH). .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_DOCKING The docking port is very close to another docking port, but has not docked. It is using magnetic force to acquire a solid dock. .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_UNDOCKING The docking port has just been undocked from another docking port, and is disabled until it moves away by a sufficient distance (:func:`krpc_SpaceCenter_DockingPort_ReengageDistance`). .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_SHIELDED The docking port has a shield, and the shield is closed. .. macro:: KRPC_SPACECENTER_DOCKINGPORTSTATE_MOVING The docking ports shield is currently opening/closing. Engine ^^^^^^ .. type:: krpc_SpaceCenter_Engine_t An engine, including ones of various types. For example liquid fuelled gimballed engines, solid rocket boosters and jet engines. Obtained by calling :func:`krpc_SpaceCenter_Part_Engine`. .. note:: For RCS thrusters :func:`krpc_SpaceCenter_Part_RCS`. .. macro:: KRPC_CLASS_SPACECENTER_ENGINE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Engine_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Engine_t instance) The part object for this engine. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_Active(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the engine is active. Setting this attribute may have no effect, depending on :func:`krpc_SpaceCenter_Engine_CanShutdown` and :func:`krpc_SpaceCenter_Engine_CanRestart`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_Thrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The current amount of thrust being produced by the engine, in Newtons. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_AvailableThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The amount of thrust, in Newtons, that would be produced by the engine when activated and with its throttle set to 100%. Returns zero if the engine does not have any fuel. Takes the engine's current :func:`krpc_SpaceCenter_Engine_ThrustLimit` and atmospheric conditions into account. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_AvailableThrustAt(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance, double pressure) The amount of thrust, in Newtons, that would be produced by the engine when activated and with its throttle set to 100%. Returns zero if the engine does not have any fuel. Takes the given pressure into account. :Parameters: * **pressure** -- Atmospheric pressure in atmospheres :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_MaxThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The amount of thrust, in Newtons, that would be produced by the engine when activated and fueled, with its throttle and throttle limiter set to 100%. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_MaxThrustAt(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance, double pressure) The amount of thrust, in Newtons, that would be produced by the engine when activated and fueled, with its throttle and throttle limiter set to 100%. Takes the given pressure into account. :Parameters: * **pressure** -- Atmospheric pressure in atmospheres :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_MaxVacuumThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The maximum amount of thrust that can be produced by the engine in a vacuum, in Newtons. This is the amount of thrust produced by the engine when activated, :func:`krpc_SpaceCenter_Engine_ThrustLimit` is set to 100%, the main vessel's throttle is set to 100% and the engine is in a vacuum. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_ThrustLimit(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_ThrustLimit(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, float value) The thrust limiter of the engine. A value between 0 and 1. Setting this attribute may have no effect, for example the thrust limit for a solid rocket booster cannot be changed in flight. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_Thrusters(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Engine_t instance) The components of the engine that generate thrust. :Game Scenes: Flight .. note:: For example, this corresponds to the rocket nozzel on a solid rocket booster, or the individual nozzels on a RAPIER engine. The overall thrust produced by the engine, as reported by :func:`krpc_SpaceCenter_Engine_AvailableThrust`, :func:`krpc_SpaceCenter_Engine_MaxThrust` and others, is the sum of the thrust generated by each thruster. .. function:: krpc_error_t krpc_SpaceCenter_Engine_SpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The current specific impulse of the engine, in seconds. Returns zero if the engine is not active. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_SpecificImpulseAt(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance, double pressure) The specific impulse of the engine under the given pressure, in seconds. Returns zero if the engine is not active. :Parameters: * **pressure** -- Atmospheric pressure in atmospheres :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_VacuumSpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The vacuum specific impulse of the engine, in seconds. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_KerbinSeaLevelSpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The specific impulse of the engine at sea level on Kerbin, in seconds. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_PropellantNames(krpc_connection_t connection, krpc_list_string_t * returnValue, krpc_SpaceCenter_Engine_t instance) The names of the propellants that the engine consumes. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_PropellantRatios(krpc_connection_t connection, krpc_dictionary_string_float_t * returnValue, krpc_SpaceCenter_Engine_t instance) The ratio of resources that the engine consumes. A dictionary mapping resource names to the ratio at which they are consumed by the engine. :Game Scenes: Flight .. note:: For example, if the ratios are 0.6 for LiquidFuel and 0.4 for Oxidizer, then for every 0.6 units of LiquidFuel that the engine burns, it will burn 0.4 units of Oxidizer. .. function:: krpc_error_t krpc_SpaceCenter_Engine_Propellants(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_Engine_t instance) The propellants that the engine consumes. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_HasFuel(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine has any fuel available. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_Flameout(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine has flamed out - it is active but has run out of propellant, so it is producing no thrust. This is the signal a client can use to decide when to activate the next stage. Note that on a vessel with drop tanks or asparagus staging some engines can flame out while others keep burning. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_Throttle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_Throttle(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, float value) The current throttle setting for the engine. A value between 0 and 1. This is not necessarily the same as the vessel's main throttle setting, as some engines take time to adjust their throttle (such as jet engines), or independent throttle may be enabled. When the engine's independent throttle is enabled (see :func:`krpc_SpaceCenter_Engine_IndependentThrottle`), can be used to set the throttle percentage. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_ThrottleLocked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the :func:`krpc_SpaceCenter_Control_Throttle` affects the engine. For example, this is ``true`` for liquid fueled rockets, and ``false`` for solid rocket boosters. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_IndependentThrottle(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_IndependentThrottle(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the independent throttle is enabled for the engine. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_CanRestart(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine can be restarted once shutdown. If the engine cannot be shutdown, returns ``false``. For example, this is ``true`` for liquid fueled rockets and ``false`` for solid rocket boosters. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_CanShutdown(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine can be shutdown once activated. For example, this is ``true`` for liquid fueled rockets and ``false`` for solid rocket boosters. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_HasModes(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine has multiple modes of operation. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_Mode(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_Mode(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, const char * value) The name of the current engine mode. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_Modes(krpc_connection_t connection, krpc_dictionary_string_object_t * returnValue, krpc_SpaceCenter_Engine_t instance) The available modes for the engine. A dictionary mapping mode names to :type:`krpc_SpaceCenter_Engine_t` objects. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_ToggleMode(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance) Toggle the current engine mode. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_AutoModeSwitch(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_AutoModeSwitch(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the engine will automatically switch modes. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_Gimballed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine is gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalRange(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The range over which the gimbal can move, in degrees. Returns 0 if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalLocked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalLocked(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the engines gimbal is locked in place. Setting this attribute has no effect if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalLimit(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalLimit(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, float value) The gimbal limiter of the engine. A value between 0 and 1. Returns 0 if the gimbal is locked. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalResponseSpeedEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the gimbal moves toward its commanded deflection at :func:`krpc_SpaceCenter_Engine_GimbalResponseSpeed`. When ``false``, the gimbal reaches its commanded deflection in one physics tick. Throws an exception if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalResponseSpeed(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Engine_t instance) The response speed of the gimbal, in :math:`\mathrm{s^{-1}}`. Throws an exception if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Each physics tick of length :math:`\Delta t`, the gimbal moves a fraction :math:`v \Delta t` of the way from its deflection to the commanded deflection, where :math:`v` is the response speed. The fraction is at most 1, so at high physics warp the gimbal can reach its commanded deflection in one tick. This lag only applies when :func:`krpc_SpaceCenter_Engine_GimbalResponseSpeedEnabled` is ``true``. .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalPitchEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalPitchEnabled(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the gimbal responds to pitch control input. Throws an exception if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalYawEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalYawEnabled(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the gimbal responds to yaw control input. Throws an exception if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalRollEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalRollEnabled(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the gimbal responds to roll control input. Throws an exception if the engine is not gimballed. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalOverride(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalOverride(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the gimbal is being controlled directly, bypassing the vessel's normal flight controls. When enabled, the gimbal deflection is set by :func:`krpc_SpaceCenter_Engine_GimbalActuation` instead of the normal control inputs. The override is automatically released if the controlling client disconnects or the vessel changes. Has no effect if the engine is not gimballed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_GimbalActuation(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_GimbalActuation(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, const krpc_tuple_double_double_double_t * value) The gimbal actuation command applied when :func:`krpc_SpaceCenter_Engine_GimbalOverride` is enabled, in the pitch, roll and yaw axes. Each component is a normalized control input between -1 and 1. The physical deflection is scaled by :func:`krpc_SpaceCenter_Engine_GimbalRange` and :func:`krpc_SpaceCenter_Engine_GimbalLimit`. When the gimbal is not being overridden, returns the current actuation. :Game Scenes: Flight .. note:: The gimbal ignores the component for an axis it is disabled for, such as pitch when :func:`krpc_SpaceCenter_Engine_GimbalPitchEnabled` is ``false``. .. function:: krpc_error_t krpc_SpaceCenter_Engine_AvailableTorque(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_Engine_t instance) The available torque, in :math:`\mathrm{N \cdot m}`, that can be produced by this engine, in the positive and negative pitch, roll and yaw axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. Returns zero if the engine is inactive, or not gimballed. :Game Scenes: Flight .. note:: The torque is zero about an axis the gimbal is disabled for, such as pitch when :func:`krpc_SpaceCenter_Engine_GimbalPitchEnabled` is ``false``. .. function:: krpc_error_t krpc_SpaceCenter_Engine_CanReverseThrust(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine has a recognized thrust reverser. This is ``true`` for stock engines with a thrust reverser (such as the J-33 "Wheesley" and J-90 "Goliath" turbofan engines) and for supported mod engines. It is ``false`` for engines whose reverser is not recognized, as KSP provides no standard way to detect one. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Recognizes the thrust reversers of Firespitter and KerbalActuators. .. function:: krpc_error_t krpc_SpaceCenter_Engine_ThrustReversed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Engine_set_ThrustReversed(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance, bool value) Whether the engine's thrust reverser is engaged, reversing the direction of thrust. While the reverser is still moving, this reports the state it is moving to, so a read immediately after a set returns the value that was set and setting the same value again has no effect. Throws an exception if the engine does not have a thrust reverser (see :func:`krpc_SpaceCenter_Engine_CanReverseThrust`). :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_ToggleThrustReversal(krpc_connection_t connection, krpc_SpaceCenter_Engine_t instance) Toggle the engine's thrust reverser. Throws an exception if the engine does not have a thrust reverser (see :func:`krpc_SpaceCenter_Engine_CanReverseThrust`). :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Engine_HasRealFuels(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine is managed by RealFuels. The remaining properties in this section are only available when it is. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Engine_Ignitions(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_Engine_t instance) The number of times the engine can still be ignited, or -1 if it can be ignited an unlimited number of times. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_IgnitionResources(krpc_connection_t connection, krpc_dictionary_string_double_t * returnValue, krpc_SpaceCenter_Engine_t instance) The resources the engine consumes each time it ignites, keyed by resource name, with the amount of each that is required. The engine uses up an ignition and fails to light if they are not available. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_HasUllage(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine's propellant is subject to ullage, so that it must be settled before the engine will run reliably. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_PropellantStability(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Engine_t instance) How settled the propellant feeding the engine is, from 0 (fully unsettled) to 1 (fully settled). Acceleration along the engine's thrust axis settles it, and coasting and rotation unsettle it. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_PropellantReliability(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Engine_t instance) The probability that the propellant feeding the engine behaves normally, from 0 to 1. This is :func:`krpc_SpaceCenter_Engine_PropellantStability` scaled by the game's ullage difficulty setting, and is the value RealFuels itself tests against when deciding whether the engine runs. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_PressureFed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the engine is fed by tank pressure rather than by a pump, and so needs to draw from a highly pressurized tank. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: Requires RealFuels. .. function:: krpc_error_t krpc_SpaceCenter_Engine_HasFeedPressure(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Engine_t instance) Whether the tanks feeding the engine supply the pressure it needs. Always ``true`` for an engine that is not pressure fed. Throws an exception if the engine is not managed by RealFuels (see :func:`krpc_SpaceCenter_Engine_HasRealFuels`). :Game Scenes: Flight .. note:: Requires RealFuels. .. type:: krpc_SpaceCenter_Propellant_t A propellant for an engine. Obtains by calling :func:`krpc_SpaceCenter_Engine_Propellants`. .. macro:: KRPC_CLASS_SPACECENTER_PROPELLANT The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Propellant_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Propellant_t instance) The name of the propellant. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_CurrentAmount(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Propellant_t instance) The current amount of propellant consumed in the current physics update. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_CurrentRequirement(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Propellant_t instance) The required amount of propellant for the current physics update. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_TotalResourceAvailable(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Propellant_t instance) The total amount of the underlying resource currently reachable given resource flow rules. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_TotalResourceCapacity(krpc_connection_t connection, double * returnValue, krpc_SpaceCenter_Propellant_t instance) The total vehicle capacity for the underlying propellant resource, restricted by resource flow rules. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_IgnoreForIsp(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Propellant_t instance) If this propellant should be ignored when calculating required mass flow given specific impulse. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_IgnoreForThrustCurve(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Propellant_t instance) If this propellant should be ignored for thrust curve calculations. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_DrawStackGauge(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Propellant_t instance) If this propellant has a stack gauge or not. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_IsDeprived(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Propellant_t instance) If this propellant is deprived. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Propellant_Ratio(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Propellant_t instance) The propellant ratio. :Game Scenes: Flight Experiment ^^^^^^^^^^ .. type:: krpc_SpaceCenter_Experiment_t Obtained by calling :func:`krpc_SpaceCenter_Part_Experiment`. .. note:: Includes the experiments of DMagic's DMModuleScienceAnimateGeneric. .. macro:: KRPC_CLASS_SPACECENTER_EXPERIMENT The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Experiment_t instance) The part object for this experiment. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Experiment_t instance) Internal name of the experiment, as used in `part cfg files `_. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Title(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Experiment_t instance) Title of the experiment, as shown on the in-game UI. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Run(krpc_connection_t connection, krpc_SpaceCenter_Experiment_t instance) Run the experiment. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Transmit(krpc_connection_t connection, krpc_SpaceCenter_Experiment_t instance) Transmit all experimental data contained by this part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Dump(krpc_connection_t connection, krpc_SpaceCenter_Experiment_t instance) Dump the experimental data contained by the experiment. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Reset(krpc_connection_t connection, krpc_SpaceCenter_Experiment_t instance) Reset the experiment. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Experiment_t instance) Whether the experiment has been deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Rerunnable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Experiment_t instance) Whether the experiment can be re-run. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Inoperable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Experiment_t instance) Whether the experiment is inoperable. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_HasData(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Experiment_t instance) Whether the experiment contains data. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Data(krpc_connection_t connection, krpc_list_SpaceCenter_ScienceData_t * returnValue, krpc_SpaceCenter_Experiment_t instance) The data contained in this experiment. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Biome(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Experiment_t instance) The name of the biome the experiment is currently in. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_Available(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Experiment_t instance) Determines if the experiment is available given the current conditions. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Experiment_ScienceSubject(krpc_connection_t connection, krpc_SpaceCenter_ScienceSubject_t * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Experiment_t instance) Containing information on the corresponding specific science result for the current conditions. Returns ``nullptr`` if the experiment is unavailable. :Game Scenes: Flight .. type:: krpc_SpaceCenter_ScienceData_t Obtained by calling :func:`krpc_SpaceCenter_Experiment_Data`. .. macro:: KRPC_STRUCT_SPACECENTER_SCIENCEDATA The service and structure ids of the structure, for :func:`krpc_KRPC_Type_StructTypeById`. .. member:: float data_amount Data amount. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCEDATA_DATAAMOUNT The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float science_value Science value. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCEDATA_SCIENCEVALUE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float transmit_value Transmit value. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCEDATA_TRANSMITVALUE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. type:: krpc_SpaceCenter_ScienceSubject_t Obtained by calling :func:`krpc_SpaceCenter_Experiment_ScienceSubject`. .. macro:: KRPC_STRUCT_SPACECENTER_SCIENCESUBJECT The service and structure ids of the structure, for :func:`krpc_KRPC_Type_StructTypeById`. .. member:: char * id The identifier of the subject, e.g. ``crewReport@KerbinSrfLandedLaunchPad``. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_ID The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: char * title The title of the subject, as shown in the science archives. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_TITLE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: bool is_complete Whether the subject has been fully researched. This is true once the science banked for the subject reaches the science cap. As the banked science (see :member:`krpc_SpaceCenter_ScienceSubject_t.science`) is only updated after transmission/recovery, this reflects fully mining the subject over repeated experiments, not whether a single run has produced data. To check whether a run has produced data, and how valuable it is, use :func:`krpc_SpaceCenter_Experiment_HasData` and :member:`krpc_SpaceCenter_ScienceData_t.transmit_value`. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_ISCOMPLETE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float science Amount of science already earned from this subject, not updated until after transmission/recovery. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_SCIENCE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float science_cap Total science allowable for this subject. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_SCIENCECAP The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float data_scale Multiply science value by this to determine data amount in mits. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_DATASCALE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float subject_value Multiplier for specific Celestial Body/Experiment Situation combination. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_SUBJECTVALUE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: float scientific_value Diminishing value multiplier for decreasing the science value returned from repeated experiments. .. macro:: KRPC_FIELD_SPACECENTER_SCIENCESUBJECT_SCIENTIFICVALUE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. Fairing ^^^^^^^ .. type:: krpc_SpaceCenter_Fairing_t A fairing. Obtained by calling :func:`krpc_SpaceCenter_Part_Fairing`. .. note:: Includes the fairings of ProceduralFairings. .. macro:: KRPC_CLASS_SPACECENTER_FAIRING The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Fairing_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Fairing_t instance) The part object for this fairing. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Fairing_Jettison(krpc_connection_t connection, krpc_SpaceCenter_Fairing_t instance) Jettison the fairing. Has no effect if it has already been jettisoned. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Fairing_Jettisoned(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Fairing_t instance) Whether the fairing has been jettisoned. :Game Scenes: Flight Intake ^^^^^^ .. type:: krpc_SpaceCenter_Intake_t An air intake. Obtained by calling :func:`krpc_SpaceCenter_Part_Intake`. .. macro:: KRPC_CLASS_SPACECENTER_INTAKE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Intake_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Intake_t instance) The part object for this intake. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Intake_Open(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Intake_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Intake_set_Open(krpc_connection_t connection, krpc_SpaceCenter_Intake_t instance, bool value) Whether the intake is open. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Intake_Speed(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Intake_t instance) Speed of the flow into the intake, in :math:`\mathrm{m/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Intake_Flow(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Intake_t instance) The rate of flow into the intake, in units of resource per second. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Intake_Area(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Intake_t instance) The area of the intake's opening, in :math:`\mathrm{m^{2}}`. :Game Scenes: Flight, Editor Vab, Editor Sph Leg ^^^ .. type:: krpc_SpaceCenter_Leg_t A landing leg. Obtained by calling :func:`krpc_SpaceCenter_Part_Leg`. .. macro:: KRPC_CLASS_SPACECENTER_LEG The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Leg_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Leg_t instance) The part object for this landing leg. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Leg_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_Leg_t instance) The current state of the landing leg. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Leg_Deployable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Leg_t instance) Whether the leg is deployable. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Leg_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Leg_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Leg_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_Leg_t instance, bool value) Whether the landing leg is deployed. :Game Scenes: Flight .. note:: Fixed landing legs are always deployed. Throws :macro:`KRPC_EXCEPTION_KRPC_INVALIDOPERATIONEXCEPTION` if set on a fixed landing leg. .. function:: krpc_error_t krpc_SpaceCenter_Leg_IsGrounded(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Leg_t instance) Returns whether the leg is touching the ground. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Leg_Load(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) The force pressing the leg's foot into the ground, in :math:`\mathrm{kN}`. :Game Scenes: Flight .. note:: The game raises the load of a grounded leg to at least 10 kN. :func:`krpc_SpaceCenter_Leg_ImpactTolerance` applies to the rise in this value. .. function:: krpc_error_t krpc_SpaceCenter_Leg_ContactPosition(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Leg_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position of the bottom of the leg's foot, in the given reference frame. While the leg is grounded, this is where it touches the ground. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Leg_SuspensionSpringStrength(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) Suspension spring strength, as set in the editor. Throws an exception if the leg has no suspension. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Leg_SuspensionDamperStrength(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) Suspension damper strength, as set in the editor. Throws an exception if the leg has no suspension. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Leg_SuspensionSpring(krpc_connection_t connection, float * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Leg_t instance) The spring constant of the suspension, in :math:`\mathrm{kN/m}`, or ``nullptr`` while the leg is not grounded. :Game Scenes: Flight .. note:: The game updates it while the leg is grounded, from :func:`krpc_SpaceCenter_Leg_SuspensionSpringStrength`, the vessel's mass, the leg's compression and the local gravity. .. function:: krpc_error_t krpc_SpaceCenter_Leg_SuspensionDamper(krpc_connection_t connection, float * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Leg_t instance) The damping constant of the suspension, in :math:`\mathrm{kN \cdot s/m}`, or ``nullptr`` while the leg is not grounded. :Game Scenes: Flight .. note:: The game updates it while the leg is grounded, from :func:`krpc_SpaceCenter_Leg_SuspensionDamperStrength` and :func:`krpc_SpaceCenter_Leg_SuspensionSpring`. .. function:: krpc_error_t krpc_SpaceCenter_Leg_SuspensionTravel(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) The travel of the suspension, in meters. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Leg_ImpactTolerance(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) The rise in :func:`krpc_SpaceCenter_Leg_Load` over one physics tick that breaks the leg, in :math:`\mathrm{kN}`. Throws an exception if the leg is not breakable. :Game Scenes: Flight, Editor Vab, Editor Sph .. note:: The game scales the rise by the local gravity divided by standard gravity before comparing it with this tolerance. .. function:: krpc_error_t krpc_SpaceCenter_Leg_ExplodeMultiplier(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Leg_t instance) The multiple of :func:`krpc_SpaceCenter_Leg_ImpactTolerance` that destroys the leg, in place of breaking it. Throws an exception if the leg is not breakable. :Game Scenes: Flight, Editor Vab, Editor Sph Launch Clamp ^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_LaunchClamp_t A launch clamp. Obtained by calling :func:`krpc_SpaceCenter_Part_LaunchClamp`. .. macro:: KRPC_CLASS_SPACECENTER_LAUNCHCLAMP The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_LaunchClamp_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_LaunchClamp_t instance) The part object for this launch clamp. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_LaunchClamp_Release(krpc_connection_t connection, krpc_SpaceCenter_LaunchClamp_t instance) Releases the docking clamp. Has no effect if the clamp has already been released. :Game Scenes: Flight Light ^^^^^ .. type:: krpc_SpaceCenter_Light_t A light. Obtained by calling :func:`krpc_SpaceCenter_Part_Light`. .. macro:: KRPC_CLASS_SPACECENTER_LIGHT The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Light_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Light_t instance) The part object for this light. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Light_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Light_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Light_set_Active(krpc_connection_t connection, krpc_SpaceCenter_Light_t instance, bool value) Whether the light is switched on. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Light_Color(krpc_connection_t connection, krpc_StdLib_ColorRGB_t * returnValue, krpc_SpaceCenter_Light_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Light_set_Color(krpc_connection_t connection, krpc_SpaceCenter_Light_t instance, const krpc_StdLib_ColorRGB_t * value) The color of the light. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Light_Blink(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Light_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Light_set_Blink(krpc_connection_t connection, krpc_SpaceCenter_Light_t instance, bool value) Whether blinking is enabled. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Light_BlinkRate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Light_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Light_set_BlinkRate(krpc_connection_t connection, krpc_SpaceCenter_Light_t instance, float value) The blink rate of the light. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Light_PowerUsage(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Light_t instance) The current power usage, in units of charge per second. :Game Scenes: Flight Parachute ^^^^^^^^^ .. type:: krpc_SpaceCenter_Parachute_t A parachute. Obtained by calling :func:`krpc_SpaceCenter_Part_Parachute`. .. note:: Includes the parachutes of RealChute. .. macro:: KRPC_CLASS_SPACECENTER_PARACHUTE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Parachute_t instance) The part object for this parachute. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Deploy(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t instance) Deploys the parachute. This has no effect if the parachute has already been deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Parachute_t instance) Whether the parachute has been deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Arm(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t instance) Deploys the parachute. This has no effect if the parachute has already been armed or deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Armed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Parachute_t instance) Whether the parachute has been armed or deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_Cut(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t instance) Cuts the parachute. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_State(krpc_connection_t connection, krpc_SpaceCenter_ParachuteState_t * returnValue, krpc_SpaceCenter_Parachute_t instance) The current state of the parachute. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Parachute_DeployAltitude(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Parachute_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Parachute_set_DeployAltitude(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t instance, float value) The altitude at which the parachute will full deploy, in meters. Only applicable to stock parachutes. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Parachute_DeployMinPressure(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Parachute_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Parachute_set_DeployMinPressure(krpc_connection_t connection, krpc_SpaceCenter_Parachute_t instance, float value) The minimum pressure at which the parachute will semi-deploy, in atmospheres. Only applicable to stock parachutes. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Parachute_SafeState(krpc_connection_t connection, krpc_SpaceCenter_ParachuteSafeState_t * returnValue, krpc_SpaceCenter_Parachute_t instance) Whether it is currently safe to deploy the parachute, given the vessel's flight conditions. Computed by KSP from the current airspeed, pressure and temperature. Only applicable to stock parachutes. Note that KSP reports :macro:`KRPC_SPACECENTER_PARACHUTESAFESTATE_UNSAFE` for the first second after the vessel unpacks, before its thermal data is valid. :Game Scenes: Flight .. type:: krpc_SpaceCenter_ParachuteState_t The state of a parachute. See :func:`krpc_SpaceCenter_Parachute_State`. .. macro:: KRPC_ENUMERATION_SPACECENTER_PARACHUTESTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_PARACHUTESTATE_STOWED The parachute is safely tucked away inside its housing. .. macro:: KRPC_SPACECENTER_PARACHUTESTATE_ARMED The parachute is armed for deployment. .. macro:: KRPC_SPACECENTER_PARACHUTESTATE_SEMIDEPLOYED The parachute has been deployed and is providing some drag, but is not fully deployed yet. (Stock parachutes only) .. macro:: KRPC_SPACECENTER_PARACHUTESTATE_DEPLOYED The parachute is fully deployed. .. macro:: KRPC_SPACECENTER_PARACHUTESTATE_CUT The parachute has been cut. .. type:: krpc_SpaceCenter_ParachuteSafeState_t The safety state of deploying a parachute. See :func:`krpc_SpaceCenter_Parachute_SafeState`. .. macro:: KRPC_ENUMERATION_SPACECENTER_PARACHUTESAFESTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_PARACHUTESAFESTATE_SAFE The parachute is safe to deploy. .. macro:: KRPC_SPACECENTER_PARACHUTESAFESTATE_RISKY Deploying the parachute is risky, and it may break off. .. macro:: KRPC_SPACECENTER_PARACHUTESAFESTATE_UNSAFE The parachute is unsafe to deploy, and will break off. .. macro:: KRPC_SPACECENTER_PARACHUTESAFESTATE_NONE The safety state is not available, because the vessel is not in an atmosphere or the parachute has already been deployed or cut. Radiator ^^^^^^^^ .. type:: krpc_SpaceCenter_Radiator_t A radiator. Obtained by calling :func:`krpc_SpaceCenter_Part_Radiator`. .. macro:: KRPC_CLASS_SPACECENTER_RADIATOR The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Radiator_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Radiator_t instance) The part object for this radiator. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Radiator_Deployable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Radiator_t instance) Whether the radiator is deployable. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Radiator_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Radiator_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Radiator_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_Radiator_t instance, bool value) For a deployable radiator, ``true`` if the radiator is extended. If the radiator is not deployable, this is always ``true``. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Radiator_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_Radiator_t instance) The current state of the radiator. :Game Scenes: Flight .. note:: A fixed radiator is always :macro:`KRPC_SPACECENTER_DEPLOYABLESTATE_DEPLOYED`. Resource Converter ^^^^^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_ResourceConverter_t A resource converter. Obtained by calling :func:`krpc_SpaceCenter_Part_ResourceConverter`. .. macro:: KRPC_CLASS_SPACECENTER_RESOURCECONVERTER The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_ResourceConverter_t instance) The part object for this converter. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Count(krpc_connection_t connection, int32_t * returnValue, krpc_SpaceCenter_ResourceConverter_t instance) The number of converters in the part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Name(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) The name of the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) True if the specified converter is active. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Start(krpc_connection_t connection, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) Start the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Stop(krpc_connection_t connection, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) Stop the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_State(krpc_connection_t connection, krpc_SpaceCenter_ResourceConverterState_t * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) The state of the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_StatusInfo(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) Status information for the specified converter. This is the full status message shown in the in-game UI. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Inputs(krpc_connection_t connection, krpc_list_string_t * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) List of the names of resources consumed by the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_Outputs(krpc_connection_t connection, krpc_list_string_t * returnValue, krpc_SpaceCenter_ResourceConverter_t instance, int32_t index) List of the names of resources produced by the specified converter. :Parameters: * **index** -- Index of the converter. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_OptimumCoreTemperature(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceConverter_t instance) The core temperature at which the converter will operate with peak efficiency, in Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_CoreTemperature(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceConverter_t instance) The core temperature of the converter, in Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceConverter_ThermalEfficiency(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceConverter_t instance) The thermal efficiency of the converter, as a percentage of its maximum. :Game Scenes: Flight .. type:: krpc_SpaceCenter_ResourceConverterState_t The state of a resource converter. See :func:`krpc_SpaceCenter_ResourceConverter_State`. .. macro:: KRPC_ENUMERATION_SPACECENTER_RESOURCECONVERTERSTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_RUNNING Converter is running. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_IDLE Converter is idle. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_MISSINGRESOURCE Converter is missing a required resource. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_STORAGEFULL No available storage for output resource. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_CAPACITY At preset resource capacity. .. macro:: KRPC_SPACECENTER_RESOURCECONVERTERSTATE_UNKNOWN Unknown state. Possible with modified resource converters. In this case, check :func:`krpc_SpaceCenter_ResourceConverter_StatusInfo` for more information. Resource Harvester ^^^^^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_ResourceHarvester_t A resource harvester (drill). Obtained by calling :func:`krpc_SpaceCenter_Part_ResourceHarvester`. .. macro:: KRPC_CLASS_SPACECENTER_RESOURCEHARVESTER The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The part object for this harvester. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The deployment state of the harvester. Whether it is drilling is reported separately by :func:`krpc_SpaceCenter_ResourceHarvester_Active`. :Game Scenes: Flight .. note:: A harvester is never :macro:`KRPC_SPACECENTER_DEPLOYABLESTATE_BROKEN`, as the game does not track damage for them. .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_ResourceHarvester_t instance, bool value) Whether the harvester is deployed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_set_Active(krpc_connection_t connection, krpc_SpaceCenter_ResourceHarvester_t instance, bool value) Whether the harvester is actively drilling. :Game Scenes: Flight .. note:: A value set while the harvester is deploying is applied when the deploy completes, so it can be set immediately after setting :func:`krpc_SpaceCenter_ResourceHarvester_Deployed` without waiting for the deploy animation. Setting it has no effect while the harvester is retracted or retracting. .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_ExtractionRate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The rate at which the drill is extracting ore, in :math:`\mathrm{units/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_ThermalEfficiency(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The thermal efficiency of the drill, as a percentage of its maximum. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_CoreTemperature(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The core temperature of the drill, in Kelvin. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceHarvester_OptimumCoreTemperature(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceHarvester_t instance) The core temperature at which the drill will operate with peak efficiency, in Kelvin. :Game Scenes: Flight Reaction Wheel ^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_ReactionWheel_t A reaction wheel. Obtained by calling :func:`krpc_SpaceCenter_Part_ReactionWheel`. .. macro:: KRPC_CLASS_SPACECENTER_REACTIONWHEEL The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) The part object for this reaction wheel. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_set_Active(krpc_connection_t connection, krpc_SpaceCenter_ReactionWheel_t instance, bool value) Whether the reaction wheel is active. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_Broken(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) Whether the reaction wheel is broken. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_AvailableTorque(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) The available torque, in :math:`\mathrm{N \cdot m}`, that can be produced by this reaction wheel, in the positive and negative pitch, roll and yaw axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. Returns zero if the reaction wheel is inactive or broken. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_MaxTorque(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) The maximum torque, in :math:`\mathrm{N \cdot m}`, that can be produced by this reaction wheel, when it is active, in the positive and negative pitch, roll and yaw axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_AuthorityLimiter(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ReactionWheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ReactionWheel_set_AuthorityLimiter(krpc_connection_t connection, krpc_SpaceCenter_ReactionWheel_t instance, float value) The authority limiter for the reaction wheel, as a percentage of maximum torque. A value between 0 and 1. :Game Scenes: Flight, Editor Vab, Editor Sph Resource Drain ^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_ResourceDrain_t A resource drain. Obtained by calling :func:`krpc_SpaceCenter_Part_ResourceDrain`. .. macro:: KRPC_CLASS_SPACECENTER_RESOURCEDRAIN The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) The part object for this resource drain. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_AvailableResources(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) List of available resources. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_SetResource(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t instance, krpc_SpaceCenter_Resource_t resource, bool enabled) Whether the given resource should be drained. :Parameters: :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_CheckResource(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_ResourceDrain_t instance, krpc_SpaceCenter_Resource_t resource) Whether the provided resource is enabled for draining. :Parameters: :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_DrainMode(krpc_connection_t connection, krpc_SpaceCenter_DrainMode_t * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_set_DrainMode(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t instance, krpc_SpaceCenter_DrainMode_t value) The drain mode. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_MinRate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) Minimum possible drain rate :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_MaxRate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) Maximum possible drain rate. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_Rate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_ResourceDrain_t instance) .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_set_Rate(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t instance, float value) Current drain rate. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_Start(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t instance) Activates resource draining for all enabled parts. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_ResourceDrain_Stop(krpc_connection_t connection, krpc_SpaceCenter_ResourceDrain_t instance) Turns off resource draining. :Game Scenes: Flight .. type:: krpc_SpaceCenter_DrainMode_t Resource drain mode. See :func:`krpc_SpaceCenter_ResourceDrain_DrainMode`. .. macro:: KRPC_ENUMERATION_SPACECENTER_DRAINMODE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_DRAINMODE_PART Drains from the parent part. .. macro:: KRPC_SPACECENTER_DRAINMODE_VESSEL Drains from all available parts. Robotic Controller ^^^^^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_RoboticController_t A robotic controller. Obtained by calling :func:`krpc_SpaceCenter_Part_RoboticController`. .. macro:: KRPC_CLASS_SPACECENTER_ROBOTICCONTROLLER The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RoboticController_t instance) The part object for this controller. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Enabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_set_Enabled(krpc_connection_t connection, krpc_SpaceCenter_RoboticController_t instance, bool value) Whether the controller is enabled. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Playing(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance) Whether the controller's sequence is currently playing. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Position(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticController_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_set_Position(krpc_connection_t connection, krpc_SpaceCenter_RoboticController_t instance, float value) The current position along the sequence, in seconds. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Length(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticController_t instance) The length of the sequence, in seconds. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_PlaySpeed(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticController_t instance) The speed at which the sequence is played back, as a multiple of normal speed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Play(krpc_connection_t connection, krpc_SpaceCenter_RoboticController_t instance) Start playing the controller's sequence. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Stop(krpc_connection_t connection, krpc_SpaceCenter_RoboticController_t instance) Stop playing the controller's sequence. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_HasPart(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance, krpc_SpaceCenter_Part_t part) Whether the controller has a part. :Parameters: :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_Axes(krpc_connection_t connection, krpc_list_SpaceCenter_RoboticAxis_t * returnValue, krpc_SpaceCenter_RoboticController_t instance) The axes for the controller. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_AddAxis(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance, krpc_SpaceCenter_Module_t module, const char * fieldName) Add an axis to the controller. :Parameters: * **module** -- The part module that the axis belongs to. * **fieldName** -- The name of the axis field, as returned by :func:`krpc_SpaceCenter_RoboticController_Axes`. :returns: Returns ``true`` if the axis is added successfully. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_AddKeyFrame(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance, krpc_SpaceCenter_Module_t module, const char * fieldName, float time, float value) Add key frame value for controller axis. :Parameters: * **module** -- The part module that the axis belongs to. * **fieldName** -- The name of the axis field, as returned by :func:`krpc_SpaceCenter_RoboticController_Axes`. * **time** -- The time of the key frame. * **value** -- The value of the key frame. :returns: Returns ``true`` if the key frame is added successfully. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticController_ClearAxis(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticController_t instance, krpc_SpaceCenter_Module_t module, const char * fieldName) Clear axis. :Parameters: * **module** -- The part module that the axis belongs to. * **fieldName** -- The name of the axis field, as returned by :func:`krpc_SpaceCenter_RoboticController_Axes`. :returns: Returns ``true`` if the axis is cleared successfully. :Game Scenes: Flight .. type:: krpc_SpaceCenter_RoboticAxis_t An axis of a robotic controller. .. note:: See :func:`krpc_SpaceCenter_RoboticController_Axes`. .. macro:: KRPC_STRUCT_SPACECENTER_ROBOTICAXIS The service and structure ids of the structure, for :func:`krpc_KRPC_Type_StructTypeById`. .. member:: krpc_SpaceCenter_Module_t module The part module the axis belongs to. .. macro:: KRPC_FIELD_SPACECENTER_ROBOTICAXIS_MODULE The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. .. member:: char * field_name The name of the field the axis controls. .. macro:: KRPC_FIELD_SPACECENTER_ROBOTICAXIS_FIELDNAME The position of the field, for :func:`krpc_KRPC_Expression_GetFieldByIndex`. Robotic Hinge ^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_RoboticHinge_t A robotic hinge. Obtained by calling :func:`krpc_SpaceCenter_Part_RoboticHinge`. .. macro:: KRPC_CLASS_SPACECENTER_ROBOTICHINGE The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) The part object for this robotic hinge. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_TargetAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_TargetAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, float value) Target angle. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_CurrentAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) Current angle. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_MinAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_MinAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, float value) The minimum angle the hinge can move to, in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_MaxAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_MaxAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, float value) The maximum angle the hinge can move to, in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_Rate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_Rate(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, float value) Target movement rate in :math:`\mathrm{{}^{\circ}/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_Damping(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_Damping(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, float value) Damping percentage. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_Locked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_Locked(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, bool value) Lock movement. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_MotorEngaged(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_set_MotorEngaged(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance, bool value) Whether the motor is engaged. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_IsMoving(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticHinge_t instance) Whether the servo is currently moving. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticHinge_MoveHome(krpc_connection_t connection, krpc_SpaceCenter_RoboticHinge_t instance) Move hinge to its built position. :Game Scenes: Flight Robotic Piston ^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_RoboticPiston_t A robotic piston part. Obtained by calling :func:`krpc_SpaceCenter_Part_RoboticPiston`. .. macro:: KRPC_CLASS_SPACECENTER_ROBOTICPISTON The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) The part object for this robotic piston. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_TargetExtension(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_TargetExtension(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, float value) Target extension of the piston. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_CurrentExtension(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) Current extension of the piston. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_MinExtension(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_MinExtension(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, float value) The minimum extension of the piston, in meters. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_MaxExtension(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_MaxExtension(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, float value) The maximum extension of the piston, in meters. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_Rate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_Rate(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, float value) Target movement rate in :math:`\mathrm{m/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_Damping(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_Damping(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, float value) Damping percentage. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_Locked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_Locked(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, bool value) Lock movement. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_MotorEngaged(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_set_MotorEngaged(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance, bool value) Whether the motor is engaged. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_IsMoving(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticPiston_t instance) Whether the servo is currently moving. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticPiston_MoveHome(krpc_connection_t connection, krpc_SpaceCenter_RoboticPiston_t instance) Move piston to its built position. :Game Scenes: Flight Robotic Rotation ^^^^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_RoboticRotation_t A robotic rotation servo. Obtained by calling :func:`krpc_SpaceCenter_Part_RoboticRotation`. .. macro:: KRPC_CLASS_SPACECENTER_ROBOTICROTATION The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) The part object for this robotic rotation servo. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_TargetAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_TargetAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, float value) Target angle. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_CurrentAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) Current angle. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_MinAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_MinAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, float value) The minimum angle the servo can rotate to, in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_MaxAngle(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_MaxAngle(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, float value) The maximum angle the servo can rotate to, in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_AllowFullRotation(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_AllowFullRotation(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, bool value) Whether the servo is allowed to rotate freely through a full revolution, ignoring the angle limits. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_Rate(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_Rate(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, float value) Target movement rate in :math:`\mathrm{{}^{\circ}/s}`. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_Damping(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_Damping(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, float value) Damping percentage. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_Locked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_Locked(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, bool value) Lock Movement :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_MotorEngaged(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_set_MotorEngaged(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance, bool value) Whether the motor is engaged. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_IsMoving(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotation_t instance) Whether the servo is currently moving. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotation_MoveHome(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotation_t instance) Move rotation servo to its built position. :Game Scenes: Flight Robotic Rotor ^^^^^^^^^^^^^ .. type:: krpc_SpaceCenter_RoboticRotor_t A robotic rotor. Obtained by calling :func:`krpc_SpaceCenter_Part_RoboticRotor`. .. macro:: KRPC_CLASS_SPACECENTER_ROBOTICROTOR The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) The part object for this robotic rotor. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_TargetRPM(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_TargetRPM(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, float value) Target RPM. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_CurrentRPM(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) Current RPM. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_Inverted(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_Inverted(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, bool value) Whether the rotor direction is inverted. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_TorqueLimit(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_TorqueLimit(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, float value) Torque limit percentage. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_MaxTorque(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_MaxTorque(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, float value) The maximum torque the rotor can generate, in kilonewtons. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_BrakePercentage(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_BrakePercentage(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, float value) The percentage of braking force applied to the rotor. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_Locked(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_Locked(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, bool value) Lock movement. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_MotorEngaged(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_set_MotorEngaged(krpc_connection_t connection, krpc_SpaceCenter_RoboticRotor_t instance, bool value) Whether the motor is engaged. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RoboticRotor_IsMoving(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RoboticRotor_t instance) Whether the rotor is currently moving. :Game Scenes: Flight RCS ^^^ .. type:: krpc_SpaceCenter_RCS_t An RCS block or thruster. Obtained by calling :func:`krpc_SpaceCenter_Part_RCS`. .. macro:: KRPC_CLASS_SPACECENTER_RCS The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_RCS_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_RCS_t instance) The part object for this RCS. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) Whether the RCS thrusters are active. An RCS thruster is inactive if the RCS action group is disabled (:func:`krpc_SpaceCenter_Control_RCS`), the RCS thruster itself is not enabled (:func:`krpc_SpaceCenter_RCS_Enabled`), or it is covered by a fairing (:func:`krpc_SpaceCenter_Part_Shielded`) and cannot thrust while shielded. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_Enabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_Enabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thrusters are enabled. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_PitchEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_PitchEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when pitch control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_YawEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_YawEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when yaw control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_RollEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_RollEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when roll control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_ForwardEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_ForwardEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when forward control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_UpEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_UpEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when up control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_RightEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_RightEnabled(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS thruster will fire when right control input is given. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_InputOverride(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_InputOverride(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, bool value) Whether the RCS control is being set directly, bypassing the vessel's normal flight controls. When enabled, the rotation and translation demand is set by :func:`krpc_SpaceCenter_RCS_RotationOverride` and :func:`krpc_SpaceCenter_RCS_TranslationOverride` instead of the normal control inputs. The override is automatically released if the controlling client disconnects or the vessel changes. Precision mode leaves an overridden block at full thrust. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_RotationOverride(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_RotationOverride(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, const krpc_tuple_double_double_double_t * value) The rotation demand applied when :func:`krpc_SpaceCenter_RCS_InputOverride` is enabled, in the pitch, roll and yaw axes. Each component is a normalized control input between -1 and 1. :Game Scenes: Flight .. note:: The block ignores the component for an axis it is disabled for, such as pitch when :func:`krpc_SpaceCenter_RCS_PitchEnabled` is ``false``. .. function:: krpc_error_t krpc_SpaceCenter_RCS_TranslationOverride(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_TranslationOverride(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, const krpc_tuple_double_double_double_t * value) The translation demand applied when :func:`krpc_SpaceCenter_RCS_InputOverride` is enabled, in the right, up and forward axes. Each component is a normalized control input between -1 and 1. :Game Scenes: Flight .. note:: The block ignores the component for an axis it is disabled for, such as right when :func:`krpc_SpaceCenter_RCS_RightEnabled` is ``false``. .. function:: krpc_error_t krpc_SpaceCenter_RCS_AvailableTorque(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_RCS_t instance) The available torque, in :math:`\mathrm{N \cdot m}`, that can be produced by this RCS, in the positive and negative pitch, roll and yaw axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. Returns zero if RCS is disable. :Game Scenes: Flight .. note:: Precision mode weakens the block, and the available torque follows it. A block driven by :func:`krpc_SpaceCenter_RCS_InputOverride` is exempt, so :func:`krpc_SpaceCenter_RCS_OverrideWrench` can report the larger torque an override reaches. .. function:: krpc_error_t krpc_SpaceCenter_RCS_AvailableForce(krpc_connection_t connection, krpc_SpaceCenter_AxisRange_t * returnValue, krpc_SpaceCenter_RCS_t instance) The available force, in Newtons, that can be produced by this RCS, in the positive and negative x, y and z axes of the vessel. These axes correspond to the coordinate axes of the :func:`krpc_SpaceCenter_Vessel_ReferenceFrame`. Returns zero if RCS is disabled. :Game Scenes: Flight .. note:: Precision mode weakens the block, and the available force follows it. A block driven by :func:`krpc_SpaceCenter_RCS_InputOverride` is exempt, so :func:`krpc_SpaceCenter_RCS_OverrideWrench` can report the larger force an override reaches. .. function:: krpc_error_t krpc_SpaceCenter_RCS_Force(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_RCS_t instance) The force being applied by the RCS thrusters, in Newtons. The vector is in the vessel's reference frame (:func:`krpc_SpaceCenter_Vessel_ReferenceFrame`). Returns zero if the RCS is inactive. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_Torque(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_RCS_t instance) The torque being applied by the RCS thrusters about the vessel's center of mass, in :math:`\mathrm{N \cdot m}`. The vector is in the vessel's reference frame (:func:`krpc_SpaceCenter_Vessel_ReferenceFrame`). Returns zero if the RCS is inactive. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_OverrideWrench(krpc_connection_t connection, krpc_SpaceCenter_Wrench_t * returnValue, krpc_SpaceCenter_RCS_t instance, const krpc_tuple_double_double_double_t * rotation, const krpc_tuple_double_double_double_t * translation) The force and torque the given demands would produce, in Newtons and :math:`\mathrm{N \cdot m}`. :Parameters: * **rotation** -- A rotation demand, as set by :func:`krpc_SpaceCenter_RCS_RotationOverride`. * **translation** -- A translation demand, as set by :func:`krpc_SpaceCenter_RCS_TranslationOverride`. :returns: The force, and the torque about the vessel's center of mass, in the vessel's reference frame (:func:`krpc_SpaceCenter_Vessel_ReferenceFrame`), or zero if the RCS is inactive. :Game Scenes: Flight .. note:: The demands do not have to be applied. The prediction leaves out full thrust, which :func:`krpc_SpaceCenter_RCS_Force` and :func:`krpc_SpaceCenter_RCS_Torque` include. .. function:: krpc_error_t krpc_SpaceCenter_RCS_AvailableThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The amount of thrust, in Newtons, that would be produced by the thruster when activated. Returns zero if the thruster does not have any fuel. Takes the thrusters current :func:`krpc_SpaceCenter_RCS_ThrustLimit` and atmospheric conditions into account. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_MaxThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The maximum amount of thrust that can be produced by the RCS thrusters when active, in Newtons, with the :func:`krpc_SpaceCenter_RCS_ThrustLimit` set to 100%. Takes atmospheric conditions into account. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_MaxVacuumThrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The maximum amount of thrust that can be produced by the RCS thrusters when active in a vacuum, in Newtons. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_ThrustLimit(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) .. function:: krpc_error_t krpc_SpaceCenter_RCS_set_ThrustLimit(krpc_connection_t connection, krpc_SpaceCenter_RCS_t instance, float value) The thrust limiter of the thruster. A value between 0 and 1. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_Thrusters(krpc_connection_t connection, krpc_list_object_t * returnValue, krpc_SpaceCenter_RCS_t instance) A list of thrusters, one of each nozzel in the RCS part. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_SpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The current specific impulse of the RCS, in seconds. Returns zero if the RCS is not active. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_VacuumSpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The vacuum specific impulse of the RCS, in seconds. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_KerbinSeaLevelSpecificImpulse(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_RCS_t instance) The specific impulse of the RCS at sea level on Kerbin, in seconds. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_Propellants(krpc_connection_t connection, krpc_list_string_t * returnValue, krpc_SpaceCenter_RCS_t instance) The names of resources that the RCS consumes. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_RCS_PropellantRatios(krpc_connection_t connection, krpc_dictionary_string_float_t * returnValue, krpc_SpaceCenter_RCS_t instance) The ratios of resources that the RCS consumes. A dictionary mapping resource names to the ratios at which they are consumed by the RCS. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_RCS_HasFuel(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_RCS_t instance) Whether the RCS has fuel available. :Game Scenes: Flight Sensor ^^^^^^ .. type:: krpc_SpaceCenter_Sensor_t A sensor, such as a thermometer. Obtained by calling :func:`krpc_SpaceCenter_Part_Sensor`. .. macro:: KRPC_CLASS_SPACECENTER_SENSOR The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Sensor_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Sensor_t instance) The part object for this sensor. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_Sensor_Active(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Sensor_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Sensor_set_Active(krpc_connection_t connection, krpc_SpaceCenter_Sensor_t instance, bool value) Whether the sensor is active. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Sensor_Value(krpc_connection_t connection, char * * returnValue, krpc_SpaceCenter_Sensor_t instance) The current value of the sensor. :Game Scenes: Flight .. note:: This is the same readout string shown in the part's right-click menu in-game, and is intended for display rather than for parsing. Both its units and the way it formats numbers follow the language the game is running in, so it is not stable across locales. For programmatic access to the underlying quantities, use :func:`krpc_SpaceCenter_Part_Temperature` (temperature sensors), :func:`krpc_SpaceCenter_Flight_GForce` (accelerometers) or :func:`krpc_SpaceCenter_Flight_StaticPressure` (barometers). Solar Panel ^^^^^^^^^^^ .. type:: krpc_SpaceCenter_SolarPanel_t A solar panel. Obtained by calling :func:`krpc_SpaceCenter_Part_SolarPanel`. .. note:: Includes the curved solar panels of Near Future Solar. .. macro:: KRPC_CLASS_SPACECENTER_SOLARPANEL The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_SolarPanel_t instance) The part object for this solar panel. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_Deployable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_SolarPanel_t instance) Whether the solar panel is deployable. :Game Scenes: Flight, Editor Vab, Editor Sph .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_SolarPanel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_SolarPanel_t instance, bool value) Whether the solar panel is extended. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_SolarPanel_t instance) The current state of the solar panel. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_EnergyFlow(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_SolarPanel_t instance) The current amount of energy being generated by the solar panel, in units of charge per second. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_SolarPanel_SunExposure(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_SolarPanel_t instance) The current amount of sunlight that is incident on the solar panel, as a percentage. A value between 0 and 1. :Game Scenes: Flight Thruster ^^^^^^^^ .. type:: krpc_SpaceCenter_Thruster_t The component of an :type:`krpc_SpaceCenter_Engine_t` or :type:`krpc_SpaceCenter_RCS_t` part that generates thrust. Can obtained by calling :func:`krpc_SpaceCenter_Engine_Thrusters` or :func:`krpc_SpaceCenter_RCS_Thrusters`. .. note:: Engines can consist of multiple thrusters. For example, the S3 KS-25x4 "Mammoth" has four rocket nozzels, and so consists of four thrusters. .. macro:: KRPC_CLASS_SPACECENTER_THRUSTER The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Thruster_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Thruster_t instance) The :func:`krpc_SpaceCenter_Thruster_Part` that contains this thruster. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_Thrust(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Thruster_t instance) The thrust being produced by the thruster, in Newtons. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_ThrustPosition(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position at which the thruster generates thrust, in the given reference frame. For gimballed engines, this takes into account the current rotation of the gimbal. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_ThrustDirection(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The direction of the force generated by the thruster, in the given reference frame. This is opposite to the direction in which the thruster expels propellant. For gimballed engines, this takes into account the current rotation of the gimbal. :Parameters: * **referenceFrame** -- The reference frame that the returned direction is in. :returns: The direction as a unit vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_ThrustReferenceFrame(krpc_connection_t connection, krpc_SpaceCenter_ReferenceFrame_t * returnValue, krpc_SpaceCenter_Thruster_t instance) A reference frame that is fixed relative to the thruster and orientated with its thrust direction (:func:`krpc_SpaceCenter_Thruster_ThrustDirection`). For gimballed engines, this takes into account the current rotation of the gimbal. * The origin is at the position of thrust for this thruster (:func:`krpc_SpaceCenter_Thruster_ThrustPosition`). * The axes rotate with the thrust direction. This is the direction in which the thruster expels propellant, including any gimballing. * The y-axis points along the thrust direction. * The x-axis and z-axis are perpendicular to the thrust direction. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_Gimballed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Thruster_t instance) Whether the thruster is gimballed. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_GimbalPosition(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) Position around which the gimbal pivots. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_GimbalAngle(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance) The current gimbal angle in the pitch, roll and yaw axes, in degrees. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Thruster_InitialThrustPosition(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position at which the thruster generates thrust, when the engine is in its initial position (no gimballing), in the given reference frame. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. note:: This position can move when the gimbal rotates. This is because the thrust position and gimbal position are not necessarily the same. .. function:: krpc_error_t krpc_SpaceCenter_Thruster_InitialThrustDirection(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Thruster_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The direction of the force generated by the thruster, when the engine is in its initial position (no gimballing), in the given reference frame. This is opposite to the direction in which the thruster expels propellant. :Parameters: * **referenceFrame** -- The reference frame that the returned direction is in. :returns: The direction as a unit vector. :Game Scenes: Flight Wheel ^^^^^ .. type:: krpc_SpaceCenter_Wheel_t A wheel. Includes landing gear and rover wheels. Obtained by calling :func:`krpc_SpaceCenter_Part_Wheel`. Can be used to control the motors, steering and deployment of wheels, among other things. .. macro:: KRPC_CLASS_SPACECENTER_WHEEL The service and class ids of the class, for :func:`krpc_KRPC_Type_ClassTypeById`. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Part(krpc_connection_t connection, krpc_SpaceCenter_Part_t * returnValue, krpc_SpaceCenter_Wheel_t instance) The part object for this wheel. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_State(krpc_connection_t connection, krpc_SpaceCenter_DeployableState_t * returnValue, krpc_SpaceCenter_Wheel_t instance) The current state of the wheel. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Radius(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Radius of the wheel, in meters. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Grounded(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel is touching the ground. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_HasBrakes(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel has brakes. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Brakes(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_Brakes(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) The braking force, as a percentage of maximum, when the brakes are applied. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_AutoFrictionControl(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_AutoFrictionControl(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether automatic friction control is enabled. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_ManualFrictionControl(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_ManualFrictionControl(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) Manual friction control value. Only has an effect if automatic friction control is disabled. A value between 0 and 5 inclusive. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Deployable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel is deployable. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Deployed(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_Deployed(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the wheel is deployed. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Powered(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel is powered by a motor. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_MotorEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_MotorEnabled(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the motor is enabled. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_MotorInverted(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_MotorInverted(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the direction of the motor is inverted. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_MotorState(krpc_connection_t connection, krpc_SpaceCenter_MotorState_t * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the direction of the motor is inverted. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_MotorOutput(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) The output of the motor. This is the torque currently being generated, in :math:`\mathrm{N \cdot m}`. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_TractionControlEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_TractionControlEnabled(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether automatic traction control is enabled. A wheel only has traction control if it is powered. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_TractionControl(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_TractionControl(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) Setting for the traction control. Only takes effect if the wheel has automatic traction control enabled. A value between 0 and 5 inclusive. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_DriveLimiter(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_DriveLimiter(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) Manual setting for the motor limiter. Only takes effect if the wheel has automatic traction control disabled. A value between 0 and 100 inclusive. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Steerable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel has steering. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SteeringEnabled(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_SteeringEnabled(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the wheel steering is enabled. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SteeringInverted(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_SteeringInverted(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the wheel steering is inverted. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SteeringAngleAuto(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_SteeringAngleAuto(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, bool value) Whether the steering angle is automatically limited based on the vessel's speed, reducing the maximum angle as the vessel moves faster. See also :func:`krpc_SpaceCenter_Wheel_SteeringAngleLimit`. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SteeringAngleLimit(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_SteeringAngleLimit(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) The steering angle limit. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SteeringResponseTime(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) .. function:: krpc_error_t krpc_SpaceCenter_Wheel_set_SteeringResponseTime(krpc_connection_t connection, krpc_SpaceCenter_Wheel_t instance, float value) Steering response time. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_HasSuspension(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel has suspension. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SuspensionSpringStrength(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Suspension spring strength, as set in the editor. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SuspensionDamperStrength(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Suspension damper strength, as set in the editor. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SuspensionSpring(krpc_connection_t connection, float * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Wheel_t instance) The spring constant of the suspension, in :math:`\mathrm{kN/m}`, or ``nullptr`` while the wheel is not grounded. Throws an exception if the wheel has no suspension. :Game Scenes: Flight .. note:: The game updates it while the wheel is grounded, from :func:`krpc_SpaceCenter_Wheel_SuspensionSpringStrength`, the vessel's mass, the wheel's compression and the local gravity. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SuspensionDamper(krpc_connection_t connection, float * returnValue, bool * returnValueIsNull, krpc_SpaceCenter_Wheel_t instance) The damping constant of the suspension, in :math:`\mathrm{kN \cdot s/m}`, or ``nullptr`` while the wheel is not grounded. Throws an exception if the wheel has no suspension. :Game Scenes: Flight .. note:: The game updates it while the wheel is grounded, from :func:`krpc_SpaceCenter_Wheel_SuspensionDamperStrength` and :func:`krpc_SpaceCenter_Wheel_SuspensionSpring`. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_SuspensionTravel(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) The travel of the suspension, in meters. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Load(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) The force pressing the wheel into the ground, in :math:`\mathrm{kN}`. :Game Scenes: Flight .. note:: The game raises the load of a grounded wheel to at least 0.5 kN, or 10 kN for a wheel with the old friction model. :func:`krpc_SpaceCenter_Wheel_ImpactTolerance` applies to the rise in this value. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_ContactPosition(krpc_connection_t connection, krpc_tuple_double_double_double_t * returnValue, krpc_SpaceCenter_Wheel_t instance, krpc_SpaceCenter_ReferenceFrame_t referenceFrame) The position of the bottom of the wheel, in the given reference frame. While the wheel is grounded, this is where it touches the ground. :Parameters: * **referenceFrame** -- The reference frame that the returned position vector is in. :returns: The position as a vector. :Game Scenes: Flight .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Broken(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel is broken. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Repairable(krpc_connection_t connection, bool * returnValue, krpc_SpaceCenter_Wheel_t instance) Whether the wheel is repairable. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Stress(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Current stress on the wheel. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_StressTolerance(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Stress tolerance of the wheel. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_ImpactTolerance(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) The rise in :func:`krpc_SpaceCenter_Wheel_Load` over one physics tick that breaks the wheel, in :math:`\mathrm{kN}`. Throws an exception if the wheel is not breakable. .. note:: The game scales the rise by the local gravity divided by standard gravity before comparing it with this tolerance. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_ExplodeMultiplier(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) The multiple of :func:`krpc_SpaceCenter_Wheel_ImpactTolerance` that destroys the wheel, in place of breaking it. Throws an exception if the wheel is not breakable. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_StressPercentage(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Current stress on the wheel as a percentage of its stress tolerance. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Deflection(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Current deflection of the wheel. .. function:: krpc_error_t krpc_SpaceCenter_Wheel_Slip(krpc_connection_t connection, float * returnValue, krpc_SpaceCenter_Wheel_t instance) Current slip of the wheel. .. type:: krpc_SpaceCenter_MotorState_t The state of the motor on a powered wheel. See :func:`krpc_SpaceCenter_Wheel_MotorState`. .. macro:: KRPC_ENUMERATION_SPACECENTER_MOTORSTATE The service and enumeration ids of the enumeration, for :func:`krpc_KRPC_Type_EnumerationTypeById` and :func:`krpc_KRPC_Expression_ConstantEnumById`. .. macro:: KRPC_SPACECENTER_MOTORSTATE_IDLE The motor is idle. .. macro:: KRPC_SPACECENTER_MOTORSTATE_RUNNING The motor is running. .. macro:: KRPC_SPACECENTER_MOTORSTATE_DISABLED The motor is disabled. .. macro:: KRPC_SPACECENTER_MOTORSTATE_INOPERABLE The motor is inoperable. .. macro:: KRPC_SPACECENTER_MOTORSTATE_NOTENOUGHRESOURCES The motor does not have enough resources to run.