Alarm#

class KerbalAlarmClock.Alarm()#

Represents an alarm. Obtained by calling KerbalAlarmClock.getAlarms(), KerbalAlarmClock.alarmWithName() or KerbalAlarmClock.alarmsWithType().

Alarm.getAction()#
Alarm.setAction(value)#

The action that the alarm triggers.

Property:

Can be read or written

Return type:

KerbalAlarmClock.AlarmAction

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Note

An alarm that plays a sound has the action KerbalAlarmClock.AlarmAction.custom. See KerbalAlarmClock.Alarm.getPlaySound().

Alarm.getMargin()#
Alarm.setMargin(value)#

The number of seconds before the event that the alarm will fire.

Property:

Can be read or written

Return type:

number

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getTime()#
Alarm.setTime(value)#

The time at which the alarm will fire.

Property:

Can be read or written

Return type:

number

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getType()#

The type of the alarm.

Property:

Read-only, cannot be set

Return type:

KerbalAlarmClock.AlarmType

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getID()#

The unique identifier for the alarm.

Property:

Read-only, cannot be set

Return type:

string

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getName()#
Alarm.setName(value)#

The short name of the alarm.

Property:

Can be read or written

Return type:

string

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getNotes()#
Alarm.setNotes(value)#

The long description of the alarm.

Property:

Can be read or written

Return type:

string

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getRemaining()#

The number of seconds until the alarm will fire.

Property:

Read-only, cannot be set

Return type:

number

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getEnabled()#
Alarm.setEnabled(value)#

Whether the alarm is enabled. A disabled alarm does not fire.

Property:

Can be read or written

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getPlaySound()#
Alarm.setPlaySound(value)#

Whether the alarm plays a sound when it fires.

Property:

Can be read or written

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Note

An alarm that plays a sound has the action KerbalAlarmClock.AlarmAction.custom. Setting KerbalAlarmClock.Alarm.getAction() to any other value turns the sound off.

Alarm.getTriggered()#

Whether the alarm has fired. Remains true once the alarm has fired; stream this or use it in an event expression to react to the alarm firing.

Property:

Read-only, cannot be set

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getRepeat()#
Alarm.setRepeat(value)#

Whether the alarm will be repeated after it has fired. Only has an effect for alarm types that support repeating (see KerbalAlarmClock.Alarm.getSupportsRepeat()).

Property:

Can be read or written

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getSupportsRepeat()#

Whether this alarm’s type supports repeating (see KerbalAlarmClock.Alarm.getRepeat()).

Property:

Read-only, cannot be set

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getRepeatPeriod()#
Alarm.setRepeatPeriod(value)#

The time delay to automatically create an alarm after it has fired. Only has an effect for alarm types that support a repeat period (see KerbalAlarmClock.Alarm.getSupportsRepeatPeriod()).

Property:

Can be read or written

Return type:

number

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getSupportsRepeatPeriod()#

Whether this alarm’s type supports a repeat period (see KerbalAlarmClock.Alarm.getRepeatPeriod()).

Property:

Read-only, cannot be set

Return type:

boolean

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getVessel()#
Alarm.setVessel(value)#

The vessel that the alarm is attached to.

Property:

Can be read or written

Return type:

SpaceCenter.Vessel

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getXferOriginBody()#
Alarm.setXferOriginBody(value)#

The celestial body the vessel is departing from.

Property:

Can be read or written

Return type:

SpaceCenter.CelestialBody

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.getXferTargetBody()#
Alarm.setXferTargetBody(value)#

The celestial body the vessel is arriving at.

Property:

Can be read or written

Return type:

SpaceCenter.CelestialBody

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Alarm.remove()#

Removes the alarm. Any further use of this object throws an exception.

Game Scenes:

Space Center, Flight, Tracking Station, Editor Vab, Editor Sph, Astronaut Complex, Mission Control, Research And Development, Administration

Note

Any further use of this object throws an exception.