Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
CommNet.CommNetVessel Class Reference

VesselModule with telemetry link and control connection logic More...

Inheritance diagram for CommNet.CommNetVessel:
VesselModule

Public Member Functions

void FindCommandSources ()
 
virtual IScienceDataTransmitter GetBestTransmitter ()
 Gets best available antenna for science transmission More...
 
virtual Vessel.ControlLevel GetControlLevel ()
 Gets control level for vessel More...
 
virtual double GetSignalStrengthModifier (CommNode b)
 Signal strength modifier vs given comm node More...
 
virtual void OnNetworkPostUpdate ()
 Does post-network-build updating, like pushing network updates out and finding control path More...
 
virtual void OnNetworkPreUpdate ()
 Updates the comm (if haven't yet, or unpacked, or override) More...
 
void RegisterCommandSource (ICommNetControlSource cmd)
 
void UnregisterCommandSource (ICommNetControlSource cmd)
 
- Public Member Functions inherited from VesselModule
virtual Activation GetActivation ()
 
virtual int GetOrder ()
 
void Load (ConfigNode node)
 
virtual void OnGoOffRails ()
 
virtual void OnGoOnRails ()
 
virtual void OnLoadVessel ()
 
virtual void OnUnloadVessel ()
 
void Save (ConfigNode node)
 
virtual bool ShouldBeActive ()
 

Public Attributes

Action OnNetworkUpdate
 

Protected Member Functions

virtual void CalculatePlasmaMult ()
 
virtual bool CreateControlConnection ()
 Actually finds control path More...
 
override void OnAwake ()
 
virtual void OnDestroy ()
 
virtual void OnMapFocusChange (MapObject target)
 
virtual void OnNetworkInitialized ()
 
override void OnStart ()
 Dies if vessel is flag or UNKNWON or lower Then registers the comm events and initializes More...
 
virtual void Update ()
 Updates control state if vessel is loaded More...
 
virtual void UpdateComm ()
 Updates the comm node with the best antennae info from the vessel, and finds any control point modules More...
 
void UpdateControlState ()
 Updates vessel control state More...
 
- Protected Member Functions inherited from VesselModule
void Awake ()
 
virtual void OnLoad (ConfigNode node)
 
virtual void OnSave (ConfigNode node)
 
void Start ()
 

Protected Attributes

bool canComm = true
 
CommNode comm
 
List< ICommNetControlSourcecommandSources = new List<ICommNetControlSource>()
 
CommPath controlPath = new CommPath()
 
VesselControlState controlState = VesselControlState.None
 
bool doUnloadedUpdate = false
 
bool hasScienceAntenna
 
bool inPlasma = false
 
bool networkInitialised = false
 
bool overridePostUpdate = false
 Always do postupdate, i.e. find control path More...
 
bool overridePreUpdate = false
 Always do preupdate, i.e. comm object update More...
 
int partCountCache
 
double plasmaMult = 1d
 
double signalDelay = 0d
 
bool unloadedDoOnce = true
 
- Protected Attributes inherited from VesselModule
BaseFieldList fields
 
Vessel vessel
 

Properties

bool CanComm [get]
 
bool CanScience [get]
 
CommNode Comm [get, set]
 
List< ICommNetControlSourceCommandSources [get]
 
CommPath ControlPath [get]
 
VesselControlState ControlState [get]
 
bool InPlasma [get]
 
bool IsConnected [get, set]
 
bool IsConnectedHome [get, set]
 
SignalStrength Signal [get]
 
double SignalDelay [get]
 
double SignalStrength [get]
 
- Properties inherited from VesselModule
BaseFieldList Fields [get]
 
Vessel Vessel [get, set]
 

Additional Inherited Members

- Public Types inherited from VesselModule
enum  Activation {
  Activation.FlightScene = 1, Activation.NonFlightScenes = 2, Activation.LoadedVessels = 4, Activation.UnloadedVessels = 8,
  Activation.Never = 0, Activation.AllScenes = 3, Activation.LoadedOrUnloaded = 12, Activation.Always = 255
}
 

Detailed Description

VesselModule with telemetry link and control connection logic

Member Function Documentation

virtual void CommNet.CommNetVessel.CalculatePlasmaMult ( )
inlineprotectedvirtual
virtual bool CommNet.CommNetVessel.CreateControlConnection ( )
inlineprotectedvirtual

Actually finds control path

Returns

< test connection!

< return if connection state has changed

void CommNet.CommNetVessel.FindCommandSources ( )
inline
virtual IScienceDataTransmitter CommNet.CommNetVessel.GetBestTransmitter ( )
inlinevirtual

Gets best available antenna for science transmission

Returns
virtual Vessel.ControlLevel CommNet.CommNetVessel.GetControlLevel ( )
inlinevirtual

Gets control level for vessel

Returns
virtual double CommNet.CommNetVessel.GetSignalStrengthModifier ( CommNode  b)
inlinevirtual

Signal strength modifier vs given comm node

Parameters
b
Returns
override void CommNet.CommNetVessel.OnAwake ( )
inlineprotectedvirtual

Reimplemented from VesselModule.

virtual void CommNet.CommNetVessel.OnDestroy ( )
inlineprotectedvirtual
virtual void CommNet.CommNetVessel.OnMapFocusChange ( MapObject  target)
inlineprotectedvirtual
virtual void CommNet.CommNetVessel.OnNetworkInitialized ( )
inlineprotectedvirtual

< don't remove the event listener - this may not be the final network, here.

virtual void CommNet.CommNetVessel.OnNetworkPostUpdate ( )
inlinevirtual

Does post-network-build updating, like pushing network updates out and finding control path

virtual void CommNet.CommNetVessel.OnNetworkPreUpdate ( )
inlinevirtual

Updates the comm (if haven't yet, or unpacked, or override)

override void CommNet.CommNetVessel.OnStart ( )
inlineprotectedvirtual

Dies if vessel is flag or UNKNWON or lower Then registers the comm events and initializes

Reimplemented from VesselModule.

void CommNet.CommNetVessel.RegisterCommandSource ( ICommNetControlSource  cmd)
inline
void CommNet.CommNetVessel.UnregisterCommandSource ( ICommNetControlSource  cmd)
inline
virtual void CommNet.CommNetVessel.Update ( )
inlineprotectedvirtual

Updates control state if vessel is loaded

virtual void CommNet.CommNetVessel.UpdateComm ( )
inlineprotectedvirtual

Updates the comm node with the best antennae info from the vessel, and finds any control point modules

< bad here

void CommNet.CommNetVessel.UpdateControlState ( )
inlineprotected

Updates vessel control state

Member Data Documentation

bool CommNet.CommNetVessel.canComm = true
protected
CommNode CommNet.CommNetVessel.comm
protected
List<ICommNetControlSource> CommNet.CommNetVessel.commandSources = new List<ICommNetControlSource>()
protected
CommPath CommNet.CommNetVessel.controlPath = new CommPath()
protected
VesselControlState CommNet.CommNetVessel.controlState = VesselControlState.None
protected
bool CommNet.CommNetVessel.doUnloadedUpdate = false
protected
bool CommNet.CommNetVessel.hasScienceAntenna
protected
bool CommNet.CommNetVessel.inPlasma = false
protected
bool CommNet.CommNetVessel.networkInitialised = false
protected
Action CommNet.CommNetVessel.OnNetworkUpdate
bool CommNet.CommNetVessel.overridePostUpdate = false
protected

Always do postupdate, i.e. find control path

bool CommNet.CommNetVessel.overridePreUpdate = false
protected

Always do preupdate, i.e. comm object update

int CommNet.CommNetVessel.partCountCache
protected
double CommNet.CommNetVessel.plasmaMult = 1d
protected
double CommNet.CommNetVessel.signalDelay = 0d
protected
bool CommNet.CommNetVessel.unloadedDoOnce = true
protected

Property Documentation

bool CommNet.CommNetVessel.CanComm
get
bool CommNet.CommNetVessel.CanScience
get
CommNode CommNet.CommNetVessel.Comm
getset
List<ICommNetControlSource> CommNet.CommNetVessel.CommandSources
get
CommPath CommNet.CommNetVessel.ControlPath
get
VesselControlState CommNet.CommNetVessel.ControlState
get
bool CommNet.CommNetVessel.InPlasma
get
bool CommNet.CommNetVessel.IsConnected
getset
bool CommNet.CommNetVessel.IsConnectedHome
getset
SignalStrength CommNet.CommNetVessel.Signal
get
double CommNet.CommNetVessel.SignalDelay
get
double CommNet.CommNetVessel.SignalStrength
get

The documentation for this class was generated from the following file: