Pilot Input — kOS 1.4.0.0 documentation (2024)

These are suffixes of ship:control.

They are similar to the suffixes on the Raw control page, exceptthat these suffixes refer to the player’s actual input controls, ratherthan kOS’s own controls that are layered on top of them, overriding them.

Please note that the Breaking Ground DLC parts that can be configuredto respond to the throttle, such as electric motors and propellor pitcheswill only respond to the settings described here on this page, and NOTthe settings described in the raw control page, or thesettings in lock throttle or lock steering. SQUAD designedthese to only pay attention to the player’s controls, not autopilotcontrols.

Most are read-only

Most of these controls are get-only because trying to change them hasno effect anyway (If kOS did let you set them, KSP would just reset themback to match the player’s actual input axis device immediately anyway.)The controls can be read to find out what the player is trying to do, ifyou’d like to write a script that tries to respond to that information.

But some are set-able

There are exceptions - some controls here can be set. The onlycontrols that might be settable in here are the ones that are forsettings that “stay put” and don’t reset to center when the pilot letsgo of the stick. For example, while PILOTPITCH matches whatevertemporary position the pilot’s stick is in, PILOTPITCHTRIM stayswhere it was last set. Thus PILOTPITCHTRIM is settable here,while PILOTPITCH is not. The docmentation below marks whichsuffixes are indeed set-able. Through the use of these trim-ablesettings, it is possible to control the ship in a way that stilllets the pilot temporarily grab the controls for a second to overridewhat kOS is doing.

structure Control

Suffix

Get/Set

Type, Range

Equivalent Key

PILOTMAINTHROTTLE

Get and Set

scalar [0,1]

LEFT-CTRL, LEFT-SHIFT

PILOTYAW

Get-only

scalar [-1,1]

D, A

PILOTPITCH

Get-only

scalar [-1,1]

W, S

PILOTROLL

Get-only

scalar [-1,1]

Q, E

PILOTROTATION

Get-only

Vector

(YAW,PITCH,ROLL)

PILOTYAWTRIM

Get and Set

scalar [-1,1]

ALT+D, ALT+A

PILOTPITCHTRIM

Get and Set

scalar [-1,1]

ALT+W, ALT+S

PILOTROLLTRIM

Get and Set

scalar [-1,1]

ALT+Q, ALT+E

PILOTFORE

Get-only

scalar [-1,1]

N, H

PILOTSTARBOARD

Get-only

scalar [-1,1]

L, J

PILOTTOP

Get-only

scalar [-1,1]

I, K

PILOTTRANSLATION

Get-only

Vector

(STARBOARD,TOP,FORE)

PILOTWHEELSTEER

Get-only

scalar [-1,1]

A, D

PILOTWHEELTHROTTLE

Get and Set

scalar [-1,1]

W, S

PILOTWHEELSTEERTRIM

Get and Set

scalar [-1,1]

ALT+A, ALT+D

PILOTWHEELTHROTTLETRIM

Get and Set

scalar [-1,1]

ALT+W, ALT+S

PILOTNEUTRAL

Get-only

Boolean

Are the pilot’s controls zeroed, including trim?

SHIP:CONTROL:PILOTMAINTHROTTLE

Get and Set

Returns the pilot’s input for the throttle. If this is set, and alock throttle is in effect, the lock throttle will overridethis, BUT it still affects where the throttle returns to when kOSlets go of the controls.

RP-1 Special Case: If using the RP-1 mod, and flying a “sounding rocket”where the avionics controls are insuficcient to steer but are goodenough to ignite engines, then lock throttle does not work toactivate those engines, but this suffix can do it. RP-1 activelysuppresses the normal ability for an autopilot to control the throttlein this case and only pays attention to the pilot’s own manual control.

SHIP:CONTROL:PILOTYAW

Get-only.

Returns the pilot’s rotation input about the “up” vector as the pilot faces forward. Essentially left \((-1)\) or right \((+1)\).

SHIP:CONTROL:PILOTPITCH

Get-only.

Returns the pilot’s rotation input about the starboard vector up \((+1)\) or down \((-1)\).

SHIP:CONTROL:PILOTROLL

Get-only.

Returns the pilot’s rotation input about the logintudinal axis of the ship left-wing-down \((-1)\) or left-wing-up \((+1)\).

SHIP:CONTROL:PILOTROTATION

Get-only.

Returns the pilot’s rotation input as a Vector object containing (YAW, PITCH, ROLL) in that order.

SHIP:CONTROL:PILOTYAWTRIM

Get and Set

The pilot’s input for the YAW of the rotational trim.Note that this CAN be set, unlike PILOTYAW, making itpossible to use it for an autopilot control program.The player can also adjust it too, though, overridingwhat you set it to.

SHIP:CONTROL:PILOTPITCHTRIM

Get and Set

The pilot’s input for the PITCH of the rotational trim.Note that this CAN be set, unlike PILOTPITCH, making itpossible to use it for an autopilot control program.The player can also adjust it too, though, overridingwhat you set it to.

SHIP:CONTROL:PILOTROLLTRIM

Get and Set

The pilot’s input for the ROLL of the rotational trim.Note that this CAN be set, unlike PILOTROLL, making itpossible to use it for an autopilot control program.The player can also adjust it too, though, overridingwhat you set it to.

SHIP:CONTROL:PILOTFORE

Get-only.

Returns the the pilot’s input for the translation of the ship forward \((+1)\) or backward \((-1)\).

SHIP:CONTROL:PILOTSTARBOARD

Get-only.

Returns the the pilot’s input for the translation of the ship to the right \((+1)\) or left \((-1)\) from the pilot’s perspective.

SHIP:CONTROL:PILOTTOP

Get-only.

Returns the the pilot’s input for the translation of the ship up \((+1)\) or down \((-1)\) from the pilot’s perspective.

SHIP:CONTROL:PILOTTRANSLATION

Get-only.

Returns the the pilot’s input for translation as a Vector (STARBOARD, TOP, FORE).

SHIP:CONTROL:PILOTWHEELSTEER

Get-only.

Returns the the pilot’s input for wheel steering left \((-1)\) or right \((+1)\).

SHIP:CONTROL:PILOTWHEELTHROTTLE

Get and Set

The the pilot’s input for the wheels to move the ship forward \((+1)\) or backward \((-1)\) while on the ground.

Because this is not an axis that resets, it can be set by a script althoughit may get suppressed when a lock throttle is in effect.

SHIP:CONTROL:PILOTWHEELSTEERTRIM

Get and Set

Returns the the pilot’s input for the trim of the wheel steering.

Because this is a trim, it can be set by a kOS script.

SHIP:CONTROL:PILOTWHEELTHROTTLETRIM

Get and Set

Returns the the pilot’s input for the trim of the wheel throttle.

Because this is a trim, it can be set by a kOS script.

SHIP:CONTROL:PILOTNEUTRAL

Get-only.

Returns true or false if the pilot is active or not.

Be aware that kOS can’t control a control at the same time that a player controls it. If kOS is taking control of the yoke, then the player can’t manually control it. Remember to run:

SET SHIP:CONTROL:NEUTRALIZE TO TRUE.

after the script is done using the controls, or the player will be locked out of control.

Pilot Input — kOS 1.4.0.0 documentation (2024)

References

Top Articles
Latest Posts
Article information

Author: Sen. Emmett Berge

Last Updated:

Views: 5879

Rating: 5 / 5 (80 voted)

Reviews: 87% of readers found this page helpful

Author information

Name: Sen. Emmett Berge

Birthday: 1993-06-17

Address: 787 Elvis Divide, Port Brice, OH 24507-6802

Phone: +9779049645255

Job: Senior Healthcare Specialist

Hobby: Cycling, Model building, Kitesurfing, Origami, Lapidary, Dance, Basketball

Introduction: My name is Sen. Emmett Berge, I am a funny, vast, charming, courageous, enthusiastic, jolly, famous person who loves writing and wants to share my knowledge and understanding with you.