# Build Folders (you can keep bin if you'd like, to store dlls and pdbs) | # Build Folders (you can keep bin if you'd like, to store dlls and pdbs) |
[Bb]in/ | [Bb]in/ |
[Oo]bj/ | [Oo]bj/ |
# Unity specific | |
[Ll]ibrary/ | |
[Tt]emp/ | |
*.unityproj | |
# mstest test results | # mstest test results |
TestResults | TestResults |
## Ignore Visual Studio temporary files, build results, and | ## Ignore Visual Studio temporary files, build results, and |
## files generated by popular Visual Studio add-ons. | ## files generated by popular Visual Studio add-ons. |
# User-specific files | # User-specific files |
*.suo | *.suo |
*.user | *.user |
*.sln.docstates | *.sln.docstates |
# Build results | # Build results |
[Dd]ebug/ | [Dd]ebug/ |
x64/ | x64/ |
*_i.c | *_i.c |
*_p.c | *_p.c |
*.ilk | *.ilk |
*.meta | *.meta |
*.obj | *.obj |
*.pch | *.pch |
*.pdb | *.pdb |
*.pgc | *.pgc |
*.pgd | *.pgd |
*.rsp | *.rsp |
*.sbr | *.sbr |
*.tlb | *.tlb |
*.tli | *.tli |
*.tlh | *.tlh |
*.tmp | *.tmp |
*.log | *.log |
*.vspscc | *.vspscc |
*.vssscc | *.vssscc |
.builds | .builds |
# Visual C++ cache files | # Visual C++ cache files |
ipch/ | ipch/ |
*.aps | *.aps |
*.ncb | *.ncb |
*.opensdf | *.opensdf |
*.sdf | *.sdf |
# Visual Studio profiler | # Visual Studio profiler |
*.psess | *.psess |
*.vsp | *.vsp |
*.vspx | *.vspx |
# Guidance Automation Toolkit | # Guidance Automation Toolkit |
*.gpState | *.gpState |
# ReSharper is a .NET coding add-in | # ReSharper is a .NET coding add-in |
_ReSharper* | _ReSharper* |
# Mindbench SASS cache | # Mindbench SASS cache |
.sass-cache/ | .sass-cache/ |
# NCrunch | # NCrunch |
*.ncrunch* | *.ncrunch* |
.*crunch*.local.xml | .*crunch*.local.xml |
# Installshield output folder | # Installshield output folder |
[Ee]xpress | [Ee]xpress |
# DocProject is a documentation generator add-in | # DocProject is a documentation generator add-in |
DocProject/buildhelp/ | DocProject/buildhelp/ |
DocProject/Help/*.HxT | DocProject/Help/*.HxT |
DocProject/Help/*.HxC | DocProject/Help/*.HxC |
DocProject/Help/*.hhc | DocProject/Help/*.hhc |
DocProject/Help/*.hhk | DocProject/Help/*.hhk |
DocProject/Help/*.hhp | DocProject/Help/*.hhp |
DocProject/Help/Html2 | DocProject/Help/Html2 |
DocProject/Help/html | DocProject/Help/html |
# Click-Once directory | # Click-Once directory |
publish | publish |
# Publish Web Output | # Publish Web Output |
*.Publish.xml | *.Publish.xml |
# NuGet Packages Directory | # NuGet Packages Directory |
packages | packages |
# Windows Azure Build Output | # Windows Azure Build Output |
csx | csx |
*.build.csdef | *.build.csdef |
# Windows Store app package directory | # Windows Store app package directory |
AppPackages/ | AppPackages/ |
# Others | # Others |
sql | sql |
TestResults | TestResults |
[Tt]est[Rr]esult* | [Tt]est[Rr]esult* |
*.Cache | *.Cache |
ClientBin | ClientBin |
[Ss]tyle[Cc]op.* | [Ss]tyle[Cc]op.* |
~$* | ~$* |
*.dbmdl | *.dbmdl |
Generated_Code #added for RIA/Silverlight projects | Generated_Code #added for RIA/Silverlight projects |
# Backup & report files from converting an old project file to a newer | # Backup & report files from converting an old project file to a newer |
# Visual Studio version. Backup files are not needed, because we have git ;-) | # Visual Studio version. Backup files are not needed, because we have git ;-) |
_UpgradeReport_Files/ | _UpgradeReport_Files/ |
Backup*/ | Backup*/ |
UpgradeLog*.XML | UpgradeLog*.XML |
# SQL Server files | # SQL Server files |
App_Data/*.mdf | App_Data/*.mdf |
App_Data/*.ldf | App_Data/*.ldf |
[Gg]ame/ | [Gg]ame/ |
[Rr]elease/ | [Rr]elease/ |
Binary files a/Assets/CurseLogo.png and /dev/null differ
Binary files a/Assets/CurseLogo.psd and /dev/null differ
Binary files a/Assets/DropDownBackground.psd and /dev/null differ
Binary files /dev/null and b/Assets/Images/app-launcher-icon.psd differ
Binary files /dev/null and b/Assets/Images/flight-menu-background.psd differ
Binary files /dev/null and b/Assets/Images/ui-drop-down.psd differ
Binary files /dev/null and b/Assets/Plugins/KerbalEngineer.Unity.dll differ
%YAML 1.1 | |
%TAG !u! tag:unity3d.com,2011: | |
--- !u!1 &116014 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22475412} | |
- 222: {fileID: 22223226} | |
- 114: {fileID: 11409704} | |
- 114: {fileID: 11424646} | |
m_Layer: 5 | |
m_Name: Content | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &122098 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22401100} | |
- 222: {fileID: 22201528} | |
- 114: {fileID: 11404586} | |
- 114: {fileID: 11496484} | |
- 114: {fileID: 11461688} | |
m_Layer: 5 | |
m_Name: ControlBar | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &126098 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22476196} | |
- 222: {fileID: 22270862} | |
- 114: {fileID: 11423044} | |
- 114: {fileID: 11485532} | |
- 225: {fileID: 22567868} | |
- 114: {fileID: 11415294} | |
m_Layer: 5 | |
m_Name: flight-menu | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &133376 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22478174} | |
- 114: {fileID: 11443382} | |
m_Layer: 5 | |
m_Name: TopControls | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &137786 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22444606} | |
- 222: {fileID: 22267348} | |
- 114: {fileID: 11465882} | |
m_Layer: 5 | |
m_Name: Text | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &138760 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22409936} | |
- 222: {fileID: 22255938} | |
- 114: {fileID: 11403342} | |
m_Layer: 5 | |
m_Name: Text | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &156848 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22483410} | |
- 222: {fileID: 22267572} | |
- 114: {fileID: 11463504} | |
- 114: {fileID: 11453198} | |
m_Layer: 5 | |
m_Name: Titlebar | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &172308 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22401786} | |
- 222: {fileID: 22247322} | |
- 114: {fileID: 11439582} | |
m_Layer: 5 | |
m_Name: Text | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!1 &194088 | |
GameObject: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 22469574} | |
- 222: {fileID: 22281674} | |
- 114: {fileID: 11498756} | |
- 114: {fileID: 11454510} | |
- 114: {fileID: 11451984} | |
m_Layer: 5 | |
m_Name: ShowEngineer | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!114 &11403342 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 138760} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: 0, g: 0, b: 0, a: 1} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_FontData: | |
m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} | |
m_FontSize: 12 | |
m_FontStyle: 1 | |
m_BestFit: 0 | |
m_MinSize: 10 | |
m_MaxSize: 40 | |
m_Alignment: 4 | |
m_RichText: 1 | |
m_HorizontalOverflow: 0 | |
m_VerticalOverflow: 0 | |
m_LineSpacing: 1 | |
m_Text: SHOW ENGINEER | |
--- !u!114 &11404586 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 122098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: .800000072, g: 1, b: 0, a: .501960814} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} | |
m_Type: 1 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!114 &11409704 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 116014} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: .313725501, g: .313725501, b: .313725501, a: .70588237} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 0} | |
m_Type: 1 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!114 &11415294 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 2019631361, guid: a3a55138b08428847a08c7b48fe72efe, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_FastFadeDuration: .200000003 | |
m_SlowFadeDuration: 1 | |
--- !u!114 &11423044 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1741964061, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_HorizontalFit: 0 | |
m_VerticalFit: 2 | |
--- !u!114 &11424646 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 116014} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1297475563, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Padding: | |
m_Left: 0 | |
m_Right: 0 | |
m_Top: 0 | |
m_Bottom: 0 | |
m_ChildAlignment: 0 | |
m_Spacing: 0 | |
m_ChildForceExpandWidth: 1 | |
m_ChildForceExpandHeight: 0 | |
--- !u!114 &11439582 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 172308} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: .800000072, g: 1, b: 0, a: .784313738} | |
m_RaycastTarget: 0 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_FontData: | |
m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} | |
m_FontSize: 12 | |
m_FontStyle: 1 | |
m_BestFit: 0 | |
m_MinSize: 10 | |
m_MaxSize: 40 | |
m_Alignment: 3 | |
m_RichText: 0 | |
m_HorizontalOverflow: 0 | |
m_VerticalOverflow: 0 | |
m_LineSpacing: 1 | |
m_Text: FLIGHT ENGINEER | |
--- !u!114 &11443382 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 133376} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_IgnoreLayout: 0 | |
m_MinWidth: -1 | |
m_MinHeight: -1 | |
m_PreferredWidth: -1 | |
m_PreferredHeight: 25 | |
m_FlexibleWidth: -1 | |
m_FlexibleHeight: -1 | |
--- !u!114 &11451984 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 194088} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_IgnoreLayout: 0 | |
m_MinWidth: -1 | |
m_MinHeight: -1 | |
m_PreferredWidth: -1 | |
m_PreferredHeight: 20 | |
m_FlexibleWidth: -1 | |
m_FlexibleHeight: -1 | |
--- !u!114 &11453198 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 156848} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_IgnoreLayout: 0 | |
m_MinWidth: -1 | |
m_MinHeight: -1 | |
m_PreferredWidth: -1 | |
m_PreferredHeight: 20 | |
m_FlexibleWidth: -1 | |
m_FlexibleHeight: -1 | |
--- !u!114 &11454510 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 194088} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Navigation: | |
m_Mode: 3 | |
m_SelectOnUp: {fileID: 0} | |
m_SelectOnDown: {fileID: 0} | |
m_SelectOnLeft: {fileID: 0} | |
m_SelectOnRight: {fileID: 0} | |
m_Transition: 1 | |
m_Colors: | |
m_NormalColor: {r: 1, g: 1, b: 1, a: 1} | |
m_HighlightedColor: {r: .960784316, g: .960784316, b: .960784316, a: 1} | |
m_PressedColor: {r: .784313738, g: .784313738, b: .784313738, a: 1} | |
m_DisabledColor: {r: .784313738, g: .784313738, b: .784313738, a: .501960814} | |
m_ColorMultiplier: 1 | |
m_FadeDuration: .100000001 | |
m_SpriteState: | |
m_HighlightedSprite: {fileID: 0} | |
m_PressedSprite: {fileID: 0} | |
m_DisabledSprite: {fileID: 0} | |
m_AnimationTriggers: | |
m_NormalTrigger: Normal | |
m_HighlightedTrigger: Highlighted | |
m_PressedTrigger: Pressed | |
m_DisabledTrigger: Disabled | |
m_Interactable: 1 | |
m_TargetGraphic: {fileID: 11498756} | |
m_OnClick: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, | |
Culture=neutral, PublicKeyToken=null | |
--- !u!114 &11461688 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 122098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_IgnoreLayout: 0 | |
m_MinWidth: -1 | |
m_MinHeight: -1 | |
m_PreferredWidth: -1 | |
m_PreferredHeight: 20 | |
m_FlexibleWidth: -1 | |
m_FlexibleHeight: -1 | |
--- !u!114 &11463504 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 156848} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: .183823526, g: .183823526, b: .183823526, a: .90196079} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 0} | |
m_Type: 0 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!114 &11465882 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 137786} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: 0, g: 0, b: 0, a: 1} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_FontData: | |
m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} | |
m_FontSize: 12 | |
m_FontStyle: 1 | |
m_BestFit: 0 | |
m_MinSize: 10 | |
m_MaxSize: 40 | |
m_Alignment: 4 | |
m_RichText: 1 | |
m_HorizontalOverflow: 0 | |
m_VerticalOverflow: 0 | |
m_LineSpacing: 1 | |
m_Text: CONTROL BAR | |
--- !u!114 &11485532 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1297475563, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Padding: | |
m_Left: 0 | |
m_Right: 0 | |
m_Top: 0 | |
m_Bottom: 0 | |
m_ChildAlignment: 0 | |
m_Spacing: 0 | |
m_ChildForceExpandWidth: 1 | |
m_ChildForceExpandHeight: 1 | |
--- !u!114 &11496484 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 122098} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Navigation: | |
m_Mode: 3 | |
m_SelectOnUp: {fileID: 0} | |
m_SelectOnDown: {fileID: 0} | |
m_SelectOnLeft: {fileID: 0} | |
m_SelectOnRight: {fileID: 0} | |
m_Transition: 1 | |
m_Colors: | |
m_NormalColor: {r: 1, g: 1, b: 1, a: 1} | |
m_HighlightedColor: {r: .960784316, g: .960784316, b: .960784316, a: 1} | |
m_PressedColor: {r: .784313738, g: .784313738, b: .784313738, a: 1} | |
m_DisabledColor: {r: .784313738, g: .784313738, b: .784313738, a: .501960814} | |
m_ColorMultiplier: 1 | |
m_FadeDuration: .100000001 | |
m_SpriteState: | |
m_HighlightedSprite: {fileID: 0} | |
m_PressedSprite: {fileID: 0} | |
m_DisabledSprite: {fileID: 0} | |
m_AnimationTriggers: | |
m_NormalTrigger: Normal | |
m_HighlightedTrigger: Highlighted | |
m_PressedTrigger: Pressed | |
m_DisabledTrigger: Disabled | |
m_Interactable: 1 | |
m_TargetGraphic: {fileID: 11404586} | |
m_OnClick: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, | |
Culture=neutral, PublicKeyToken=null | |
--- !u!114 &11498756 | |
MonoBehaviour: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 194088} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: .800000072, g: 1, b: 0, a: .501960814} | |
m_RaycastTarget: 1 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} | |
m_Type: 1 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!222 &22201528 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 122098} | |
--- !u!222 &22223226 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 116014} | |
--- !u!222 &22247322 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 172308} | |
--- !u!222 &22255938 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 138760} | |
--- !u!222 &22267348 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 137786} | |
--- !u!222 &22267572 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 156848} | |
--- !u!222 &22270862 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
--- !u!222 &22281674 | |
CanvasRenderer: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 194088} | |
--- !u!224 &22401100 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 122098} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22444606} | |
m_Father: {fileID: 22478174} | |
m_RootOrder: 1 | |
m_AnchorMin: {x: .5, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: -.5, y: 0} | |
m_SizeDelta: {x: -3, y: -4} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22401786 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 172308} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 22483410} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: 2.5, y: 0} | |
m_SizeDelta: {x: -5, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22409936 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 138760} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 22469574} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22444606 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 137786} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 22401100} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22469574 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 194088} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22409936} | |
m_Father: {fileID: 22478174} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: .5, y: 1} | |
m_AnchoredPosition: {x: .5, y: 0} | |
m_SizeDelta: {x: -3, y: -4} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22475412 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 116014} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22478174} | |
m_Father: {fileID: 22476196} | |
m_RootOrder: 1 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 0, y: 0} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22476196 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22483410} | |
- {fileID: 22475412} | |
m_Father: {fileID: 0} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: .5, y: .5} | |
m_AnchorMax: {x: .5, y: .5} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 250, y: 0} | |
m_Pivot: {x: 1, y: 0} | |
--- !u!224 &22478174 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 133376} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22469574} | |
- {fileID: 22401100} | |
m_Father: {fileID: 22475412} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 0, y: 0} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!224 &22483410 | |
RectTransform: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 156848} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: | |
- {fileID: 22401786} | |
m_Father: {fileID: 22476196} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 0, y: 0} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: 1} | |
--- !u!225 &22567868 | |
CanvasGroup: | |
m_ObjectHideFlags: 1 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 100100000} | |
m_GameObject: {fileID: 126098} | |
m_Enabled: 1 | |
m_Alpha: 1 | |
m_Interactable: 1 | |
m_BlocksRaycasts: 1 | |
m_IgnoreParentGroups: 0 | |
--- !u!1001 &100100000 | |
Prefab: | |
m_ObjectHideFlags: 1 | |
serializedVersion: 2 | |
m_Modification: | |
m_TransformParent: {fileID: 0} | |
m_Modifications: [] | |
m_RemovedComponents: [] | |
m_ParentPrefab: {fileID: 0} | |
m_RootGameObject: {fileID: 126098} | |
m_IsPrefabParent: 1 | |
%YAML 1.1 | |
%TAG !u! tag:unity3d.com,2011: | |
--- !u!29 &1 | |
SceneSettings: | |
m_ObjectHideFlags: 0 | |
m_PVSData: | |
m_PVSObjectsArray: [] | |
m_PVSPortalsArray: [] | |
m_OcclusionBakeSettings: | |
smallestOccluder: 5 | |
smallestHole: .25 | |
backfaceThreshold: 100 | |
--- !u!104 &2 | |
RenderSettings: | |
m_ObjectHideFlags: 0 | |
serializedVersion: 6 | |
m_Fog: 0 | |
m_FogColor: {r: .5, g: .5, b: .5, a: 1} | |
m_FogMode: 3 | |
m_FogDensity: .00999999978 | |
m_LinearFogStart: 0 | |
m_LinearFogEnd: 300 | |
m_AmbientSkyColor: {r: .211999997, g: .226999998, b: .259000003, a: 1} | |
m_AmbientEquatorColor: {r: .114, g: .125, b: .133000001, a: 1} | |
m_AmbientGroundColor: {r: .0469999984, g: .0430000015, b: .0350000001, a: 1} | |
m_AmbientIntensity: 1 | |
m_AmbientMode: 3 | |
m_SkyboxMaterial: {fileID: 0} | |
m_HaloStrength: .5 | |
m_FlareStrength: 1 | |
m_FlareFadeSpeed: 3 | |
m_HaloTexture: {fileID: 0} | |
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} | |
m_DefaultReflectionMode: 0 | |
m_DefaultReflectionResolution: 128 | |
m_ReflectionBounces: 1 | |
m_ReflectionIntensity: 1 | |
m_CustomReflection: {fileID: 0} | |
m_Sun: {fileID: 0} | |
--- !u!157 &3 | |
LightmapSettings: | |
m_ObjectHideFlags: 0 | |
serializedVersion: 5 | |
m_GIWorkflowMode: 1 | |
m_LightmapsMode: 1 | |
m_GISettings: | |
serializedVersion: 2 | |
m_BounceScale: 1 | |
m_IndirectOutputScale: 1 | |
m_AlbedoBoost: 1 | |
m_TemporalCoherenceThreshold: 1 | |
m_EnvironmentLightingMode: 0 | |
m_EnableBakedLightmaps: 0 | |
m_EnableRealtimeLightmaps: 0 | |
m_LightmapEditorSettings: | |
serializedVersion: 3 | |
m_Resolution: 2 | |
m_BakeResolution: 40 | |
m_TextureWidth: 1024 | |
m_TextureHeight: 1024 | |
m_AOMaxDistance: 1 | |
m_Padding: 2 | |
m_CompAOExponent: 0 | |
m_LightmapParameters: {fileID: 0} | |
m_TextureCompression: 1 | |
m_FinalGather: 0 | |
m_FinalGatherRayCount: 1024 | |
m_ReflectionCompression: 2 | |
m_LightmapSnapshot: {fileID: 0} | |
m_RuntimeCPUUsage: 25 | |
--- !u!196 &4 | |
NavMeshSettings: | |
serializedVersion: 2 | |
m_ObjectHideFlags: 0 | |
m_BuildSettings: | |
serializedVersion: 2 | |
agentRadius: .5 | |
agentHeight: 2 | |
agentSlope: 45 | |
agentClimb: .400000006 | |
ledgeDropHeight: 0 | |
maxJumpAcrossDistance: 0 | |
accuratePlacement: 0 | |
minRegionArea: 2 | |
cellSize: .166666672 | |
manualCellSize: 0 | |
m_NavMeshData: {fileID: 0} | |
--- !u!1 &476101859 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 476101860} | |
- 222: {fileID: 476101862} | |
- 114: {fileID: 476101861} | |
m_Layer: 5 | |
m_Name: Background-Flight | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!224 &476101860 | |
RectTransform: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 476101859} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 1866791882} | |
m_RootOrder: 1 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!114 &476101861 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 476101859} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: 1, g: 1, b: 1, a: 1} | |
m_RaycastTarget: 0 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 21300000, guid: 0115c816d260a0947976c8ea804febbc, type: 3} | |
m_Type: 0 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!222 &476101862 | |
CanvasRenderer: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 476101859} | |
--- !u!224 &1026898450 stripped | |
RectTransform: | |
m_PrefabParentObject: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, | |
type: 2} | |
m_PrefabInternal: {fileID: 1329571933} | |
--- !u!1001 &1329571933 | |
Prefab: | |
m_ObjectHideFlags: 0 | |
serializedVersion: 2 | |
m_Modification: | |
m_TransformParent: {fileID: 1866791882} | |
m_Modifications: | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalPosition.x | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalPosition.y | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalPosition.z | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalRotation.x | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalRotation.y | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalRotation.z | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_LocalRotation.w | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_RootOrder | |
value: 2 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.x | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.y | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.x | |
value: 250 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.y | |
value: 45 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMin.x | |
value: .5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMin.y | |
value: .5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMax.x | |
value: .5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMax.y | |
value: .5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_Pivot.x | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22476196, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_Pivot.y | |
value: 0 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMin.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMax.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.x | |
value: 125 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.y | |
value: -12.5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.x | |
value: 250 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22478174, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.y | |
value: 25 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22483410, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMin.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22483410, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMax.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22483410, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.x | |
value: 125 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22483410, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.x | |
value: 250 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22483410, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.y | |
value: 20 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMin.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchorMax.y | |
value: 1 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.x | |
value: 125 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_AnchoredPosition.y | |
value: -32.5 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.x | |
value: 250 | |
objectReference: {fileID: 0} | |
- target: {fileID: 22475412, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_SizeDelta.y | |
value: 25 | |
objectReference: {fileID: 0} | |
- target: {fileID: 11439582, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
propertyPath: m_Color.a | |
value: .784313738 | |
objectReference: {fileID: 0} | |
m_RemovedComponents: [] | |
m_ParentPrefab: {fileID: 100100000, guid: a41f85cb0b8964f43947e85b3e833c0f, type: 2} | |
m_IsPrefabParent: 0 | |
--- !u!1 &1398276586 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
serializedVersion: 4 | |
m_Component: | |
- 4: {fileID: 1398276590} | |
- 114: {fileID: 1398276589} | |
- 114: {fileID: 1398276588} | |
- 114: {fileID: 1398276587} | |
m_Layer: 0 | |
m_Name: EventSystem | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!114 &1398276587 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1398276586} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1997211142, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_ForceModuleActive: 0 | |
--- !u!114 &1398276588 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1398276586} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1077351063, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_HorizontalAxis: Horizontal | |
m_VerticalAxis: Vertical | |
m_SubmitButton: Submit | |
m_CancelButton: Cancel | |
m_InputActionsPerSecond: 10 | |
m_RepeatDelay: .5 | |
m_ForceModuleActive: 0 | |
--- !u!114 &1398276589 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1398276586} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -619905303, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_FirstSelected: {fileID: 0} | |
m_sendNavigationEvents: 1 | |
m_DragThreshold: 5 | |
--- !u!4 &1398276590 | |
Transform: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1398276586} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 0} | |
m_RootOrder: 2 | |
--- !u!1 &1866791878 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 1866791882} | |
- 223: {fileID: 1866791881} | |
- 114: {fileID: 1866791880} | |
- 114: {fileID: 1866791879} | |
m_Layer: 5 | |
m_Name: Canvas | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!114 &1866791879 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1866791878} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1301386320, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_IgnoreReversedGraphics: 1 | |
m_BlockingObjects: 0 | |
m_BlockingMask: | |
serializedVersion: 2 | |
m_Bits: 4294967295 | |
--- !u!114 &1866791880 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1866791878} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: 1980459831, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_UiScaleMode: 0 | |
m_ReferencePixelsPerUnit: 100 | |
m_ScaleFactor: 1 | |
m_ReferenceResolution: {x: 800, y: 600} | |
m_ScreenMatchMode: 0 | |
m_MatchWidthOrHeight: 0 | |
m_PhysicalUnit: 3 | |
m_FallbackScreenDPI: 96 | |
m_DefaultSpriteDPI: 96 | |
m_DynamicPixelsPerUnit: 1 | |
--- !u!223 &1866791881 | |
Canvas: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1866791878} | |
m_Enabled: 1 | |
serializedVersion: 2 | |
m_RenderMode: 0 | |
m_Camera: {fileID: 0} | |
m_PlaneDistance: 100 | |
m_PixelPerfect: 0 | |
m_ReceivesEvents: 1 | |
m_OverrideSorting: 0 | |
m_OverridePixelPerfect: 0 | |
m_SortingLayerID: 0 | |
m_SortingOrder: 0 | |
--- !u!224 &1866791882 | |
RectTransform: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 1866791878} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 0, y: 0, z: 0} | |
m_Children: | |
- {fileID: 2037475081} | |
- {fileID: 476101860} | |
- {fileID: 1026898450} | |
m_Father: {fileID: 0} | |
m_RootOrder: 1 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 0, y: 0} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: 0, y: 0} | |
--- !u!1 &2037475080 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
serializedVersion: 4 | |
m_Component: | |
- 224: {fileID: 2037475081} | |
- 222: {fileID: 2037475083} | |
- 114: {fileID: 2037475082} | |
m_Layer: 5 | |
m_Name: Background-Editor | |
m_TagString: Untagged | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!224 &2037475081 | |
RectTransform: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2037475080} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: 0} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 1866791882} | |
m_RootOrder: 0 | |
m_AnchorMin: {x: 0, y: 0} | |
m_AnchorMax: {x: 1, y: 1} | |
m_AnchoredPosition: {x: 0, y: 0} | |
m_SizeDelta: {x: 0, y: 0} | |
m_Pivot: {x: .5, y: .5} | |
--- !u!114 &2037475082 | |
MonoBehaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2037475080} | |
m_Enabled: 1 | |
m_EditorHideFlags: 0 | |
m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} | |
m_Name: | |
m_EditorClassIdentifier: | |
m_Material: {fileID: 0} | |
m_Color: {r: 1, g: 1, b: 1, a: 1} | |
m_RaycastTarget: 0 | |
m_OnCullStateChanged: | |
m_PersistentCalls: | |
m_Calls: [] | |
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, | |
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null | |
m_Sprite: {fileID: 21300000, guid: b0e2a09d07dbbcb40b0d4db43cd044f9, type: 3} | |
m_Type: 0 | |
m_PreserveAspect: 0 | |
m_FillCenter: 1 | |
m_FillMethod: 4 | |
m_FillAmount: 1 | |
m_FillClockwise: 1 | |
m_FillOrigin: 0 | |
--- !u!222 &2037475083 | |
CanvasRenderer: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2037475080} | |
--- !u!1 &2134872726 | |
GameObject: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
serializedVersion: 4 | |
m_Component: | |
- 4: {fileID: 2134872731} | |
- 20: {fileID: 2134872730} | |
- 92: {fileID: 2134872729} | |
- 124: {fileID: 2134872728} | |
- 81: {fileID: 2134872727} | |
m_Layer: 0 | |
m_Name: Main Camera | |
m_TagString: MainCamera | |
m_Icon: {fileID: 0} | |
m_NavMeshLayer: 0 | |
m_StaticEditorFlags: 0 | |
m_IsActive: 1 | |
--- !u!81 &2134872727 | |
AudioListener: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2134872726} | |
m_Enabled: 1 | |
--- !u!124 &2134872728 | |
Behaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2134872726} | |
m_Enabled: 1 | |
--- !u!92 &2134872729 | |
Behaviour: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2134872726} | |
m_Enabled: 1 | |
--- !u!20 &2134872730 | |
Camera: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2134872726} | |
m_Enabled: 1 | |
serializedVersion: 2 | |
m_ClearFlags: 2 | |
m_BackGroundColor: {r: 0, g: 0, b: 0, a: .0196078438} | |
m_NormalizedViewPortRect: | |
serializedVersion: 2 | |
x: 0 | |
y: 0 | |
width: 1 | |
height: 1 | |
near clip plane: .300000012 | |
far clip plane: 1000 | |
field of view: 60 | |
orthographic: 1 | |
orthographic size: 5 | |
m_Depth: -1 | |
m_CullingMask: | |
serializedVersion: 2 | |
m_Bits: 4294967295 | |
m_RenderingPath: -1 | |
m_TargetTexture: {fileID: 0} | |
m_TargetDisplay: 0 | |
m_TargetEye: 3 | |
m_HDR: 0 | |
m_OcclusionCulling: 1 | |
m_StereoConvergence: 10 | |
m_StereoSeparation: .0219999999 | |
m_StereoMirrorMode: 0 | |
--- !u!4 &2134872731 | |
Transform: | |
m_ObjectHideFlags: 0 | |
m_PrefabParentObject: {fileID: 0} | |
m_PrefabInternal: {fileID: 0} | |
m_GameObject: {fileID: 2134872726} | |
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | |
m_LocalPosition: {x: 0, y: 0, z: -10} | |
m_LocalScale: {x: 1, y: 1, z: 1} | |
m_Children: [] | |
m_Father: {fileID: 0} | |
m_RootOrder: 0 | |
using UnityEditor; | |
using UnityEngine; | |
public class BuildAssetBundles : MonoBehaviour | |
{ | |
[MenuItem("Assets/Build Asset Bundles")] | |
public static void Build() | |
{ | |
BuildPipeline.BuildAssetBundles(Application.dataPath + "/../Output/KerbalEngineer", BuildAssetBundleOptions.UncompressedAssetBundle); | |
} | |
} |
Binary files /dev/null and b/Assets/Testing/background-editor.png differ
Binary files /dev/null and b/Assets/Testing/background-flight.png differ
Binary files a/Assets/ToolbarBackground.psd and /dev/null differ
Binary files a/Assets/ToolbarIcon.psd and /dev/null differ
1.0.18.1 | Changed: Thermal flux is now correctly indicated in kilowatts. |
1.0.19.4, 12-02-16 | |
Fixed: Only 'STAGE_STACK_FLOW' and 'STAGE_STACK_FLOW_BALANCE' resources include surface mounted parts as fuel targets. | |
Fixed: Fairing mass being doubled in the VAB (removed workaround for a KSP bug which has been fixed). | |
1.0.19.3, 09-02-16 | |
Fixed: Fuel cross-feed from surface attached parts. | |
1.0.19.2, 19-11-15 | |
Rebuild for KSP 1.0.5.1028 silent update. | |
1.0.19.1, 09-11-15 | |
Added: Key binding editor accessible under 'Settings' on the Build Engineer. | |
Added: Added current vessel name readout. (antplant) | |
Added: 'Relative Radial Velocity' and 'Time To Rendezvous' readouts. (itwtx) | |
Added: Readout help strings. (harryyoung) | |
Changed: The 'Torque' value in the editor is now precise to two decimal places. | Changed: The 'Torque' value in the editor is now precise to two decimal places. |
Changed: Time formatting reference (Kerbin/Earth) is now based on the in-game setting. | |
Changed: Eccentric Anomaly, Mean Anomaly and Mean Anomaly At Epoc now display in degrees rather than radians. | |
Fixed: Optimised time formatting. (itwtx) | |
Fixed: TimeToAtmosphere checks that the Apoapsis is outside atmosphere. (Kerbas-ad-astra) | |
Fixed: Issue with stage priority flow. Caused Rapier calculations to fail if LF and O are drawn from different tanks. (Padishar) | |
Fixed: Issue with angle to prograde/retrograde calculations on highly inclined orbits. | |
Fixed: Editor input locks not being reset when a scene change is forced (e.g. via Kerbal Construction Time). | |
Fixed: Roll axis readout now shows the correct sign. | |
Removed: Time Formatter readout as it's not required anymore. | |
1.0.18.0 | 1.0.18.0 |
Added: Orbital readouts - "Speed at Periapsis" and "Speed at Apoapsis". (Padishar) | Added: Orbital readouts - "Speed at Periapsis" and "Speed at Apoapsis". (Padishar) |
Added: Manoeuvre readouts - "Post-burn Apoapsis" and "Post-burn Periapsis". (Padishar) | Added: Manoeuvre readouts - "Post-burn Apoapsis" and "Post-burn Periapsis". (Padishar) |
Added: Orbital readout - "Time to Atmosphere". | Added: Orbital readout - "Time to Atmosphere". |
Fixed: Synched the minimum simulation time sliders and stopped them from snapping back after 999ms. (saybur) | Fixed: Synched the minimum simulation time sliders and stopped them from snapping back after 999ms. (saybur) |
Fixed: Added workaround for the bug in Vessel.horizontalSrfSpeed (Padishar) | Fixed: Added workaround for the bug in Vessel.horizontalSrfSpeed (Padishar) |
Fixed: Physically insignificant part mass was not being correctly cascaded down through multiple parent parts. | Fixed: Physically insignificant part mass was not being correctly cascaded down through multiple parent parts. |
Fixed: Intake air demand calculation not working. | Fixed: Intake air demand calculation not working. |
Fixed: Some build engineer settings labels do not scale with UI size. | Fixed: Some build engineer settings labels do not scale with UI size. |
1.0.17.0 | 1.0.17.0 |
Added: 'Mach Number' readout under the 'Surface' category and included it on the default surface HUD. | Added: 'Mach Number' readout under the 'Surface' category and included it on the default surface HUD. |
Added: Stock sections in the Flight Engineer can now become HUDs. | Added: Stock sections in the Flight Engineer can now become HUDs. |
Added 'Thermal' readouts category including: | Added 'Thermal' readouts category including: |
Internal Flux | Internal Flux |
Convection Flux | Convection Flux |
Radiation Flux | Radiation Flux |
Critical Part Name | Critical Part Name |
Critical Part Temperature | Critical Part Temperature |
Critical Part Skin Temperature | Critical Part Skin Temperature |
Critical Part Thermal Percentage of Max Temperature | Critical Part Thermal Percentage of Max Temperature |
Hottest Part Name | Hottest Part Name |
Hottest Part Temperature | Hottest Part Temperature |
Hottest Part Skin Temperature | Hottest Part Skin Temperature |
Coldest Part Name | Coldest Part Name |
Coldest Part Temperature | Coldest Part Temperature |
Coldest Part Skin Temperature | Coldest Part Skin Temperature |
Changed: Mach on the Build Engineer now accurate to 2 decimal places. | Changed: Mach on the Build Engineer now accurate to 2 decimal places. |
Changed: Max mach in the Build Engineer defaults to 1.00 even when no jet engines are present. | Changed: Max mach in the Build Engineer defaults to 1.00 even when no jet engines are present. |
Changed: Increased eccentricity readout to 5 decimal places. | Changed: Increased eccentricity readout to 5 decimal places. |
Changed: Implemented Sarbian's object pooling. | Changed: Implemented Sarbian's object pooling. |
Changed: The default selected body is now assigned via 'Planitarium.Home'. | Changed: The default selected body is now assigned via 'Planitarium.Home'. |
Changed: HUDs to clamp fully inside the screen instead of allowing them to run off the edge by a certain amount. | Changed: HUDs to clamp fully inside the screen instead of allowing them to run off the edge by a certain amount. |
Fixed: Physically insignificant part mass is now associated with the parent part. | Fixed: Physically insignificant part mass is now associated with the parent part. |
Fixed: Longitude and Latitude readouts now use a KER formatter instead of Squad's incorrect implementation. | Fixed: Longitude and Latitude readouts now use a KER formatter instead of Squad's incorrect implementation. |
Fixed: Possible null reference in the Rendezvous Processor. | Fixed: Possible null reference in the Rendezvous Processor. |
Fixed: Fairing mass issues introduced with regards to simulation changes. | Fixed: Fairing mass issues introduced with regards to simulation changes. |
Fixed: Use of per-propellant fuel flow mode override. | Fixed: Use of per-propellant fuel flow mode override. |
Fixed: Burn times calculated for jet engines. | Fixed: Burn times calculated for jet engines. |
Fixed: Thrust issues introduced with Sarbian's simulation alterations. | Fixed: Thrust issues introduced with Sarbian's simulation alterations. |
Fixed: Issue where HUDs positioned close to the top/bottom of the screen could be pushed out of position. | Fixed: Issue where HUDs positioned close to the top/bottom of the screen could be pushed out of position. |
1.0.16.6, 02-05-15 | 1.0.16.6, 02-05-15 |
Fixed: Separately staged fairing mass jettisons are now calculated in the editor. | Fixed: Separately staged fairing mass jettisons are now calculated in the editor. |
1.0.16.5, 02-05-2015 | 1.0.16.5, 02-05-2015 |
Fixed: Delta-V not being correctly calculated. | Fixed: Delta-V not being correctly calculated. |
Changed: Editor locking now uses the InputLockManager. | Changed: Editor locking now uses the InputLockManager. |
1.0.16.4, 01-05-2015 | 1.0.16.4, 01-05-2015 |
Fixed: Physically insignificant part mass is now accounted for. | Fixed: Physically insignificant part mass is now accounted for. |
Changed: Module mass accounted for as it now makes its way onto the launch pad (e.g. fairings). | Changed: Module mass accounted for as it now makes its way onto the launch pad (e.g. fairings). |
Various optimisations: | Various optimisations: |
Object pooling. | Object pooling. |
Removed LINQ expressions. | Removed LINQ expressions. |
Converted foreach to for loops. | Converted foreach to for loops. |
1.0.16.3, 27-04-2015 | 1.0.16.3, 27-04-2015 |
Fixed issue with the toolbar icons not being created. | Fixed issue with the toolbar icons not being created. |
Removed superfluous 'm/s' on the mach slider in the build engineer. | Removed superfluous 'm/s' on the mach slider in the build engineer. |
1.0.16.2, 27-04-2015 | 1.0.16.2, 27-04-2015 |
Changed the atmospheric slider on the build engineer to default to 0km when changing bodies. | Changed the atmospheric slider on the build engineer to default to 0km when changing bodies. |
1.0.16.1, 26-04-2015, KSP Build #828 | 1.0.16.1, 26-04-2015, KSP Build #828 |
Merged Sarbian's mach adjustments. | Merged Sarbian's mach adjustments. |
Fixed bugs relating to thrust and atmosphere/velocity curves. | Fixed bugs relating to thrust and atmosphere/velocity curves. |
Changed the atmospheric slider on the Build Engineer to work based on altitude. | Changed the atmospheric slider on the Build Engineer to work based on altitude. |
Changed the atmospheric slider to clamp to the maximum altitude for the selected body. | Changed the atmospheric slider to clamp to the maximum altitude for the selected body. |
Changed the velocity slider to clamp to the maximum usable mach value for the current vessel. | Changed the velocity slider to clamp to the maximum usable mach value for the current vessel. |
1.0.16.0, 25-04-2015, KSP Build #821 | 1.0.16.0, 25-04-2015, KSP Build #821 |
Fixed errors relating to KSP 1.0 update. | Fixed errors relating to KSP 1.0 update. |
Fixed fuel simulation to account for new thrust system. | Fixed fuel simulation to account for new thrust system. |
Fixed atmospheric engines to use the new velocity curve. | Fixed atmospheric engines to use the new velocity curve. |
Fixed atmospheric readouts to work with the new atmospheric model. | Fixed atmospheric readouts to work with the new atmospheric model. |
1.0.15.2, 13-02-2015 | 1.0.15.2, 13-02-2015 |
Padishar's Fixes: | Padishar's Fixes: |
Fixed: Calculation of per-stage resource mass. | Fixed: Calculation of per-stage resource mass. |
1.0.15.1, 13-02-2015 | 1.0.15.1, 13-02-2015 |
Rebuild | Rebuild |
1.0.15.0, 08-02-2015 | 1.0.15.0, 08-02-2015 |
Padishar's Fixes: | Padishar's Fixes: |
Added: Support KIDS ISP thrust correction. | Added: Support KIDS ISP thrust correction. |
Fixed: Log spam for stage priority mode. | Fixed: Log spam for stage priority mode. |
Fixed: Locked tanks preventing simulation from staging. | Fixed: Locked tanks preventing simulation from staging. |
Fixed: No flow and all vessel modes to respect flow states. | Fixed: No flow and all vessel modes to respect flow states. |
1.0.14.1, 28-12-2014 | 1.0.14.1, 28-12-2014 |
Fixed: Missing texture on the ER-7500 model. | Fixed: Missing texture on the ER-7500 model. |
1.0.14.0, 28-12-2014 | 1.0.14.0, 28-12-2014 |
Added: Career mode that limits the Flight Engineer by: | Added: Career mode that limits the Flight Engineer by: |
- Requiring an Engineer Kerbal of any level, or placement of an Engineer Chip or ER-7500 part. | - Requiring an Engineer Kerbal of any level, or placement of an Engineer Chip or ER-7500 part. |
- Tracking station level 3 enables Flight Engineer everywhere. | - Tracking station level 3 enables Flight Engineer everywhere. |
Added: New readouts to the orbital category: | Added: New readouts to the orbital category: |
- Mean Anomaly at Epoc | - Mean Anomaly at Epoc |
Added: New readouts to the miscellaneous category: | Added: New readouts to the miscellaneous category: |
- System Time | - System Time |
Added: Editor Overlay Tab's X position is now changable in the BuildOverlay.xml settings file. | Added: Editor Overlay Tab's X position is now changable in the BuildOverlay.xml settings file. |
Changed: Editor Overlay Tabs start position moved over as to not overlap the parts menu. | Changed: Editor Overlay Tabs start position moved over as to not overlap the parts menu. |
Fixed: Bug where STAGE_PRIORITY_FLOW resources would not be corrently disabled/enabled. | Fixed: Bug where STAGE_PRIORITY_FLOW resources would not be corrently disabled/enabled. |
Fixed: Issue with the formatting large Mass and Cost values. | Fixed: Issue with the formatting large Mass and Cost values. |
Fixed: Error when loading the Engineer7500 part model. | Fixed: Error when loading the Engineer7500 part model. |
1.0.13.1, 16-12-2014 | 1.0.13.1, 16-12-2014 |
Fixed: Issue with manoeuvre node readouts and low tier tracking station. | Fixed: Issue with manoeuvre node readouts and low tier tracking station. |
1.0.13.0, 16-12-2014 | 1.0.13.0, 16-12-2014 |
Updated for KSP version 0.90 | Updated for KSP version 0.90 |
Added: New readouts to the vessel category: | Added: New readouts to the vessel category: |
- Heading Rate | - Heading Rate |
- Pitch Rate | - Pitch Rate |
- Roll Rate | - Roll Rate |
Changed: Simulation to look for fuel lines that use CModuleFuelLine module. | Changed: Simulation to look for fuel lines that use CModuleFuelLine module. |
Fixed: Editor Overlay now loads the saved visibility value properly. | Fixed: Editor Overlay now loads the saved visibility value properly. |
Fixed: Altitude (Terrain) will no longer give a reading below sea level. | Fixed: Altitude (Terrain) will no longer give a reading below sea level. |
Fixed: Suicide burn now uses radar altitude that clamps to sea level. | Fixed: Suicide burn now uses radar altitude that clamps to sea level. |
1.0.12.0, 01-12-2014 | 1.0.12.0, 01-12-2014 |
Added: Setting in Build Engineer to enable/disable vectored thrust calculations. | Added: Setting in Build Engineer to enable/disable vectored thrust calculations. |
Added: Thrust torque field in Build Engineer (courtesy of mic_e). | Added: Thrust torque field in Build Engineer (courtesy of mic_e). |
Added: New readouts to the vessel category: | Added: New readouts to the vessel category: |
- Thrust Offset Angle (courtesy of mic_e) | - Thrust Offset Angle (courtesy of mic_e) |
- Thrust Torque (courtesy of mic_e) | - Thrust Torque (courtesy of mic_e) |
- Part Count: stage/total | - Part Count: stage/total |
- Heading | - Heading |
- Pitch | - Pitch |
- Roll | - Roll |
Added: New readouts to the surface category: | Added: New readouts to the surface category: |
- Situation | - Situation |
Added: New readouts to the miscellaneous category: | Added: New readouts to the miscellaneous category: |
- Vectored Thrust Toggle | - Vectored Thrust Toggle |
Fixed: The category selection within the section editors now do not always reset back to 'Orbital'. | Fixed: The category selection within the section editors now do not always reset back to 'Orbital'. |
Fixed: Issue where the vessel simulation can sometimes permanently freeze. | Fixed: Issue where the vessel simulation can sometimes permanently freeze. |
Fixed: Issue where the vessel simulation would not show updates when the delay was set lower than the frame rate. | Fixed: Issue where the vessel simulation would not show updates when the delay was set lower than the frame rate. |
1.0.11.3, 11-11-2014 | 1.0.11.3, 11-11-2014 |
Changed: Gravity measurements for Isp to 9.82. | Changed: Gravity measurements for Isp to 9.82. |
1.0.11.2, 10-11-2014 | 1.0.11.2, 10-11-2014 |
Changed: Gravity measurements for Isp calculations from 9.81 to 9.8066 for accuracy. | Changed: Gravity measurements for Isp calculations from 9.81 to 9.8066 for accuracy. |
Changed: Manoeuvre node burn times are now more accurate. | Changed: Manoeuvre node burn times are now more accurate. |
Fixed: Bug in the manoeuvre node burn time calculations where it was not averaging acceleration correctly. | Fixed: Bug in the manoeuvre node burn time calculations where it was not averaging acceleration correctly. |
1.0.11.1, 07-11-2014 | 1.0.11.1, 07-11-2014 |
Changed: Build Engineer now shows stage part count as well as total. | Changed: Build Engineer now shows stage part count as well as total. |
Changed: Build Overlay Vessel tab data: | Changed: Build Overlay Vessel tab data: |
DeltaV: stage / total | DeltaV: stage / total |
Mass: stage / total | Mass: stage / total |
TWR: start (max) <- shows for bottom stage only. | TWR: start (max) <- shows for bottom stage only. |
Parts: stage / total | Parts: stage / total |
Fixed: Issue with the vessel tab vanishing from the editor. | Fixed: Issue with the vessel tab vanishing from the editor. |
1.0.11.0, 06-11-2014 | 1.0.11.0, 06-11-2014 |
Added: New readouts to the orbital category: | Added: New readouts to the orbital category: |
- Current SOI | - Current SOI |
- Manoeuvre Node DeltaV (Prograde) | - Manoeuvre Node DeltaV (Prograde) |
- Manoeuvre Node DeltaV (Normal) | - Manoeuvre Node DeltaV (Normal) |
- Manoeuvre Node DeltaV (Radial) | - Manoeuvre Node DeltaV (Radial) |
- Manoeuvre Node DeltaV (Total) | - Manoeuvre Node DeltaV (Total) |
- Manoeuvre Node Burn Time | - Manoeuvre Node Burn Time |
- Manoeuvre Node Half Burn Time | - Manoeuvre Node Half Burn Time |
- Manoeuvre Node Angle to Prograde | - Manoeuvre Node Angle to Prograde |
- Manoeuvre Node Angle to Retrograde | - Manoeuvre Node Angle to Retrograde |
- Time to Manoeuvre Node | - Time to Manoeuvre Node |
- Time to Manoeuvre Burn | - Time to Manoeuvre Burn |
Added: Readout help strings by ClassyJakey. | Added: Readout help strings by ClassyJakey. |
Fixed: Issue with separators in HUDs. | Fixed: Issue with separators in HUDs. |
Fixed: Issue with HUDs with backgrounds that have no displayed lines. | Fixed: Issue with HUDs with backgrounds that have no displayed lines. |
Padishar's Fixes: | Padishar's Fixes: |
Fixed: Issue with multicouplers when attached to parent by bottom node. | Fixed: Issue with multicouplers when attached to parent by bottom node. |
Fixed: Issue with sepratrons on solid rocket boosters. | Fixed: Issue with sepratrons on solid rocket boosters. |
1.0.10.0, 19-10-2014 | 1.0.10.0, 19-10-2014 |
UPDATE NOTICE: If you are updating from a previous version of Kerbal Engineer 1.0, please | UPDATE NOTICE: If you are updating from a previous version of Kerbal Engineer 1.0, please |
delete the 'Settings/SectionLibrary.xml' file, or remove the old install first. This will | delete the 'Settings/SectionLibrary.xml' file, or remove the old install first. This will |
reset the Flight Engineer sections to their default values and enable the new HUD functionality. | reset the Flight Engineer sections to their default values and enable the new HUD functionality. |
Added: New reaouts to the vessel category: | Added: New reaouts to the vessel category: |
- Suicide Burn Altitude (height above terrain to start burn) | - Suicide Burn Altitude (height above terrain to start burn) |
- Suicide Burn Distance (distance to suicide burn altitude) | - Suicide Burn Distance (distance to suicide burn altitude) |
- Suicide Burn DeltaV (velocity change required to zero vertical speed) | - Suicide Burn DeltaV (velocity change required to zero vertical speed) |
*** F5 for safety and use at your own risk! *** | *** F5 for safety and use at your own risk! *** |
Added: HUD type sections to the Flight Engineer. | Added: HUD type sections to the Flight Engineer. |
Added: HUD sections can have a smoked background for easy visibility. | Added: HUD sections can have a smoked background for easy visibility. |
Added: 'Switch to Target' button on the Target Selector readout. | Added: 'Switch to Target' button on the Target Selector readout. |
Changed: The default installed readouts to reduce new user brain melt. | Changed: The default installed readouts to reduce new user brain melt. |
Fixed: Flight Engineer not saving its hidden state. | Fixed: Flight Engineer not saving its hidden state. |
Fixed: Bug in the phase angle calculations. | Fixed: Bug in the phase angle calculations. |
Fixed: Bug where the Build Engineer would stay locked after hiding with the shortcut key. | Fixed: Bug where the Build Engineer would stay locked after hiding with the shortcut key. |
1.0.9.3, 08-10-2014 | 1.0.9.3, 08-10-2014 |
Added: Title of the build engineer in compact mode now shows if you are using atmospheric data. | Added: Title of the build engineer in compact mode now shows if you are using atmospheric data. |
Added: New readout to the surface category: | Added: New readout to the surface category: |
- Vertical Acceleration | - Vertical Acceleration |
- Horizontal Acceleration | - Horizontal Acceleration |
Changed: Atmospheric efficiency readout now shows as a percentage. | Changed: Atmospheric efficiency readout now shows as a percentage. |
Changed: Atmospheric settings (pressure/velocity) in the editor condensed onto a single line. | Changed: Atmospheric settings (pressure/velocity) in the editor condensed onto a single line. |
Fixed: Bug where the overlays in the editor would stay open outside of parts screen. | Fixed: Bug where the overlays in the editor would stay open outside of parts screen. |
1.0.9.2, 07-10-2014 | 1.0.9.2, 07-10-2014 |
Updated for KSP v0.25.0 | Updated for KSP v0.25.0 |
Changed: Prettyfied Latitude and Longitude readouts. | Changed: Prettyfied Latitude and Longitude readouts. |
Changed: ModuleLandingGear now uses the physical significance flag. | Changed: ModuleLandingGear now uses the physical significance flag. |
Changed: Updated MiniAVC to 1.0.2.4. | Changed: Updated MiniAVC to 1.0.2.4. |
1.0.9.1, 17-09-2014 | 1.0.9.1, 17-09-2014 |
Fixed: Part size bug caused by TweakScale's cost calculator. | Fixed: Part size bug caused by TweakScale's cost calculator. |
1.0.9.0, 15-09-2014 | 1.0.9.0, 15-09-2014 |
Added: Build Engineer now also implements the '\' backslash show/hide shortcut. | Added: Build Engineer now also implements the '\' backslash show/hide shortcut. |
Added: New readouts to the vessel category: | Added: New readouts to the vessel category: |
- Current Stage DeltaV | - Current Stage DeltaV |
- Surface Thrust to Weight Ratio | - Surface Thrust to Weight Ratio |
Added: New editor overlay system. | Added: New editor overlay system. |
- Sleeker design. | - Sleeker design. |
- Hover over part information options: | - Hover over part information options: |
- Name only | - Name only |
- Middle click to show | - Middle click to show |
- Always show | - Always show |
- Slide out overlay displays: | - Slide out overlay displays: |
- Vessel information | - Vessel information |
- Resources list | - Resources list |
Fixed: Cost calculation now works with mods implementing IPartCostModifier. | Fixed: Cost calculation now works with mods implementing IPartCostModifier. |
1.0.8.1, 06-09-2014 | 1.0.8.1, 06-09-2014 |
Fixed: Bug which caused rendezvous readouts to freeze the game or show all zeros. | Fixed: Bug which caused rendezvous readouts to freeze the game or show all zeros. |
1.0.8.0, 06-09-2014 | 1.0.8.0, 06-09-2014 |
Added: New readouts to the vessel category: | Added: New readouts to the vessel category: |
- Intake Air (Usage) | - Intake Air (Usage) |
Added: New readouts to the rendezvous category: | Added: New readouts to the rendezvous category: |
- Relative Velocity | - Relative Velocity |
- Relative Speed | - Relative Speed |
Fixed: An issue where deltaV would not be calculated whilst flying. | Fixed: An issue where deltaV would not be calculated whilst flying. |
Fixed: NullRef whilst loading the in flight Action Menu. | Fixed: NullRef whilst loading the in flight Action Menu. |
1.0.7.1, 02-09-2014 | 1.0.7.1, 02-09-2014 |
Changed: Reversed Intake Air readout from 'S/D' to 'D/S' for easier reading. | Changed: Reversed Intake Air readout from 'S/D' to 'D/S' for easier reading. |
Changed: Increased Intake Air readout precision to 4 decimal places. | Changed: Increased Intake Air readout precision to 4 decimal places. |
Fixed: Issue where Intake Air supply was not representative of total supply. | Fixed: Issue where Intake Air supply was not representative of total supply. |
Fixed: Bug where actual thrust does not reset to zero on deactivated engines. | Fixed: Bug where actual thrust does not reset to zero on deactivated engines. |
Fixed: Thrust now scales with velocity for atmospheric engines. (Padishar's fix) | Fixed: Thrust now scales with velocity for atmospheric engines. (Padishar's fix) |
1.0.7.0, 01-09-2014 | 1.0.7.0, 01-09-2014 |
Added: Part count information to the Build Engineer. | Added: Part count information to the Build Engineer. |
Added: Reset button to the G-Force readout. | Added: Reset button to the G-Force readout. |
Added: Preset system to the Flight Engineer. | Added: Preset system to the Flight Engineer. |
Added: New stock presets: | Added: New stock presets: |
- Orbital | - Orbital |
- Surface | - Surface |
- Vessel | - Vessel |
- Rendezvous | - Rendezvous |
Added: New readouts to the orbital category: | Added: New readouts to the orbital category: |
- True Anomaly | - True Anomaly |
- Eccentric Anomaly | - Eccentric Anomaly |
- Mean Anomaly | - Mean Anomaly |
- Argument of Periapsis | - Argument of Periapsis |
- Angle to Prograde | - Angle to Prograde |
- Angle to Retrograde | - Angle to Retrograde |
Added: New readouts to the vessel category: | Added: New readouts to the vessel category: |
- Intake Air (Demand) | - Intake Air (Demand) |
- Intake Air (Supply) | - Intake Air (Supply) |
- Intake Air (Supply/Demand) | - Intake Air (Supply/Demand) |
Added: New readouts to the rendezvous category. | Added: New readouts to the rendezvous category. |
- Semi-major Axis | - Semi-major Axis |
- Semi-minor Axis | - Semi-minor Axis |
Added: Time formatter which can show time as referenced by any celestial body. | Added: Time formatter which can show time as referenced by any celestial body. |
Added: New readouts to the miscellaneous category: | Added: New readouts to the miscellaneous category: |
- Time Reference Adjuster | - Time Reference Adjuster |
Changed: Moved Sim Delay readout into the Miscellaneous category. | Changed: Moved Sim Delay readout into the Miscellaneous category. |
Changed: Updated MiniAVC to v1.0.2.3. | Changed: Updated MiniAVC to v1.0.2.3. |
Fixed: Issues with large value wrap around in the Flight Engineer. | Fixed: Issues with large value wrap around in the Flight Engineer. |
Fixed: Bug in the phase angle calculation. | Fixed: Bug in the phase angle calculation. |
1.0.6.0, 23-08-2014 | 1.0.6.0, 23-08-2014 |
Added: Time and Angle to equatorial ascending/descending nodes in the orbital display. | Added: Time and Angle to equatorial ascending/descending nodes in the orbital display. |
Added: Time and Angle to relative ascending/descending nodes in the rendezvous display. | Added: Time and Angle to relative ascending/descending nodes in the rendezvous display. |
Added: Overlay tooltip information delay adjustment slider to the Build Engineer settings. | Added: Overlay tooltip information delay adjustment slider to the Build Engineer settings. |
Added: Ability to rename the stock displays in the Flight Engineer. | Added: Ability to rename the stock displays in the Flight Engineer. |
Changed: Build Engineer is now hidden when not in parts view. | Changed: Build Engineer is now hidden when not in parts view. |
Changed: Custom display panels will only show in the control bar if an abbreviation is set. | Changed: Custom display panels will only show in the control bar if an abbreviation is set. |
Changed: Licensing and readme structures are now more verbose to satisfy the new add-on rules. | Changed: Licensing and readme structures are now more verbose to satisfy the new add-on rules. |
Fixed: Updated MiniAVC to v1.0.2.1 (fixes remote check bug as well as other minor bugs). | Fixed: Updated MiniAVC to v1.0.2.1 (fixes remote check bug as well as other minor bugs). |
1.0.5.0, 13-08-2014 | 1.0.5.0, 13-08-2014 |
Added: Acceleration readout to the Vessel category (current / maximum). | Added: Acceleration readout to the Vessel category (current / maximum). |
Added: Category library system for the Flight Engineer readouts. | Added: Category library system for the Flight Engineer readouts. |
Added: Drop-down category selection to better support the new system. | Added: Drop-down category selection to better support the new system. |
Changed: Misc category now called Miscellaneous (this will cause previously added readouts from this category to vanish). | Changed: Misc category now called Miscellaneous (this will cause previously added readouts from this category to vanish). |
Fixed: Bug with the Build Engineer toolbar button. | Fixed: Bug with the Build Engineer toolbar button. |
Fixed: Some buggyness when trying to close the bodies drop-down in the Build Engineer via the button. | Fixed: Some buggyness when trying to close the bodies drop-down in the Build Engineer via the button. |
Fixed: Flight Engineer toolbar menu now hides when hiding the GUI with F2. | Fixed: Flight Engineer toolbar menu now hides when hiding the GUI with F2. |
Fixed: Flight Engineer toolbar button now disables when in module mode and no engineer is running. | Fixed: Flight Engineer toolbar button now disables when in module mode and no engineer is running. |
1.0.4.0, 12-08-2014 | 1.0.4.0, 12-08-2014 |
Added: Better stock toolbar support in the flight engineer. | Added: Better stock toolbar support in the flight engineer. |
Added: Dynamically generated celestial body library for supporting add-ons that modify the star system. | Added: Dynamically generated celestial body library for supporting add-ons that modify the star system. |
Changed: Reference bodies are now listed with a nestable menu system. | Changed: Reference bodies are now listed with a nestable menu system. |
Changed: Extended logging system has been improved. | Changed: Extended logging system has been improved. |
Changed: Swapped out integrated MiniAVC in place of the official bundle version. | Changed: Swapped out integrated MiniAVC in place of the official bundle version. |
Changed: Increased general distance precision to 1 decimal place. | Changed: Increased general distance precision to 1 decimal place. |
Changed: Increased Semi-major/minor axis precision to 3 decimal places. | Changed: Increased Semi-major/minor axis precision to 3 decimal places. |
Fixed: Impact altitude was mistakenly formatted as an angle, it is now formatted correctly as a distance. | Fixed: Impact altitude was mistakenly formatted as an angle, it is now formatted correctly as a distance. |
1.0.3.0, 30-07-2014 | 1.0.3.0, 30-07-2014 |
Added: Integrated KSP-AVC support with MiniAVC. | Added: Integrated KSP-AVC support with MiniAVC. |
Added: Setting to change the simulation delay in the Build Engineer. | Added: Setting to change the simulation delay in the Build Engineer. |
Added: Setting to enable and disable the build overlay system. | Added: Setting to enable and disable the build overlay system. |
Added: Burn time to Delta-V readouts. | Added: Burn time to Delta-V readouts. |
Added: Atmospheric readouts fully support FAR. | Added: Atmospheric readouts fully support FAR. |
Added: Atmospheric readouts are disabled with NEAR. | Added: Atmospheric readouts are disabled with NEAR. |
Changed: Force formatting inversely scales decimal precision with value. | Changed: Force formatting inversely scales decimal precision with value. |
Fixed: Flickering in VAB and Vessel display. | Fixed: Flickering in VAB and Vessel display. |
Fixed: Bug saving the GUI display size. | Fixed: Bug saving the GUI display size. |
1.0.2.0, 27-07-2014 | 1.0.2.0, 27-07-2014 |
Added: Separator readout module under Misc in the Flight Engineer. | Added: Separator readout module under Misc in the Flight Engineer. |
Added: Adjustable GUI display size. | Added: Adjustable GUI display size. |
Added: Display size can be adjusted in the Build Engineer settings. | Added: Display size can be adjusted in the Build Engineer settings. |
Added: Misc readout for adjusting display size in the Flight Engineer. | Added: Misc readout for adjusting display size in the Flight Engineer. |
Changed: The rendezvous readout for the target's Orbital Period has higher precision. | Changed: The rendezvous readout for the target's Orbital Period has higher precision. |
Fixed: White toolbar icon by manually importing the texture if it cannot be found in the game database. | Fixed: White toolbar icon by manually importing the texture if it cannot be found in the game database. |
Fixed: Engines that have a minimum thrust are now calculated properly. (Thanks to nosscire.) | Fixed: Engines that have a minimum thrust are now calculated properly. (Thanks to nosscire.) |
Fixed: Compact collapse mode is now saved in the Build Engineer. | Fixed: Compact collapse mode is now saved in the Build Engineer. |
1.0.1.0, 26-07-2014 | 1.0.1.0, 26-07-2014 |
Added: Part-less Flight Engineer. | Added: Part-less Flight Engineer. |
Added: Ability to collapse the Build Engineer into compact mode from left or right. | Added: Ability to collapse the Build Engineer into compact mode from left or right. |
Added: Settings in Build Engineer for compact collapse mode and partless/module Flight Engineer. | Added: Settings in Build Engineer for compact collapse mode and partless/module Flight Engineer. |
Added: Biome, Impact Biome and Slope readouts. | Added: Biome, Impact Biome and Slope readouts. |
Added: Extra logging and exception handling. | Added: Extra logging and exception handling. |
Added: The original Engineer Chip part. | Added: The original Engineer Chip part. |
Added: "Show Engineer" toggle on the Flight Engineer toolbar. | Added: "Show Engineer" toggle on the Flight Engineer toolbar. |
Changed: Extended logging system now also writes to the standard KSP logs. | Changed: Extended logging system now also writes to the standard KSP logs. |
Changed: Extended logging saves next to the .dll file. | Changed: Extended logging saves next to the .dll file. |
Changed: ER7500 part has no physical significance. | Changed: ER7500 part has no physical significance. |
Fixed: ActionMenu and DisplayStack destruction bug. | Fixed: ActionMenu and DisplayStack destruction bug. |
1.0.0.1, 24-07-2014 | 1.0.0.1, 24-07-2014 |
Added: Stock toolbar support in the Flight Engineer. | Added: Stock toolbar support in the Flight Engineer. |
Changed: Orbital Period has higher precision. | Changed: Orbital Period has higher precision. |
Fixed: Various NullRefs in editor window and overlay. | Fixed: Various NullRefs in editor window and overlay. |
1.0.0.0, 24-07-2014 | 1.0.0.0, 24-07-2014 |
Initial release for public testing. | Initial release for public testing. |
<?xml version="1.0" encoding="utf-8"?> | |
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<PropertyGroup> | |
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | |
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | |
<ProductVersion>10.0.20506</ProductVersion> | |
<SchemaVersion>2.0</SchemaVersion> | |
<ProjectGuid>{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}</ProjectGuid> | |
<OutputType>Library</OutputType> | |
<AssemblyName>Assembly-CSharp-Editor</AssemblyName> | |
<FileAlignment>512</FileAlignment> | |
<ProjectTypeGuids>{E097FAD1-6243-4DAD-9C02-E9B9EFC3FFC1};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> | |
<TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier> | |
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | |
<TargetFrameworkProfile>Unity Full v3.5</TargetFrameworkProfile> | |
<CompilerResponseFile></CompilerResponseFile> | |
<UnityProjectType>Editor:5</UnityProjectType> | |
<UnityBuildTarget>StandaloneWindows:5</UnityBuildTarget> | |
<UnityVersion>5.2.4f1</UnityVersion> | |
<RootNamespace></RootNamespace> | |
<LangVersion Condition=" '$(VisualStudioVersion)' != '10.0' ">4</LangVersion> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | |
<DebugType>pdbonly</DebugType> | |
<Optimize>false</Optimize> | |
<OutputPath>Temp\UnityVS_bin\Debug\</OutputPath> | |
<IntermediateOutputPath>Temp\UnityVS_obj\Debug\</IntermediateOutputPath> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
<DefineConstants>DEBUG;TRACE;UNITY_5_2_4;UNITY_5_2;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_2D_PHYSICS;ENABLE_4_6_FEATURES;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_RAKNET;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_HUB;ENABLE_CLOUD_PROJECT_ID;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_METRICS;ENABLE_REFLECTION_BUFFERS;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;ENABLE_ANDROID_ATLAS_ETC1_COMPRESSION;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_LOG_MIXED_STACKTRACE;ENABLE_UNITYWEBREQUEST;ENABLE_EVENT_QUEUE;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN</DefineConstants> | |
<AllowUnsafeBlocks>false</AllowUnsafeBlocks> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | |
<DebugType>pdbonly</DebugType> | |
<Optimize>false</Optimize> | |
<OutputPath>Temp\UnityVS_bin\Release\</OutputPath> | |
<IntermediateOutputPath>Temp\UnityVS_obj\Release\</IntermediateOutputPath> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
<DefineConstants>TRACE;UNITY_5_2_4;UNITY_5_2;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_2D_PHYSICS;ENABLE_4_6_FEATURES;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_RAKNET;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_HUB;ENABLE_CLOUD_PROJECT_ID;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_METRICS;ENABLE_REFLECTION_BUFFERS;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;ENABLE_ANDROID_ATLAS_ETC1_COMPRESSION;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_LOG_MIXED_STACKTRACE;ENABLE_UNITYWEBREQUEST;ENABLE_EVENT_QUEUE;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN</DefineConstants> | |
<AllowUnsafeBlocks>false</AllowUnsafeBlocks> | |
</PropertyGroup> | |
<ItemGroup> | |
<Reference Include="mscorlib" /> | |
<Reference Include="System" /> | |
<Reference Include="System.XML" /> | |
<Reference Include="System.Core" /> | |
<Reference Include="Boo.Lang" /> | |
<Reference Include="UnityScript.Lang" /> | |
<Reference Include="System.Runtime.Serialization" /> | |
<Reference Include="System.Xml.Linq" /> | |
<Reference Include="UnityEngine"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Advertisements"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Advertisements.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.UI"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.UI.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.UI"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.UI.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.Networking"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.Networking.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Networking"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Networking.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Graphs"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Graphs.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Android.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Android.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.iOS.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.iOS.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.WP8.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.WP8.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Metro.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Metro.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.Tizen.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.Tizen.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.SamsungTV.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.SamsungTV.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.WebGL.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.WebGL.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.LinuxStandalone.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.LinuxStandalone.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.WindowsStandalone.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.WindowsStandalone.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.OSXStandalone.Extensions"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.OSXStandalone.Extensions.dll</HintPath> | |
</Reference> | |
<Reference Include="SyntaxTree.VisualStudio.Unity.Bridge"> | |
<HintPath>Library\UnityAssemblies\SyntaxTree.VisualStudio.Unity.Bridge.dll</HintPath> | |
</Reference> | |
<Reference Include="Mono.Cecil"> | |
<HintPath>Library\UnityAssemblies\Mono.Cecil.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor.iOS.Extensions.Xcode"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.iOS.Extensions.Xcode.dll</HintPath> | |
</Reference> | |
<Reference Include="KerbalEngineer.Unity"> | |
<HintPath>Assets\Plugins\KerbalEngineer.Unity.dll</HintPath> | |
</Reference> | |
</ItemGroup> | |
<ItemGroup> | |
<Compile Include="Assets\Scripts\Editor\BuildAssetBundles.cs" /> | |
</ItemGroup> | |
<Import Project="$(MSBuildExtensionsPath)\SyntaxTree\UnityVS\2015\UnityVS.CSharp.targets" /> | |
</Project> | |
<?xml version="1.0" encoding="utf-8"?> | |
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<PropertyGroup> | |
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | |
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | |
<ProductVersion>10.0.20506</ProductVersion> | |
<SchemaVersion>2.0</SchemaVersion> | |
<ProjectGuid>{26D24EAD-1AF6-6749-D9C8-C47AEC4E6A98}</ProjectGuid> | |
<OutputType>Library</OutputType> | |
<AssemblyName>Assembly-CSharp</AssemblyName> | |
<FileAlignment>512</FileAlignment> | |
<ProjectTypeGuids>{E097FAD1-6243-4DAD-9C02-E9B9EFC3FFC1};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> | |
<TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier> | |
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | |
<TargetFrameworkProfile>Unity Subset v3.5</TargetFrameworkProfile> | |
<CompilerResponseFile></CompilerResponseFile> | |
<UnityProjectType>Game:1</UnityProjectType> | |
<UnityBuildTarget>StandaloneWindows:5</UnityBuildTarget> | |
<UnityVersion>5.3.3p2</UnityVersion> | |
<RootNamespace></RootNamespace> | |
<LangVersion Condition=" '$(VisualStudioVersion)' != '10.0' ">4</LangVersion> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | |
<DebugType>pdbonly</DebugType> | |
<Optimize>false</Optimize> | |
<OutputPath>Temp\UnityVS_bin\Debug\</OutputPath> | |
<IntermediateOutputPath>Temp\UnityVS_obj\Debug\</IntermediateOutputPath> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
<DefineConstants>DEBUG;TRACE;UNITY_5_3_3;UNITY_5_3;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITERENDERER_FLIPPING;ENABLE_SPRITES;ENABLE_SPRITE_POLYGON;ENABLE_TERRAIN;ENABLE_RAKNET;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_HUB;ENABLE_CLOUD_PROJECT_ID;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_METRICS;ENABLE_EDITOR_METRICS_CACHING;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;ENABLE_ANDROID_ATLAS_ETC1_COMPRESSION;ENABLE_EDITOR_TESTS_RUNNER;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_LOG_MIXED_STACKTRACE;ENABLE_UNITYWEBREQUEST;ENABLE_EVENT_QUEUE;ENABLE_CLUSTERINPUT;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN</DefineConstants> | |
<AllowUnsafeBlocks>false</AllowUnsafeBlocks> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | |
<DebugType>pdbonly</DebugType> | |
<Optimize>false</Optimize> | |
<OutputPath>Temp\UnityVS_bin\Release\</OutputPath> | |
<IntermediateOutputPath>Temp\UnityVS_obj\Release\</IntermediateOutputPath> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
<DefineConstants>TRACE;UNITY_5_3_3;UNITY_5_3;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITERENDERER_FLIPPING;ENABLE_SPRITES;ENABLE_SPRITE_POLYGON;ENABLE_TERRAIN;ENABLE_RAKNET;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_HUB;ENABLE_CLOUD_PROJECT_ID;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_METRICS;ENABLE_EDITOR_METRICS_CACHING;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;ENABLE_ANDROID_ATLAS_ETC1_COMPRESSION;ENABLE_EDITOR_TESTS_RUNNER;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_LOG_MIXED_STACKTRACE;ENABLE_UNITYWEBREQUEST;ENABLE_EVENT_QUEUE;ENABLE_CLUSTERINPUT;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN</DefineConstants> | |
<AllowUnsafeBlocks>false</AllowUnsafeBlocks> | |
</PropertyGroup> | |
<ItemGroup> | |
<Reference Include="mscorlib" /> | |
<Reference Include="System" /> | |
<Reference Include="System.XML" /> | |
<Reference Include="System.Core" /> | |
<Reference Include="Boo.Lang" /> | |
<Reference Include="UnityScript.Lang" /> | |
<Reference Include="System.Runtime.Serialization" /> | |
<Reference Include="System.Xml.Linq" /> | |
<Reference Include="UnityEngine"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.UI"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.UI.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.Networking"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.Networking.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.Networking"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.Networking.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEngine.UI"> | |
<HintPath>Library\UnityAssemblies\UnityEngine.UI.dll</HintPath> | |
</Reference> | |
<Reference Include="UnityEditor"> | |
<HintPath>Library\UnityAssemblies\UnityEditor.dll</HintPath> | |
</Reference> | |
</ItemGroup> | |
<ItemGroup> | |
<Compile Include="Assets\Scripts\BuildAssetBundles.cs" /> | |
</ItemGroup> | |
<Import Project="$(MSBuildExtensionsPath)\SyntaxTree\UnityVS\2015\UnityVS.CSharp.targets" /> | |
</Project> | |
namespace KerbalEngineer.Unity | |
{ | |
using System; | |
using System.Collections; | |
using UnityEngine; | |
[RequireComponent(typeof(CanvasGroup))] | |
public class CanvasGroupFader : MonoBehaviour | |
{ | |
private CanvasGroup m_CanvasGroup; | |
private IEnumerator m_FadeCoroutine; | |
public bool fading | |
{ | |
get | |
{ | |
return m_FadeCoroutine != null; | |
} | |
} | |
/// <summary> | |
/// Fades the canvas group to a specified alpha using the supplied blocking state during fade with optional callback. | |
/// </summary> | |
public void FadeTo(float alpha, float duration, Action callback = null) | |
{ | |
if (m_CanvasGroup == null) | |
{ | |
return; | |
} | |
Fade(m_CanvasGroup.alpha, alpha, duration, callback); | |
} | |
/// <summary> | |
/// Sets the alpha value of the canvas group. | |
/// </summary> | |
public void SetAlpha(float alpha) | |
{ | |
if (m_CanvasGroup == null) | |
{ | |
return; | |
} | |
alpha = Mathf.Clamp01(alpha); | |
m_CanvasGroup.alpha = alpha; | |
} | |
protected virtual void Awake() | |
{ | |
// cache components | |
m_CanvasGroup = GetComponent<CanvasGroup>(); | |
} | |
/// <summary> | |
/// Starts a fade from one alpha value to another with callback. | |
/// </summary> | |
private void Fade(float from, float to, float duration, Action callback) | |
{ | |
if (m_FadeCoroutine != null) | |
{ | |
StopCoroutine(m_FadeCoroutine); | |
} | |
m_FadeCoroutine = FadeCoroutine(from, to, duration, callback); | |
StartCoroutine(m_FadeCoroutine); | |
} | |
/// <summary> | |
/// Coroutine that handles the fading. | |
/// </summary> | |
private IEnumerator FadeCoroutine(float from, float to, float duration, Action callback) | |
{ | |
float progress = 0.0f; | |
while (progress <= 1.0f) | |
{ | |
progress += Time.deltaTime / duration; | |
SetAlpha(Mathf.Lerp(from, to, progress)); | |
yield return null; | |
} | |
print(m_CanvasGroup.alpha); | |
callback?.Invoke(); | |
m_FadeCoroutine = null; | |
} | |
} | |
} |
// | |
// Kerbal Engineer Redux | |
// | |
// Copyright (C) 2016 CYBUTEK | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// GNU General Public License for more details. | |
// You should have received a copy of the GNU General Public License | |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
// | |
namespace KerbalEngineer.Unity.Flight | |
{ | |
using KerbalEngineer.Flight; | |
using UnityEngine; | |
using UnityEngine.EventSystems; | |
public class FlightEngineerMenu : CanvasGroupFader, IPointerEnterHandler, IPointerExitHandler | |
{ | |
[SerializeField] | |
private float m_FastFadeDuration = 0.2f; | |
[SerializeField] | |
private float m_SlowFadeDuration = 1.0f; | |
public void OnPointerEnter(PointerEventData eventData) | |
{ | |
FadeIn(); | |
} | |
public void OnPointerExit(PointerEventData eventData) | |
{ | |
// slow-fade out if the application launcher button is off | |
if (FlightAppLauncher.instance != null && FlightAppLauncher.instance.isOn == false) | |
{ | |
FadeTo(0.0f, m_SlowFadeDuration, Destroy); | |
} | |
} | |
protected override void Awake() | |
{ | |
base.Awake(); | |
// subscribe events | |
FlightAppLauncher.MenuClosed += MenuClosed; | |
FlightAppLauncher.ButtonHover += ButtonHover; | |
} | |
protected virtual void OnDestroy() | |
{ | |
// unsubscribe events | |
FlightAppLauncher.MenuClosed -= MenuClosed; | |
FlightAppLauncher.ButtonHover -= ButtonHover; | |
} | |
protected virtual void OnEnable() | |
{ | |
// set starting alpha to zero and fade in | |
SetAlpha(0.0f); | |
FadeIn(); | |
} | |
/// <summary> | |
/// Called when the application launcher button is hovered over. | |
/// </summary> | |
private void ButtonHover() | |
{ | |
FadeIn(); | |
} | |
/// <summary> | |
/// Destroys the game object. | |
/// </summary> | |
private void Destroy() | |
{ | |
// disable game object first due to an issue within unity 5.2.4f1 that shows a single frame at full opaque alpha just before destruction | |
gameObject.SetActive(false); | |
Destroy(gameObject); | |
} | |
private void FadeIn() | |
{ | |
FadeTo(1.0f, m_FastFadeDuration); | |
} | |
private void MenuClosed() | |
{ | |
FadeTo(0.0f, m_FastFadeDuration, Destroy); | |
} | |
} | |
} |
<?xml version="1.0" encoding="utf-8"?> | |
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | |
<PropertyGroup> | |
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | |
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | |
<ProjectGuid>{5387BB1E-32B1-4BAC-B03F-100570B9554C}</ProjectGuid> | |
<OutputType>Library</OutputType> | |
<AppDesignerFolder>Properties</AppDesignerFolder> | |
<RootNamespace>KerbalEngineer.Unity</RootNamespace> | |
<AssemblyName>KerbalEngineer.Unity</AssemblyName> | |
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | |
<FileAlignment>512</FileAlignment> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | |
<DebugSymbols>true</DebugSymbols> | |
<DebugType>full</DebugType> | |
<Optimize>false</Optimize> | |
<OutputPath>bin\Debug\</OutputPath> | |
<DefineConstants>DEBUG;TRACE</DefineConstants> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | |
<DebugType>none</DebugType> | |
<Optimize>true</Optimize> | |
<OutputPath>..\Output\KerbalEngineer\</OutputPath> | |
<DefineConstants> | |
</DefineConstants> | |
<ErrorReport>prompt</ErrorReport> | |
<WarningLevel>4</WarningLevel> | |
</PropertyGroup> | |
<ItemGroup> | |
<Compile Include="CanvasGroupFader.cs" /> | |
<Compile Include="Flight\FlightEngineerMenu.cs" /> | |
<Compile Include="Properties\AssemblyInfo.cs" /> | |
</ItemGroup> | |
<ItemGroup> | |
<Reference Include="System"> | |
<HintPath>..\..\game\KSP_Data\Managed\System.dll</HintPath> | |
<Private>False</Private> | |
</Reference> | |
<Reference Include="UnityEngine"> | |
<HintPath>..\..\game\KSP_Data\Managed\UnityEngine.dll</HintPath> | |
<Private>False</Private> | |
</Reference> | |
<Reference Include="UnityEngine.UI"> | |
<HintPath>..\..\game\KSP_Data\Managed\UnityEngine.UI.dll</HintPath> | |
<Private>False</Private> | |
</Reference> | |
</ItemGroup> | |
<ItemGroup> | |
<ProjectReference Include="..\KerbalEngineer\KerbalEngineer.csproj"> | |
<Project>{39806613-e0b7-46e0-89a6-a569ec538cbb}</Project> | |
<Name>KerbalEngineer</Name> | |
<Private>False</Private> | |
</ProjectReference> | |
</ItemGroup> | |
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | |
<PropertyGroup> | |
<PostBuildEvent>copy "$(TargetPath)" "$(SolutionDir)Assets\Plugins" /Y</PostBuildEvent> | |
</PropertyGroup> | |
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. | |
Other similar extension points exist, see Microsoft.Common.targets. | |
<Target Name="BeforeBuild"> | |
</Target> | |
<Target Name="AfterBuild"> | |
</Target> | |
--> | |
</Project> |
using System.Reflection; | |
using System.Runtime.InteropServices; | |
[assembly: AssemblyTitle("KerbalEngineer.Unity")] | |
[assembly: AssemblyProduct("KerbalEngineer.Unity")] | |
[assembly: AssemblyCopyright("Copyright © CYBUTEK 2016")] | |
[assembly: ComVisible(false)] | |
[assembly: Guid("5387bb1e-32b1-4bac-b03f-100570b9554c")] | |
[assembly: AssemblyVersion("1.0.0.0")] | |
[assembly: AssemblyFileVersion("1.0.0.0")] |
| |
Microsoft Visual Studio Solution File, Format Version 12.00 | Microsoft Visual Studio Solution File, Format Version 12.00 |
# Visual Studio 2013 | # Visual Studio 2015 |
VisualStudioVersion = 12.0.30110.0 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KerbalEngineer.CSharp.Editor", "KerbalEngineer.CSharp.Editor.csproj", "{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}" |
MinimumVisualStudioVersion = 10.0.40219.1 | EndProject |
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KerbalEngineer", "KerbalEngineer\KerbalEngineer.csproj", "{39806613-E0B7-46E0-89A6-A569EC538CBB}" | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KerbalEngineer", "KerbalEngineer\KerbalEngineer.csproj", "{39806613-E0B7-46E0-89A6-A569EC538CBB}" |
EndProject | |
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KerbalEngineer.Unity", "KerbalEngineer.Unity\KerbalEngineer.Unity.csproj", "{5387BB1E-32B1-4BAC-B03F-100570B9554C}" | |
EndProject | EndProject |
Global | Global |
GlobalSection(SolutionConfigurationPlatforms) = preSolution | GlobalSection(SolutionConfigurationPlatforms) = preSolution |
Debug|Any CPU = Debug|Any CPU | Debug|Any CPU = Debug|Any CPU |
Release|Any CPU = Release|Any CPU | Release|Any CPU = Release|Any CPU |
EndGlobalSection | EndGlobalSection |
GlobalSection(ProjectConfigurationPlatforms) = postSolution | GlobalSection(ProjectConfigurationPlatforms) = postSolution |
{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | |
{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}.Debug|Any CPU.Build.0 = Debug|Any CPU | |
{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}.Release|Any CPU.ActiveCfg = Release|Any CPU | |
{D7B7C6CE-6B5A-CE40-5B7C-9D0E6583E469}.Release|Any CPU.Build.0 = Release|Any CPU | |
{39806613-E0B7-46E0-89A6-A569EC538CBB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | {39806613-E0B7-46E0-89A6-A569EC538CBB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU |
{39806613-E0B7-46E0-89A6-A569EC538CBB}.Debug|Any CPU.Build.0 = Debug|Any CPU | {39806613-E0B7-46E0-89A6-A569EC538CBB}.Debug|Any CPU.Build.0 = Debug|Any CPU |
{39806613-E0B7-46E0-89A6-A569EC538CBB}.Release|Any CPU.ActiveCfg = Release|Any CPU | {39806613-E0B7-46E0-89A6-A569EC538CBB}.Release|Any CPU.ActiveCfg = Release|Any CPU |
{39806613-E0B7-46E0-89A6-A569EC538CBB}.Release|Any CPU.Build.0 = Release|Any CPU | {39806613-E0B7-46E0-89A6-A569EC538CBB}.Release|Any CPU.Build.0 = Release|Any CPU |
{5387BB1E-32B1-4BAC-B03F-100570B9554C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | |
{5387BB1E-32B1-4BAC-B03F-100570B9554C}.Debug|Any CPU.Build.0 = Debug|Any CPU | |
{5387BB1E-32B1-4BAC-B03F-100570B9554C}.Release|Any CPU.ActiveCfg = Release|Any CPU | |
{5387BB1E-32B1-4BAC-B03F-100570B9554C}.Release|Any CPU.Build.0 = Release|Any CPU | |
EndGlobalSection | EndGlobalSection |
GlobalSection(SolutionProperties) = preSolution | GlobalSection(SolutionProperties) = preSolution |
HideSolutionNode = FALSE | HideSolutionNode = FALSE |
EndGlobalSection | EndGlobalSection |
EndGlobal | EndGlobal |
// | |
// Kerbal Engineer Redux | |
// | |
// Copyright (C) 2016 CYBUTEK | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// GNU General Public License for more details. | |
// You should have received a copy of the GNU General Public License | |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
// | |
namespace KerbalEngineer | |
{ | |
using KSP.UI; | |
using KSP.UI.Screens; | |
using UnityEngine; | |
public class AppLauncherButton : MonoBehaviour | |
{ | |
private static Texture m_IconTexture; | |
private ApplicationLauncherButton m_Button; | |
/// <summary> | |
/// Gets or sets the toggle button state. | |
/// </summary> | |
public bool isOn | |
{ | |
get | |
{ | |
return m_Button != null && | |
m_Button.toggleButton.Button.interactable && | |
m_Button.toggleButton.CurrentState == UIRadioButton.State.True; | |
} | |
set | |
{ | |
if (m_Button == null) | |
{ | |
return; | |
} | |
if (value) | |
{ | |
SetOn(); | |
} | |
else | |
{ | |
SetOff(); | |
} | |
} | |
} | |
/// <summary> | |
/// Disables the button if not already disabled. | |
/// </summary> | |
public void Disable() | |
{ | |
if (m_Button != null && m_Button.toggleButton.Button.interactable) | |
{ | |
m_Button.Disable(); | |
} | |
} | |
/// <summary> | |
/// Enables the button if not already enabled. | |
/// </summary> | |
public void Enable() | |
{ | |
if (m_Button != null && m_Button.toggleButton.Button.interactable == false) | |
{ | |
m_Button.Enable(); | |
} | |
} | |
/// <summary> | |
/// Gets the anchor position for pop-up content. | |
/// </summary> | |
public Vector3 GetAnchor() | |
{ | |
if (m_Button == null) | |
{ | |
return Vector3.zero; | |
} | |
Vector3 anchor = m_Button.GetAnchor(); | |
anchor.x -= 3.0f; | |
return anchor; | |
} | |
/// <summary> | |
/// Enables and sets the button to off. | |
/// </summary> | |
public void SetOff() | |
{ | |
Enable(); | |
if (m_Button != null && m_Button.toggleButton.CurrentState != UIRadioButton.State.False) | |
{ | |
m_Button.SetTrue(); | |
} | |
} | |
/// <summary> | |
/// Enables and sets the button to on. | |
/// </summary> | |
public void SetOn() | |
{ | |
Enable(); | |
if (m_Button != null && m_Button.toggleButton.CurrentState != UIRadioButton.State.True) | |
{ | |
m_Button.SetTrue(); | |
} | |
} | |
protected virtual void Awake() | |
{ | |
// cache icon texture | |
if (m_IconTexture == null && AssetBundleLoader.images != null) | |
{ | |
m_IconTexture = AssetBundleLoader.images.LoadAsset<Texture2D>("app-launcher-icon"); | |
} | |
// subscribe event listeners | |
GameEvents.onGUIApplicationLauncherReady.Add(OnGUIApplicationLauncherReady); | |
GameEvents.onGUIApplicationLauncherUnreadifying.Add(OnGUIApplicationLauncherUnreadifying); | |
} | |
protected virtual void OnDestroy() | |
{ | |
// unsubscribe event listeners | |
GameEvents.onGUIApplicationLauncherReady.Remove(OnGUIApplicationLauncherReady); | |
GameEvents.onGUIApplicationLauncherUnreadifying.Remove(OnGUIApplicationLauncherUnreadifying); | |
} | |
/// <summary> | |
/// Called on button being disabled. | |
/// </summary> | |
protected virtual void OnDisable() { } | |
/// <summary> | |
/// Called on button being enabled. | |
/// </summary> | |
protected virtual void OnEnable() { } | |
/// <summary> | |
/// Called on button being toggled off. | |
/// </summary> | |
protected virtual void OnFalse() { } | |
/// <summary> | |
/// Called on mouse hovering. | |
/// </summary> | |
protected virtual void OnHover() { } | |
/// <summary> | |
/// Called on mouse exiting hover. | |
/// </summary> | |
protected virtual void OnHoverOut() { } | |
/// <summary> | |
/// Called on button being ready. | |
/// </summary> | |
protected virtual void OnReady() { } | |
/// <summary> | |
/// Called after the application launcher is ready and the button created. | |
/// </summary> | |
protected virtual void OnTrue() { } | |
/// <summary> | |
/// Called after the application launcher is unreadified and the button removed. | |
/// </summary> | |
protected virtual void OnUnreadifying() { } | |
private void OnGUIApplicationLauncherReady() | |
{ | |
// create button | |
if (ApplicationLauncher.Instance != null) | |
{ | |
m_Button = ApplicationLauncher.Instance.AddModApplication(OnTrue, OnFalse, OnHover, OnHoverOut, OnEnable, OnDisable, ApplicationLauncher.AppScenes.ALWAYS, m_IconTexture); | |
} | |
OnReady(); | |
} | |
private void OnGUIApplicationLauncherUnreadifying(GameScenes scene) | |
{ | |
// remove button | |
if (ApplicationLauncher.Instance != null && m_Button != null) | |
{ | |
ApplicationLauncher.Instance.RemoveModApplication(m_Button); | |
} | |
OnUnreadifying(); | |
} | |
} | |
} |
namespace KerbalEngineer | |
{ | |
using UnityEngine; | |
[KSPAddon(KSPAddon.Startup.Instantly, false)] | |
public class AssetBundleLoader : MonoBehaviour | |
{ | |
private static AssetBundle m_Images; | |
private static AssetBundle m_Prefabs; | |
/// <summary> | |
/// Gets the loaded images asset bundle. | |
/// </summary> | |
public static AssetBundle images | |
{ | |
get | |
{ | |
return m_Images; | |
} | |
} | |
/// <summary> | |
/// Gets the loaded prefabs asset bundle. | |
/// </summary> | |
public static AssetBundle prefabs | |
{ | |
get | |
{ | |
return m_Prefabs; | |
} | |
} | |
protected virtual void Awake() | |
{ | |
string bundlePath = EngineerGlobals.AssemblyPath; | |
m_Images = AssetBundle.CreateFromFile(bundlePath + "/images"); | |
m_Prefabs = AssetBundle.CreateFromFile(bundlePath + "/prefabs"); | |
} | |
} | |
} |
// | // |
// Kerbal Engineer Redux | // Copyright (C) 2015 CYBUTEK |
// | |
// Copyright (C) 2014 CYBUTEK | |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
namespace KerbalEngineer.Editor | namespace KerbalEngineer.Editor |
{ | { |
#region Using Directives | |
using System; | using System; |
using Extensions; | using Extensions; |
using Flight; | using Flight; |
using Helpers; | using Helpers; |
using KeyBinding; | |
using Settings; | using Settings; |
using UIControls; | using UIControls; |
using UnityEngine; | using UnityEngine; |
using VesselSimulator; | using VesselSimulator; |
#endregion | |
[KSPAddon(KSPAddon.Startup.EditorAny, false)] | [KSPAddon(KSPAddon.Startup.EditorAny, false)] |
public class BuildAdvanced : MonoBehaviour | public class BuildAdvanced : MonoBehaviour |
{ | { |
#region Fields | public static float Altitude; |
public static float Altitude = 0.0f; | |
private static Rect compactModeRect = new Rect(0.0f, 5.0f, 0.0f, 20.0f); | |
private static Stage stage; | |
private static int stagesCount; | |
private static int stagesLength; | |
private static string title; | |
private GUIStyle areaSettingStyle; | private GUIStyle areaSettingStyle; |
private GUIStyle areaStyle; | private GUIStyle areaStyle; |
private float atmosphericMach; | private float atmosphericMach; |
private GUIStyle bodiesButtonActiveStyle; | private GUIStyle bodiesButtonActiveStyle; |
private GUIStyle bodiesButtonStyle; | private GUIStyle bodiesButtonStyle; |
private DropDown bodiesList; | private DropDown bodiesList; |
private Rect bodiesListPosition; | private Rect bodiesListPosition; |
private GUIStyle buttonStyle; | private GUIStyle buttonStyle; |
private int compactCheck; | private int compactCheck; |
private bool compactCollapseRight; | private bool compactCollapseRight; |
private bool compactMode; | private bool compactMode; |
private float compactRight; | private float compactRight; |
private bool hasChanged; | private bool hasChanged; |
private GUIStyle infoStyle; | private GUIStyle infoStyle; |
private bool isEditorLocked; | private bool isEditorLocked; |
private float maxMach; | private float maxMach; |
private int numberOfStages; | private int numberOfStages; |
private Rect position = new Rect(265.0f, 45.0f, 0, 0); | private Rect position = new Rect(265.0f, 45.0f, 0, 0); |
private GUIStyle settingAtmoStyle; | private GUIStyle settingAtmoStyle; |
private GUIStyle settingStyle; | private GUIStyle settingStyle; |
private bool showAllStages; | private bool showAllStages; |
private bool showAtmosphericDetails; | private bool showAtmosphericDetails; |
private bool showSettings; | private bool showSettings; |
private Stage[] stages; | private Stage[] stages; |
private GUIStyle titleStyle; | private GUIStyle titleStyle; |
private bool visible = true; | private bool visible = true; |
private GUIStyle windowStyle; | private GUIStyle windowStyle; |
#endregion | |
#region Properties | |
/// <summary> | /// <summary> |
/// Gets the current instance if started or returns null. | /// Gets the current instance if started or returns null. |
/// </summary> | /// </summary> |
public static BuildAdvanced Instance { get; private set; } | public static BuildAdvanced Instance { get; private set; } |
/// <summary> | /// <summary> |
/// Gets and sets whether to show in compact mode. | /// Gets and sets whether to show in compact mode. |
/// </summary> | /// </summary> |
public bool CompactMode | public bool CompactMode |
{ | { |
get | get |
{ | { |
return compactMode; | return compactMode; |
} | } |
set | set |
{ | { |
compactMode = value; | compactMode = value; |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets and sets whether to show all stages. | /// Gets and sets whether to show all stages. |
/// </summary> | /// </summary> |
public bool ShowAllStages | public bool ShowAllStages |
{ | { |
get | get |
{ | { |
return showAllStages; | return showAllStages; |
} | } |
set | set |
{ | { |
showAllStages = value; | showAllStages = value; |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets and sets whether to use atmospheric details. | /// Gets and sets whether to use atmospheric details. |
/// </summary> | /// </summary> |
public bool ShowAtmosphericDetails | public bool ShowAtmosphericDetails |
{ | { |
get | get |
{ | { |
return showAtmosphericDetails; | return showAtmosphericDetails; |
} | } |
set | set |
{ | { |
showAtmosphericDetails = value; | showAtmosphericDetails = value; |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets and sets whether to show the settings display. | /// Gets and sets whether to show the settings display. |
/// </summary> | /// </summary> |
public bool ShowSettings | public bool ShowSettings |
{ | { |
get | get |
{ | { |
return showSettings; | return showSettings; |
} | } |
set | set |
{ | { |
showSettings = value; | showSettings = value; |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets and sets whether the display is enabled. | /// Gets and sets whether the display is enabled. |
/// </summary> | /// </summary> |
public bool Visible | public bool Visible |
{ | { |
get | get |
{ | { |
return visible; | return visible; |
} | } |
set | set |
{ | { |
visible = value; | visible = value; |
} | } |
} | } |
#endregion | |
#region Methods | |
private static Rect compactModeRect = new Rect(0.0f, 5.0f, 0.0f, 20.0f); | |
private static Stage stage; | |
private static int stagesCount; | |
private static int stagesLength; | |
private static string title; | |
protected void Awake() | protected void Awake() |
{ | { |
try | try |
{ | { |
Instance = this; | Instance = this; |
bodiesList = gameObject.AddComponent<DropDown>(); | bodiesList = gameObject.AddComponent<DropDown>(); |
bodiesList.DrawCallback = DrawBodiesList; | bodiesList.DrawCallback = DrawBodiesList; |
Load(); | Load(); |
SimManager.UpdateModSettings(); | SimManager.UpdateModSettings(); |
SimManager.OnReady -= GetStageInfo; | SimManager.OnReady -= GetStageInfo; |
SimManager.OnReady += GetStageInfo; | SimManager.OnReady += GetStageInfo; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.Awake()"); | Logger.Exception(ex, "BuildAdvanced.Awake()"); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Saves the settings when this object is destroyed. | /// Saves the settings when this object is destroyed. |
/// </summary> | /// </summary> |
protected void OnDestroy() | protected void OnDestroy() |
{ | { |
Logger.Log("BuildAdvanced->OnDestroy"); | |
try | try |
{ | { |
SettingHandler handler = new SettingHandler(); | SettingHandler handler = new SettingHandler(); |
handler.Set("visible", visible); | handler.Set("visible", visible); |
handler.Set("windowPositionX", position.x); | handler.Set("windowPositionX", position.x); |
handler.Set("windowPositionY", position.y); | handler.Set("windowPositionY", position.y); |
handler.Set("compactMode", compactMode); | handler.Set("compactMode", compactMode); |
handler.Set("compactCollapseRight", compactCollapseRight); | handler.Set("compactCollapseRight", compactCollapseRight); |
handler.Set("showAllStages", showAllStages); | handler.Set("showAllStages", showAllStages); |
handler.Set("showAtmosphericDetails", showAtmosphericDetails); | handler.Set("showAtmosphericDetails", showAtmosphericDetails); |
handler.Set("showSettings", showSettings); | handler.Set("showSettings", showSettings); |
handler.Set("selectedBodyName", CelestialBodies.SelectedBody.Name); | handler.Set("selectedBodyName", CelestialBodies.SelectedBody.Name); |
handler.Save("BuildAdvanced.xml"); | handler.Save("BuildAdvanced.xml"); |
GuiDisplaySize.OnSizeChanged -= OnSizeChanged; | GuiDisplaySize.OnSizeChanged -= OnSizeChanged; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.OnDestroy()"); | Logger.Exception(ex, "BuildAdvanced.OnDestroy()"); |
} | } |
EditorLock(false); | |
} | } |
protected void OnGUI() | protected void OnGUI() |
{ | { |
try | try |
{ | { |
if (!visible || EditorLogic.fetch == null || EditorLogic.fetch.ship.parts.Count == 0 || EditorLogic.fetch.editorScreen != EditorScreen.Parts) | if (!visible || EditorLogic.fetch == null || EditorLogic.fetch.ship.parts.Count == 0 || EditorLogic.fetch.editorScreen != EditorScreen.Parts) |
{ | { |
return; | return; |
} | } |
if (stages == null) | if (stages == null) |
{ | { |
return; | return; |
} | } |
// Change the window title based on whether in compact mode or not. | // Change the window title based on whether in compact mode or not. |
title = !compactMode ? "KERBAL ENGINEER REDUX " + EngineerGlobals.ASSEMBLY_VERSION : "K.E.R. " + EngineerGlobals.ASSEMBLY_VERSION; | title = !compactMode ? "KERBAL ENGINEER REDUX " + EngineerGlobals.ASSEMBLY_VERSION : "K.E.R. " + EngineerGlobals.ASSEMBLY_VERSION; |
// Reset the window size when the staging or something else has changed. | // Reset the window size when the staging or something else has changed. |
stagesLength = stages.Length; | stagesLength = stages.Length; |
if (showAllStages) | if (showAllStages) |
{ | { |
stagesCount = stagesLength; | stagesCount = stagesLength; |
} | } |
if (showAllStages == false) | if (showAllStages == false) |
{ | { |
stagesCount = 0; | stagesCount = 0; |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
if (stages[i].deltaV > 0.0f) | if (stages[i].deltaV > 0.0f) |
{ | { |
stagesCount = stagesCount + 1; | stagesCount = stagesCount + 1; |
} | } |
} | } |
} | } |
if (hasChanged || stagesCount != numberOfStages) | if (hasChanged || stagesCount != numberOfStages) |
{ | { |
hasChanged = false; | hasChanged = false; |
numberOfStages = stagesCount; | numberOfStages = stagesCount; |
position.width = 0; | position.width = 0; |
position.height = 0; | position.height = 0; |
} | } |
GUI.skin = null; | GUI.skin = null; |
position = GUILayout.Window(GetInstanceID(), position, Window, title, windowStyle).ClampToScreen(); | position = GUILayout.Window(GetInstanceID(), position, Window, title, windowStyle).ClampToScreen(); |
if (compactCheck > 0 && compactCollapseRight) | if (compactCheck > 0 && compactCollapseRight) |
{ | { |
position.x = compactRight - position.width; | position.x = compactRight - position.width; |
compactCheck--; | compactCheck--; |
} | } |
else if (compactCheck > 0) | else if (compactCheck > 0) |
{ | { |
compactCheck = 0; | compactCheck = 0; |
} | } |
// Check editor lock to manage click-through. | // Check editor lock to manage click-through. |
CheckEditorLock(); | CheckEditorLock(); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.OnGUI()"); | Logger.Exception(ex, "BuildAdvanced.OnGUI()"); |
} | } |
} | } |
protected void Start() | protected void Start() |
{ | { |
try | try |
{ | { |
InitialiseStyles(); | InitialiseStyles(); |
GuiDisplaySize.OnSizeChanged += OnSizeChanged; | GuiDisplaySize.OnSizeChanged += OnSizeChanged; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.Start()"); | Logger.Exception(ex, "BuildAdvanced.Start()"); |
} | } |
} | } |
protected void Update() | protected void Update() |
{ | { |
try | try |
{ | { |
if (Input.GetKeyDown(KeyBinder.EditorShowHide)) | if (Input.GetKeyDown(KeyBinder.EditorShowHide)) |
{ | { |
visible = !visible; | visible = !visible; |
if (!visible) | if (!visible) |
{ | { |
EditorLock(false); | EditorLock(false); |
} | } |
} | } |
if (!visible || EditorLogic.fetch == null || EditorLogic.fetch.ship.parts.Count == 0) | if (!visible || EditorLogic.fetch == null || EditorLogic.fetch.ship.parts.Count == 0) |
{ | { |
bodiesList.enabled = false; | bodiesList.enabled = false; |
return; | return; |
} | } |
// Configure the simulation parameters based on the selected reference body. | // Configure the simulation parameters based on the selected reference body. |
SimManager.Gravity = CelestialBodies.SelectedBody.Gravity; | SimManager.Gravity = CelestialBodies.SelectedBody.Gravity; |
if (showAtmosphericDetails) | if (showAtmosphericDetails) |
{ | { |
SimManager.Atmosphere = CelestialBodies.SelectedBody.GetAtmospheres(Altitude); | SimManager.Atmosphere = CelestialBodies.SelectedBody.GetAtmospheres(Altitude); |
} | } |
else | else |
{ | { |
SimManager.Atmosphere = 0; | SimManager.Atmosphere = 0; |
} | } |
SimManager.Mach = atmosphericMach; | SimManager.Mach = atmosphericMach; |
SimManager.RequestSimulation(); | SimManager.RequestSimulation(); |
SimManager.TryStartSimulation(); | SimManager.TryStartSimulation(); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.Update()"); | Logger.Exception(ex, "BuildAdvanced.Update()"); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Checks whether the editor should be locked to stop click-through. | /// Checks whether the editor should be locked to stop click-through. |
/// </summary> | /// </summary> |
private void CheckEditorLock() | private void CheckEditorLock() |
{ | { |
if ((position.MouseIsOver() || bodiesList.Position.MouseIsOver()) && !isEditorLocked) | if ((position.MouseIsOver() || bodiesList.Position.MouseIsOver()) && !isEditorLocked) |
{ | { |
EditorLock(true); | EditorLock(true); |
} | } |
else if (!position.MouseIsOver() && !bodiesList.Position.MouseIsOver() && isEditorLocked) | else if (!position.MouseIsOver() && !bodiesList.Position.MouseIsOver() && isEditorLocked) |
{ | { |
EditorLock(false); | EditorLock(false); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Draws the atmospheric settings. | /// Draws the atmospheric settings. |
/// </summary> | /// </summary> |
private void DrawAtmosphericDetails() | private void DrawAtmosphericDetails() |
{ | { |
try | try |
{ | { |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.BeginVertical(); | GUILayout.BeginVertical(); |
GUILayout.Label("Altitude: " + (Altitude * 0.001f).ToString("F1") + "km", settingAtmoStyle, GUILayout.Width(125.0f * GuiDisplaySize.Offset)); | GUILayout.Label("Altitude: " + (Altitude * 0.001f).ToString("F1") + "km", settingAtmoStyle, GUILayout.Width(125.0f * GuiDisplaySize.Offset)); |
GUI.skin = HighLogic.Skin; | GUI.skin = HighLogic.Skin; |
Altitude = GUILayout.HorizontalSlider(Altitude, 0.0f, (float)(CelestialBodies.SelectedBody.CelestialBody.atmosphereDepth)); | Altitude = GUILayout.HorizontalSlider(Altitude, 0.0f, (float)(CelestialBodies.SelectedBody.CelestialBody.atmosphereDepth)); |
GUI.skin = null; | GUI.skin = null; |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
GUILayout.Space(5.0f); | GUILayout.Space(5.0f); |
GUILayout.BeginVertical(); | GUILayout.BeginVertical(); |
GUILayout.Label("Mach: " + atmosphericMach.ToString("F2"), settingAtmoStyle, GUILayout.Width(125.0f * GuiDisplaySize.Offset)); | GUILayout.Label("Mach: " + atmosphericMach.ToString("F2"), settingAtmoStyle, GUILayout.Width(125.0f * GuiDisplaySize.Offset)); |
GUI.skin = HighLogic.Skin; | GUI.skin = HighLogic.Skin; |
atmosphericMach = GUILayout.HorizontalSlider(Mathf.Clamp(atmosphericMach, 0.0f, maxMach), 0.0f, maxMach); | atmosphericMach = GUILayout.HorizontalSlider(Mathf.Clamp(atmosphericMach, 0.0f, maxMach), 0.0f, maxMach); |
GUI.skin = null; | GUI.skin = null; |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.DrawAtmosphericDetails()"); | Logger.Exception(ex, "BuildAdvanced.DrawAtmosphericDetails()"); |
} | } |
} | } |
private void DrawBodiesList() | private void DrawBodiesList() |
{ | { |
if (CelestialBodies.SystemBody == CelestialBodies.SelectedBody) | if (CelestialBodies.SystemBody == CelestialBodies.SelectedBody) |
{ | { |
DrawBody(CelestialBodies.SystemBody); | DrawBody(CelestialBodies.SystemBody); |
} | } |
else | else |
{ | { |
foreach (CelestialBodies.BodyInfo body in CelestialBodies.SystemBody.Children) | foreach (CelestialBodies.BodyInfo body in CelestialBodies.SystemBody.Children) |
{ | { |
DrawBody(body); | DrawBody(body); |
} | } |
} | } |
} | } |
private void DrawBody(CelestialBodies.BodyInfo bodyInfo, int depth = 0) | private void DrawBody(CelestialBodies.BodyInfo bodyInfo, int depth = 0) |
{ | { |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Space(20.0f * depth); | GUILayout.Space(20.0f * depth); |
if (GUILayout.Button(bodyInfo.Children.Count > 0 ? bodyInfo.Name + " [" + bodyInfo.Children.Count + "]" : bodyInfo.Name, bodyInfo.Selected && bodyInfo.SelectedDepth == 0 ? bodiesButtonActiveStyle : bodiesButtonStyle)) | if (GUILayout.Button(bodyInfo.Children.Count > 0 ? bodyInfo.Name + " [" + bodyInfo.Children.Count + "]" : bodyInfo.Name, bodyInfo.Selected && bodyInfo.SelectedDepth == 0 ? bodiesButtonActiveStyle : bodiesButtonStyle)) |
{ | { |
CelestialBodies.SetSelectedBody(bodyInfo.Name); | CelestialBodies.SetSelectedBody(bodyInfo.Name); |
Altitude = 0.0f; | Altitude = 0.0f; |
bodiesList.Resize = true; | bodiesList.Resize = true; |
} | } |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
if (bodyInfo.Selected) | if (bodyInfo.Selected) |
{ | { |
for (int i = 0; i < bodyInfo.Children.Count; ++i) | for (int i = 0; i < bodyInfo.Children.Count; ++i) |
{ | { |
DrawBody(bodyInfo.Children[i], depth + 1); | DrawBody(bodyInfo.Children[i], depth + 1); |
} | } |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Draws the burn time column. | /// Draws the burn time column. |
/// </summary> | /// </summary> |
private void DrawBurnTime() | private void DrawBurnTime() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("BURN", titleStyle); | GUILayout.Label("BURN", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(TimeFormatter.ConvertToString(stage.time), infoStyle); | GUILayout.Label(TimeFormatter.ConvertToString(stage.time), infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the cost column. | /// Draws the cost column. |
/// </summary> | /// </summary> |
private void DrawCost() | private void DrawCost() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(110.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(110.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("COST", titleStyle); | GUILayout.Label("COST", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(Units.Cost(stage.cost, stage.totalCost), infoStyle); | GUILayout.Label(Units.Cost(stage.cost, stage.totalCost), infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the deltaV column. | /// Draws the deltaV column. |
/// </summary> | /// </summary> |
private void DrawDeltaV() | private void DrawDeltaV() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("DELTA-V", titleStyle); | GUILayout.Label("DELTA-V", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.deltaV.ToString("N0") + " / " + stage.inverseTotalDeltaV.ToString("N0") + "m/s", infoStyle); | GUILayout.Label(stage.deltaV.ToString("N0") + " / " + stage.inverseTotalDeltaV.ToString("N0") + "m/s", infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the specific impluse column. | /// Draws the specific impluse column. |
/// </summary> | /// </summary> |
private void DrawIsp() | private void DrawIsp() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("ISP", titleStyle); | GUILayout.Label("ISP", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.isp.ToString("F1") + "s", infoStyle); | GUILayout.Label(stage.isp.ToString("F1") + "s", infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the mass column. | /// Draws the mass column. |
/// </summary> | /// </summary> |
private void DrawMass() | private void DrawMass() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(110.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(110.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("MASS", titleStyle); | GUILayout.Label("MASS", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(Units.ToMass(stage.mass, stage.totalMass), infoStyle); | GUILayout.Label(Units.ToMass(stage.mass, stage.totalMass), infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the part count column. | /// Draws the part count column. |
/// </summary> | /// </summary> |
private void DrawPartCount() | private void DrawPartCount() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(50.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(50.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("PARTS", titleStyle); | GUILayout.Label("PARTS", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.partCount + " / " + stage.totalPartCount, infoStyle); | GUILayout.Label(stage.partCount + " / " + stage.totalPartCount, infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the settings panel. | /// Draws the settings panel. |
/// </summary> | /// </summary> |
private void DrawSettings() | private void DrawSettings() |
{ | { |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Compact mode collapses to the:", settingStyle); | GUILayout.Label("Compact mode collapses to the:", settingStyle); |
compactCollapseRight = !GUILayout.Toggle(!compactCollapseRight, "LEFT", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | compactCollapseRight = !GUILayout.Toggle(!compactCollapseRight, "LEFT", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
compactCollapseRight = GUILayout.Toggle(compactCollapseRight, "RIGHT", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | compactCollapseRight = GUILayout.Toggle(compactCollapseRight, "RIGHT", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Simulate using vectored thrust values:", settingStyle); | GUILayout.Label("Simulate using vectored thrust values:", settingStyle); |
SimManager.vectoredThrust = GUILayout.Toggle(SimManager.vectoredThrust, "ENABLED", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | SimManager.vectoredThrust = GUILayout.Toggle(SimManager.vectoredThrust, "ENABLED", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Verbose Simulation Log:", settingStyle); | GUILayout.Label("Verbose Simulation Log:", settingStyle); |
SimManager.logOutput = GUILayout.Toggle(SimManager.logOutput, "ENABLED", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | SimManager.logOutput = GUILayout.Toggle(SimManager.logOutput, "ENABLED", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Build Engineer Overlay:", settingStyle); | GUILayout.Label("Build Engineer Overlay:", settingStyle); |
BuildOverlay.Visible = GUILayout.Toggle(BuildOverlay.Visible, "VISIBLE", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | BuildOverlay.Visible = GUILayout.Toggle(BuildOverlay.Visible, "VISIBLE", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
BuildOverlayPartInfo.NamesOnly = GUILayout.Toggle(BuildOverlayPartInfo.NamesOnly, "NAMES ONLY", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | BuildOverlayPartInfo.NamesOnly = GUILayout.Toggle(BuildOverlayPartInfo.NamesOnly, "NAMES ONLY", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
BuildOverlayPartInfo.ClickToOpen = GUILayout.Toggle(BuildOverlayPartInfo.ClickToOpen, "CLICK TO OPEN", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | BuildOverlayPartInfo.ClickToOpen = GUILayout.Toggle(BuildOverlayPartInfo.ClickToOpen, "CLICK TO OPEN", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Flight Engineer activation mode:", settingStyle); | GUILayout.Label("Flight Engineer activation mode:", settingStyle); |
FlightEngineerCore.IsCareerMode = GUILayout.Toggle(FlightEngineerCore.IsCareerMode, "CAREER", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | FlightEngineerCore.IsCareerMode = GUILayout.Toggle(FlightEngineerCore.IsCareerMode, "CAREER", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
FlightEngineerCore.IsCareerMode = !GUILayout.Toggle(!FlightEngineerCore.IsCareerMode, "PARTLESS", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | FlightEngineerCore.IsCareerMode = !GUILayout.Toggle(!FlightEngineerCore.IsCareerMode, "PARTLESS", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Flight Engineer Career Limitations:", settingStyle); | GUILayout.Label("Flight Engineer Career Limitations:", settingStyle); |
FlightEngineerCore.IsKerbalLimited = GUILayout.Toggle(FlightEngineerCore.IsKerbalLimited, "KERBAL", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | FlightEngineerCore.IsKerbalLimited = GUILayout.Toggle(FlightEngineerCore.IsKerbalLimited, "KERBAL", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
FlightEngineerCore.IsTrackingStationLimited = GUILayout.Toggle(FlightEngineerCore.IsTrackingStationLimited, "TRACKING", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | FlightEngineerCore.IsTrackingStationLimited = GUILayout.Toggle(FlightEngineerCore.IsTrackingStationLimited, "TRACKING", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
GUILayout.Label("Key Bindings:", settingStyle); | |
if (GUILayout.Button("EDIT KEY BINDINGS", buttonStyle, GUILayout.Width(200.0f * GuiDisplaySize.Offset))) | |
{ | |
KeyBinder.Show(); | |
} | |
GUILayout.EndHorizontal(); | |
GUILayout.BeginHorizontal(); | |
GUILayout.Label("GUI Size: " + GuiDisplaySize.Increment, settingStyle); | GUILayout.Label("GUI Size: " + GuiDisplaySize.Increment, settingStyle); |
if (GUILayout.Button("<", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset))) | if (GUILayout.Button("<", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset))) |
{ | { |
GuiDisplaySize.Increment--; | GuiDisplaySize.Increment--; |
} | } |
if (GUILayout.Button(">", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset))) | if (GUILayout.Button(">", buttonStyle, GUILayout.Width(100.0f * GuiDisplaySize.Offset))) |
{ | { |
GuiDisplaySize.Increment++; | GuiDisplaySize.Increment++; |
} | } |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
GUILayout.Label("Minimum delay between simulations: " + SimManager.minSimTime.TotalMilliseconds + "ms", settingStyle); | GUILayout.Label("Minimum delay between simulations: " + SimManager.minSimTime.TotalMilliseconds + "ms", settingStyle); |
GUI.skin = HighLogic.Skin; | GUI.skin = HighLogic.Skin; |
SimManager.minSimTime = TimeSpan.FromMilliseconds(GUILayout.HorizontalSlider((float)SimManager.minSimTime.TotalMilliseconds, 0, 2000.0f)); | SimManager.minSimTime = TimeSpan.FromMilliseconds(GUILayout.HorizontalSlider((float)SimManager.minSimTime.TotalMilliseconds, 0, 2000.0f)); |
GUI.skin = null; | GUI.skin = null; |
} | } |
/// <summary> | /// <summary> |
/// Draws the stage number column. | /// Draws the stage number column. |
/// </summary> | /// </summary> |
private void DrawStageNumbers() | private void DrawStageNumbers() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(30.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(30.0f * GuiDisplaySize.Offset)); |
GUILayout.Label(string.Empty, titleStyle); | GUILayout.Label(string.Empty, titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label("S" + stage.number, titleStyle); | GUILayout.Label("S" + stage.number, titleStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the thrust column. | /// Draws the thrust column. |
/// </summary> | /// </summary> |
private void DrawThrust() | private void DrawThrust() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("THRUST", titleStyle); | GUILayout.Label("THRUST", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.thrust.ToForce(), infoStyle); | GUILayout.Label(stage.thrust.ToForce(), infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Draws the torque column. | /// Draws the torque column. |
/// </summary> | /// </summary> |
private void DrawTorque() | private void DrawTorque() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("TORQUE", titleStyle); | GUILayout.Label("TORQUE", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.maxThrustTorque.ToTorque(), infoStyle); | GUILayout.Label(stage.maxThrustTorque.ToTorque(), infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
/// <summary> | /// <summary> |
/// Drwas the thrust to weight ratio column. | /// Drwas the thrust to weight ratio column. |
/// </summary> | /// </summary> |
private void DrawTwr() | private void DrawTwr() |
{ | { |
GUILayout.BeginVertical(GUILayout.Width(100.0f * GuiDisplaySize.Offset)); | GUILayout.BeginVertical(GUILayout.Width(100.0f * GuiDisplaySize.Offset)); |
GUILayout.Label("TWR (MAX)", titleStyle); | GUILayout.Label("TWR (MAX)", titleStyle); |
for (int i = 0; i < stagesLength; ++i) | for (int i = 0; i < stagesLength; ++i) |
{ | { |
stage = stages[i]; | stage = stages[i]; |
if (showAllStages || stage.deltaV > 0.0) | if (showAllStages || stage.deltaV > 0.0) |
{ | { |
GUILayout.Label(stage.thrustToWeight.ToString("F2") + " (" + stage.maxThrustToWeight.ToString("F2") + ")", infoStyle); | GUILayout.Label(stage.thrustToWeight.ToString("F2") + " (" + stage.maxThrustToWeight.ToString("F2") + ")", infoStyle); |
} | } |
} | } |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
private void EditorLock(bool state) | private void EditorLock(bool state) |
{ | { |
if (state) | if (state) |
{ | { |
InputLockManager.SetControlLock(ControlTypes.All, "KER_BuildAdvanced"); | InputLockManager.SetControlLock(ControlTypes.All, "KER_BuildAdvanced"); |
BuildOverlayPartInfo.Hidden = true; | BuildOverlayPartInfo.Hidden = true; |
isEditorLocked = true; | isEditorLocked = true; |
} | } |
else | else |
{ | { |
InputLockManager.SetControlLock(ControlTypes.None, "KER_BuildAdvanced"); | InputLockManager.SetControlLock(ControlTypes.None, "KER_BuildAdvanced"); |
BuildOverlayPartInfo.Hidden = false; | BuildOverlayPartInfo.Hidden = false; |
isEditorLocked = false; | isEditorLocked = false; |
} | } |
} | } |
private void GetStageInfo() | private void GetStageInfo() |
{ | { |
stages = SimManager.Stages; | stages = SimManager.Stages; |
if (stages != null && stages.Length > 0) | if (stages != null && stages.Length > 0) |
{ | { |
maxMach = stages[stages.Length - 1].maxMach; | maxMach = stages[stages.Length - 1].maxMach; |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Initialises all the styles that are required. | /// Initialises all the styles that are required. |
/// </summary> | /// </summary> |
private void InitialiseStyles() | private void InitialiseStyles() |
{ | { |
windowStyle = new GUIStyle(HighLogic.Skin.window) | windowStyle = new GUIStyle(HighLogic.Skin.window) |
{ | { |
alignment = TextAnchor.UpperLeft | alignment = TextAnchor.UpperLeft |
}; | }; |
areaStyle = new GUIStyle(HighLogic.Skin.box) | areaStyle = new GUIStyle(HighLogic.Skin.box) |
{ | { |
padding = new RectOffset(0, 0, 9, 0) | padding = new RectOffset(0, 0, 9, 0) |
}; | }; |
areaSettingStyle = new GUIStyle(HighLogic.Skin.box) | areaSettingStyle = new GUIStyle(HighLogic.Skin.box) |
{ | { |
padding = new RectOffset(10, 10, 10, 10) | padding = new RectOffset(10, 10, 10, 10) |
}; | }; |
buttonStyle = new GUIStyle(HighLogic.Skin.button) | buttonStyle = new GUIStyle(HighLogic.Skin.button) |
{ | { |
normal = | normal = |
{ | { |
textColor = Color.white | textColor = Color.white |
}, | }, |
fontSize = (int)(11 * GuiDisplaySize.Offset), | fontSize = (int)(11 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
alignment = TextAnchor.MiddleCenter | alignment = TextAnchor.MiddleCenter |
}; | }; |
titleStyle = new GUIStyle(HighLogic.Skin.label) | titleStyle = new GUIStyle(HighLogic.Skin.label) |
{ | { |
normal = | normal = |
{ | { |
textColor = Color.white | textColor = Color.white |
}, | }, |
fontSize = (int)(11 * GuiDisplaySize.Offset), | fontSize = (int)(11 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
alignment = TextAnchor.MiddleCenter, | alignment = TextAnchor.MiddleCenter, |
stretchWidth = true, | stretchWidth = true |
}; | }; |
infoStyle = new GUIStyle(HighLogic.Skin.label) | infoStyle = new GUIStyle(HighLogic.Skin.label) |
{ | { |
fontSize = (int)(11 * GuiDisplaySize.Offset), | fontSize = (int)(11 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
alignment = TextAnchor.MiddleCenter, | alignment = TextAnchor.MiddleCenter, |
stretchWidth = true | stretchWidth = true |
}; | }; |
settingStyle = new GUIStyle(titleStyle) | settingStyle = new GUIStyle(titleStyle) |
{ | { |
alignment = TextAnchor.MiddleLeft, | alignment = TextAnchor.MiddleLeft, |
stretchWidth = true, | stretchWidth = true, |
stretchHeight = true | stretchHeight = true |
}; | }; |
settingAtmoStyle = new GUIStyle(titleStyle) | settingAtmoStyle = new GUIStyle(titleStyle) |
{ | { |
margin = new RectOffset(), | margin = new RectOffset(), |
padding = new RectOffset(), | padding = new RectOffset(), |
alignment = TextAnchor.UpperLeft | alignment = TextAnchor.UpperLeft |
}; | }; |
bodiesButtonStyle = new GUIStyle(HighLogic.Skin.button) | bodiesButtonStyle = new GUIStyle(HighLogic.Skin.button) |
{ | { |
margin = new RectOffset(0, 0, 2, 0), | margin = new RectOffset(0, 0, 2, 0), |
padding = new RectOffset(5, 5, 5, 5), | padding = new RectOffset(5, 5, 5, 5), |
normal = | normal = |
{ | { |
textColor = Color.white | textColor = Color.white |
}, | }, |
active = | active = |
{ | { |
textColor = Color.white | textColor = Color.white |
}, | }, |
fontSize = (int)(11 * GuiDisplaySize.Offset), | fontSize = (int)(11 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
alignment = TextAnchor.MiddleCenter, | alignment = TextAnchor.MiddleCenter, |
fixedHeight = 20.0f | fixedHeight = 20.0f |
}; | }; |
bodiesButtonActiveStyle = new GUIStyle(bodiesButtonStyle) | bodiesButtonActiveStyle = new GUIStyle(bodiesButtonStyle) |
{ | { |
normal = bodiesButtonStyle.onNormal, | normal = bodiesButtonStyle.onNormal, |
hover = bodiesButtonStyle.onHover | hover = bodiesButtonStyle.onHover |
}; | }; |
} | } |
/// <summary> | /// <summary> |
/// Loads the settings when this object is created. | /// Loads the settings when this object is created. |
/// </summary> | /// </summary> |
private void Load() | private void Load() |
{ | { |
try | try |
{ | { |
SettingHandler handler = SettingHandler.Load("BuildAdvanced.xml"); | SettingHandler handler = SettingHandler.Load("BuildAdvanced.xml"); |
handler.Get("visible", ref visible); | handler.Get("visible", ref visible); |
position.x = handler.Get("windowPositionX", position.x); | position.x = handler.Get("windowPositionX", position.x); |
position.y = handler.Get("windowPositionY", position.y); | position.y = handler.Get("windowPositionY", position.y); |
handler.Get("compactMode", ref compactMode); | handler.Get("compactMode", ref compactMode); |
handler.Get("compactCollapseRight", ref compactCollapseRight); | handler.Get("compactCollapseRight", ref compactCollapseRight); |
handler.Get("showAllStages", ref showAllStages); | handler.Get("showAllStages", ref showAllStages); |
handler.Get("showAtmosphericDetails", ref showAtmosphericDetails); | handler.Get("showAtmosphericDetails", ref showAtmosphericDetails); |
handler.Get("showSettings", ref showSettings); | handler.Get("showSettings", ref showSettings); |
CelestialBodies.SetSelectedBody(handler.Get("selectedBodyName", CelestialBodies.SelectedBody.Name)); | CelestialBodies.SetSelectedBody(handler.Get("selectedBodyName", CelestialBodies.SelectedBody.Name)); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.Load()"); | Logger.Exception(ex, "BuildAdvanced.Load()"); |
} | } |
} | } |
private void OnSizeChanged() | private void OnSizeChanged() |
{ | { |
InitialiseStyles(); | InitialiseStyles(); |
hasChanged = true; | hasChanged = true; |
} | } |
/// <summary> | /// <summary> |
/// Draws the OnGUI window. | /// Draws the OnGUI window. |
/// </summary> | /// </summary> |
private void Window(int windowId) | private void Window(int windowId) |
{ | { |
try | try |
{ | { |
compactModeRect = new Rect(position.width - 70.0f * GuiDisplaySize.Offset, 5.0f, 65.0f * GuiDisplaySize.Offset, 20.0f); | compactModeRect = new Rect(position.width - 70.0f * GuiDisplaySize.Offset, 5.0f, 65.0f * GuiDisplaySize.Offset, 20.0f); |
// Draw the compact mode toggle. | // Draw the compact mode toggle. |
if (GUI.Toggle(compactModeRect, compactMode, "COMPACT", buttonStyle) != compactMode) | if (GUI.Toggle(compactModeRect, compactMode, "COMPACT", buttonStyle) != compactMode) |
{ | { |
hasChanged = true; | hasChanged = true; |
compactCheck = 2; | compactCheck = 2; |
compactRight = position.xMax; | compactRight = position.xMax; |
compactMode = !compactMode; | compactMode = !compactMode; |
} | } |
// When not in compact mode draw the 'All Stages' and 'Atmospheric' toggles. | // When not in compact mode draw the 'All Stages' and 'Atmospheric' toggles. |
if (!compactMode) | if (!compactMode) |
{ | { |
if (GUI.Toggle(new Rect(position.width - 143.0f * GuiDisplaySize.Offset, 5.0f, 70.0f * GuiDisplaySize.Offset, 20.0f), showSettings, "SETTINGS", buttonStyle) != showSettings) | if (GUI.Toggle(new Rect(position.width - 143.0f * GuiDisplaySize.Offset, 5.0f, 70.0f * GuiDisplaySize.Offset, 20.0f), showSettings, "SETTINGS", buttonStyle) != showSettings) |
{ | { |
hasChanged = true; | hasChanged = true; |
showSettings = !showSettings; | showSettings = !showSettings; |
} | } |
if (GUI.Toggle(new Rect(position.width - 226.0f * GuiDisplaySize.Offset, 5.0f, 80.0f * GuiDisplaySize.Offset, 20.0f), showAllStages, "ALL STAGES", buttonStyle) != showAllStages) | if (GUI.Toggle(new Rect(position.width - 226.0f * GuiDisplaySize.Offset, 5.0f, 80.0f * GuiDisplaySize.Offset, 20.0f), showAllStages, "ALL STAGES", buttonStyle) != showAllStages) |
{ | { |
hasChanged = true; | hasChanged = true; |
showAllStages = !showAllStages; | showAllStages = !showAllStages; |
} | } |
if (GUI.Toggle(new Rect(position.width - 324.0f * GuiDisplaySize.Offset, 5.0f, 95.0f * GuiDisplaySize.Offset, 20.0f), showAtmosphericDetails, "ATMOSPHERIC", buttonStyle) != showAtmosphericDetails) | if (GUI.Toggle(new Rect(position.width - 324.0f * GuiDisplaySize.Offset, 5.0f, 95.0f * GuiDisplaySize.Offset, 20.0f), showAtmosphericDetails, "ATMOSPHERIC", buttonStyle) != showAtmosphericDetails) |
{ | { |
hasChanged = true; | hasChanged = true; |
showAtmosphericDetails = !showAtmosphericDetails; | showAtmosphericDetails = !showAtmosphericDetails; |
} | } |
bodiesListPosition = new Rect(position.width - 452.0f * GuiDisplaySize.Offset, 5.0f, 125.0f * GuiDisplaySize.Offset, 20.0f); | bodiesListPosition = new Rect(position.width - 452.0f * GuiDisplaySize.Offset, 5.0f, 125.0f * GuiDisplaySize.Offset, 20.0f); |
bodiesList.enabled = GUI.Toggle(bodiesListPosition, bodiesList.enabled, "BODY: " + CelestialBodies.SelectedBody.Name.ToUpper(), buttonStyle); | bodiesList.enabled = GUI.Toggle(bodiesListPosition, bodiesList.enabled, "BODY: " + CelestialBodies.SelectedBody.Name.ToUpper(), buttonStyle); |
bodiesList.SetPosition(bodiesListPosition.Translate(position)); | bodiesList.SetPosition(bodiesListPosition.Translate(position)); |
} | } |
else | else |
{ | { |
if (GUI.Toggle(new Rect(position.width - 133.0f * GuiDisplaySize.Offset, 5.0f, 60.0f * GuiDisplaySize.Offset, 20.0f), showAtmosphericDetails, "ATMO", buttonStyle) != showAtmosphericDetails) | if (GUI.Toggle(new Rect(position.width - 133.0f * GuiDisplaySize.Offset, 5.0f, 60.0f * GuiDisplaySize.Offset, 20.0f), showAtmosphericDetails, "ATMO", buttonStyle) != showAtmosphericDetails) |
{ | { |
hasChanged = true; | hasChanged = true; |
showAtmosphericDetails = !showAtmosphericDetails; | showAtmosphericDetails = !showAtmosphericDetails; |
} | } |
} | } |
// Draw the main informational display box. | // Draw the main informational display box. |
if (!compactMode) | if (!compactMode) |
{ | { |
GUILayout.BeginHorizontal(areaStyle); | GUILayout.BeginHorizontal(areaStyle); |
DrawStageNumbers(); | DrawStageNumbers(); |
DrawPartCount(); | DrawPartCount(); |
DrawCost(); | DrawCost(); |
DrawMass(); | DrawMass(); |
DrawIsp(); | DrawIsp(); |
DrawThrust(); | DrawThrust(); |
DrawTorque(); | DrawTorque(); |
DrawTwr(); | DrawTwr(); |
DrawDeltaV(); | DrawDeltaV(); |
DrawBurnTime(); | DrawBurnTime(); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
if (showAtmosphericDetails && !compactMode) | if (showAtmosphericDetails && !compactMode) |
{ | { |
GUILayout.BeginVertical(areaSettingStyle); | GUILayout.BeginVertical(areaSettingStyle); |
DrawAtmosphericDetails(); | DrawAtmosphericDetails(); |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
if (showSettings) | if (showSettings) |
{ | { |
GUILayout.BeginVertical(areaSettingStyle); | GUILayout.BeginVertical(areaSettingStyle); |
DrawSettings(); | DrawSettings(); |
GUILayout.EndVertical(); | GUILayout.EndVertical(); |
} | } |
} | } |
else // Draw only a few details when in compact mode. | else // Draw only a few details when in compact mode. |
{ | { |
GUILayout.BeginHorizontal(areaStyle); | GUILayout.BeginHorizontal(areaStyle); |
DrawStageNumbers(); | DrawStageNumbers(); |
DrawTwr(); | DrawTwr(); |
DrawDeltaV(); | DrawDeltaV(); |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
} | } |
GUI.DragWindow(); | GUI.DragWindow(); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "BuildAdvanced.Window()"); | Logger.Exception(ex, "BuildAdvanced.Window()"); |
} | } |
} | } |
#endregion | |
} | } |
} | } |
// | |
// Kerbal Engineer Redux | |
// | |
// Copyright (C) 2016 CYBUTEK | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// GNU General Public License for more details. | |
// You should have received a copy of the GNU General Public License | |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
// | |
namespace KerbalEngineer.Editor | |
{ | |
[KSPAddon(KSPAddon.Startup.EditorAny, false)] | |
public class BuildAppLauncher : AppLauncherButton | |
{ | |
protected override void OnFalse() | |
{ | |
if (BuildAdvanced.Instance != null) | |
{ | |
BuildAdvanced.Instance.Visible = false; | |
} | |
} | |
protected override void OnTrue() | |
{ | |
if (BuildAdvanced.Instance != null) | |
{ | |
BuildAdvanced.Instance.Visible = true; | |
} | |
} | |
protected virtual void Update() | |
{ | |
if (BuildAdvanced.Instance == null) | |
{ | |
return; | |
} | |
// check if vessel is currently under construction with the presence of a root part | |
if (EditorLogic.RootPart != null) | |
{ | |
// set button state based on existing visibility | |
isOn = BuildAdvanced.Instance.Visible; | |
} | |
else | |
{ | |
Disable(); | |
} | |
} | |
} | |
} |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
namespace KerbalEngineer.Editor | namespace KerbalEngineer.Editor |
{ | { |
using System; | using System; |
using System.Collections.Generic; | using System.Collections.Generic; |
using Extensions; | using Extensions; |
using Helpers; | using Helpers; |
using UnityEngine; | using UnityEngine; |
public class BuildOverlayPartInfo : MonoBehaviour | public class BuildOverlayPartInfo : MonoBehaviour |
{ | { |
private static bool clickToOpen = true; | private static bool clickToOpen = true; |
private static ModuleGenerator.GeneratorResource generatorResource; | private static ModuleResource generatorResource; |
private static ModuleAlternator moduleAlternator; | private static ModuleAlternator moduleAlternator; |
private static ModuleDataTransmitter moduleDataTransmitter; | private static ModuleDataTransmitter moduleDataTransmitter; |
private static ModuleDeployableSolarPanel moduleDeployableSolarPanel; | private static ModuleDeployableSolarPanel moduleDeployableSolarPanel; |
private static ModuleGenerator moduleGenerator; | private static ModuleGenerator moduleGenerator; |
private static ModuleGimbal moduleGimbal; | private static ModuleGimbal moduleGimbal; |
private static ModuleParachute moduleParachute; | private static ModuleParachute moduleParachute; |
private static ModuleRCS moduleRcs; | private static ModuleRCS moduleRcs; |
private static ModuleReactionWheel moduleReactionWheel; | private static ModuleReactionWheel moduleReactionWheel; |
private static ModuleResource moduleResource; | private static ModuleResource moduleResource; |
private static ModuleScienceExperiment moduleScienceExperiment; | private static ModuleScienceExperiment moduleScienceExperiment; |
private static bool namesOnly; | private static bool namesOnly; |
private static Part part; | private static Part part; |
private static PartInfoItem partInfoItem; | private static PartInfoItem partInfoItem; |
private static PartResource partResource; | private static PartResource partResource; |
private static Propellant propellant; | private static Propellant propellant; |
private static PartExtensions.ProtoModuleDecoupler protoModuleDecoupler; | private static PartExtensions.ProtoModuleDecoupler protoModuleDecoupler; |
private static PartExtensions.ProtoModuleEngine protoModuleEngine; | private static PartExtensions.ProtoModuleEngine protoModuleEngine; |
private static bool visible = true; | private static bool visible = true; |
private readonly List<PartInfoItem> infoItems = new List<PartInfoItem>(); | private readonly List<PartInfoItem> infoItems = new List<PartInfoItem>(); |
private Rect position; | private Rect position; |
private Part selectedPart; | private Part selectedPart; |
private bool showInfo; | private bool showInfo; |
private bool skipFrame; | private bool skipFrame; |
public static bool ClickToOpen | public static bool ClickToOpen |
{ | { |
get | get |
{ | { |
return clickToOpen; | return clickToOpen; |
} | } |
set | set |
{ | { |
clickToOpen = value; | clickToOpen = value; |
} | } |
} | } |
public static bool Hidden { get; set; } | public static bool Hidden { get; set; } |
public static bool NamesOnly | public static bool NamesOnly |
{ | { |
get | get |
{ | { |
return namesOnly; | return namesOnly; |
} | } |
set | set |
{ | { |
namesOnly = value; | namesOnly = value; |
} | } |
} | } |
public static bool Visible | public static bool Visible |
{ | { |
get | get |
{ | { |
return visible; | return visible; |
} | } |
set | set |
{ | { |
visible = value; | visible = value; |
} | } |
} | } |
protected void OnGUI() | protected void OnGUI() |
{ | { |
try | try |
{ | { |
if (!Visible || Hidden || selectedPart == null) | if (!Visible || Hidden || selectedPart == null) |
{ | { |
return; | return; |
} | } |
position = GUILayout.Window(GetInstanceID(), position, Window, String.Empty, BuildOverlay.WindowStyle); | position = GUILayout.Window(GetInstanceID(), position, Window, String.Empty, BuildOverlay.WindowStyle); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
protected void Update() | protected void Update() |
{ | { |
try | try |
{ | { |
if (!Visible || Hidden || EditorLogic.RootPart == null || EditorLogic.fetch.editorScreen != EditorScreen.Parts) | if (!Visible || Hidden || EditorLogic.RootPart == null || EditorLogic.fetch.editorScreen != EditorScreen.Parts) |
{ | { |
return; | return; |
} | } |
position.x = Mathf.Clamp(Input.mousePosition.x + 16.0f, 0.0f, Screen.width - position.width); | position.x = Mathf.Clamp(Input.mousePosition.x + 16.0f, 0.0f, Screen.width - position.width); |
position.y = Mathf.Clamp(Screen.height - Input.mousePosition.y, 0.0f, Screen.height - position.height); | position.y = Mathf.Clamp(Screen.height - Input.mousePosition.y, 0.0f, Screen.height - position.height); |
if (position.x < Input.mousePosition.x + 20.0f) | if (position.x < Input.mousePosition.x + 20.0f) |
{ | { |
position.y = Mathf.Clamp(position.y + 20.0f, 0.0f, Screen.height - position.height); | position.y = Mathf.Clamp(position.y + 20.0f, 0.0f, Screen.height - position.height); |
} | } |
if (position.x < Input.mousePosition.x + 16.0f && position.y < Screen.height - Input.mousePosition.y) | if (position.x < Input.mousePosition.x + 16.0f && position.y < Screen.height - Input.mousePosition.y) |
{ | { |
position.x = Input.mousePosition.x - 3 - position.width; | position.x = Input.mousePosition.x - 3 - position.width; |
} | } |
part = EditorLogic.fetch.ship.parts.Find(p => p.stackIcon.highlightIcon) ?? EditorLogic.SelectedPart; | part = EditorLogic.fetch.ship.parts.Find(p => p.stackIcon.Highlighted) ?? EditorLogic.SelectedPart; |
if (part != null) | if (part != null) |
{ | { |
if (!part.Equals(selectedPart)) | if (!part.Equals(selectedPart)) |
{ | { |
selectedPart = part; | selectedPart = part; |
ResetInfo(); | ResetInfo(); |
} | } |
if (NamesOnly || skipFrame) | if (NamesOnly || skipFrame) |
{ | { |
skipFrame = false; | skipFrame = false; |
return; | return; |
} | } |
if (!showInfo && Input.GetMouseButtonDown(2)) | if (!showInfo && Input.GetMouseButtonDown(2)) |
{ | { |
showInfo = true; | showInfo = true; |
} | } |
else if (ClickToOpen && showInfo && Input.GetMouseButtonDown(2)) | else if (ClickToOpen && showInfo && Input.GetMouseButtonDown(2)) |
{ | { |
ResetInfo(); | ResetInfo(); |
} | } |
if (showInfo) | if (showInfo) |
{ | { |
PartInfoItem.Release(infoItems); | PartInfoItem.Release(infoItems); |
infoItems.Clear(); | infoItems.Clear(); |
SetCostInfo(); | SetCostInfo(); |
SetMassItems(); | SetMassItems(); |
SetResourceItems(); | SetResourceItems(); |
SetEngineInfo(); | SetEngineInfo(); |
SetAlternatorInfo(); | SetAlternatorInfo(); |
SetGimbalInfo(); | SetGimbalInfo(); |
SetRcsInfo(); | SetRcsInfo(); |
SetParachuteInfo(); | SetParachuteInfo(); |
SetSasInfo(); | SetSasInfo(); |
SetReactionWheelInfo(); | SetReactionWheelInfo(); |
SetSolarPanelInfo(); | SetSolarPanelInfo(); |
SetGeneratorInfo(); | SetGeneratorInfo(); |
SetDecouplerInfo(); | SetDecouplerInfo(); |
SetTransmitterInfo(); | SetTransmitterInfo(); |
SetScienceExperimentInfo(); | SetScienceExperimentInfo(); |
SetScienceContainerInfo(); | SetScienceContainerInfo(); |
SetSingleActivationInfo(); | SetSingleActivationInfo(); |
} | } |
} | } |
else | else |
{ | { |
selectedPart = null; | selectedPart = null; |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void ResetInfo() | private void ResetInfo() |
{ | { |
showInfo = !clickToOpen; | showInfo = !clickToOpen; |
skipFrame = true; | skipFrame = true; |
position.width = namesOnly || clickToOpen ? 0.0f : 200.0f; | position.width = namesOnly || clickToOpen ? 0.0f : 200.0f; |
position.height = 0.0f; | position.height = 0.0f; |
} | } |
private void SetAlternatorInfo() | private void SetAlternatorInfo() |
{ | { |
moduleAlternator = selectedPart.GetModule<ModuleAlternator>(); | moduleAlternator = selectedPart.GetModule<ModuleAlternator>(); |
if (moduleAlternator != null) | if (moduleAlternator != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Alternator")); | infoItems.Add(PartInfoItem.Create("Alternator")); |
for (int i = 0; i < moduleAlternator.outputResources.Count; ++i) | for (int i = 0; i < moduleAlternator.outputResources.Count; ++i) |
{ | { |
moduleResource = moduleAlternator.outputResources[i]; | moduleResource = moduleAlternator.outputResources[i]; |
infoItems.Add(PartInfoItem.Create("\t" + moduleResource.name, moduleResource.rate.ToRate())); | infoItems.Add(PartInfoItem.Create("\t" + moduleResource.name, moduleResource.rate.ToRate())); |
} | } |
} | } |
} | } |
private void SetCostInfo() | private void SetCostInfo() |
{ | { |
infoItems.Add(PartInfoItem.Create("Cost", Units.ConcatF(selectedPart.GetCostDry(), selectedPart.GetCostWet()))); | infoItems.Add(PartInfoItem.Create("Cost", Units.ConcatF(selectedPart.GetCostDry(), selectedPart.GetCostWet()))); |
} | } |
private void SetDecouplerInfo() | private void SetDecouplerInfo() |
{ | { |
protoModuleDecoupler = selectedPart.GetProtoModuleDecoupler(); | protoModuleDecoupler = selectedPart.GetProtoModuleDecoupler(); |
if (protoModuleDecoupler != null) | if (protoModuleDecoupler != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Ejection Force", protoModuleDecoupler.EjectionForce.ToForce())); | infoItems.Add(PartInfoItem.Create("Ejection Force", protoModuleDecoupler.EjectionForce.ToForce())); |
if (protoModuleDecoupler.IsOmniDecoupler) | if (protoModuleDecoupler.IsOmniDecoupler) |
{ | { |
infoItems.Add(PartInfoItem.Create("Omni-directional")); | infoItems.Add(PartInfoItem.Create("Omni-directional")); |
} | } |
} | } |
} | } |
private void SetEngineInfo() | private void SetEngineInfo() |
{ | { |
protoModuleEngine = selectedPart.GetProtoModuleEngine(); | protoModuleEngine = selectedPart.GetProtoModuleEngine(); |
if (protoModuleEngine != null) | if (protoModuleEngine != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Thrust", Units.ToForce(protoModuleEngine.MinimumThrust, protoModuleEngine.MaximumThrust))); | infoItems.Add(PartInfoItem.Create("Thrust", Units.ToForce(protoModuleEngine.MinimumThrust, protoModuleEngine.MaximumThrust))); |
infoItems.Add(PartInfoItem.Create("Isp", Units.ConcatF(protoModuleEngine.GetSpecificImpulse(1.0f), protoModuleEngine.GetSpecificImpulse(0.0f)) + "s")); | infoItems.Add(PartInfoItem.Create("Isp", Units.ConcatF(protoModuleEngine.GetSpecificImpulse(1.0f), protoModuleEngine.GetSpecificImpulse(0.0f)) + "s")); |
if (protoModuleEngine.Propellants.Count > 0) | if (protoModuleEngine.Propellants.Count > 0) |
{ | { |
infoItems.Add(PartInfoItem.Create("Propellants")); | infoItems.Add(PartInfoItem.Create("Propellants")); |
float totalRatio = 0.0f; | float totalRatio = 0.0f; |
for (int i = 0; i < protoModuleEngine.Propellants.Count; ++i) | for (int i = 0; i < protoModuleEngine.Propellants.Count; ++i) |
{ | { |
totalRatio = totalRatio + protoModuleEngine.Propellants[i].ratio; | totalRatio = totalRatio + protoModuleEngine.Propellants[i].ratio; |
} | } |
for (int i = 0; i < protoModuleEngine.Propellants.Count; ++i) | for (int i = 0; i < protoModuleEngine.Propellants.Count; ++i) |
{ | { |
propellant = protoModuleEngine.Propellants[i]; | propellant = protoModuleEngine.Propellants[i]; |
infoItems.Add(PartInfoItem.Create("\t" + propellant.name, (propellant.ratio / totalRatio).ToPercent())); | infoItems.Add(PartInfoItem.Create("\t" + propellant.name, (propellant.ratio / totalRatio).ToPercent())); |
} | } |
} | } |
} | } |
} | } |
private void SetGeneratorInfo() | private void SetGeneratorInfo() |
{ | { |
moduleGenerator = selectedPart.GetModule<ModuleGenerator>(); | moduleGenerator = selectedPart.GetModule<ModuleGenerator>(); |
if (moduleGenerator != null) | if (moduleGenerator != null) |
{ | { |
if (moduleGenerator.inputList.Count > 0) | if (moduleGenerator.inputList.Count > 0) |
{ | { |
infoItems.Add(PartInfoItem.Create("Generator Input")); | infoItems.Add(PartInfoItem.Create("Generator Input")); |
for (int i = 0; i < moduleGenerator.inputList.Count; ++i) | for (int i = 0; i < moduleGenerator.inputList.Count; ++i) |
{ | { |
generatorResource = moduleGenerator.inputList[i]; | generatorResource = moduleGenerator.inputList[i]; |
infoItems.Add(PartInfoItem.Create("\t" + generatorResource.name, generatorResource.rate.ToRate())); | infoItems.Add(PartInfoItem.Create("\t" + generatorResource.name, generatorResource.rate.ToRate())); |
} | } |
} | } |
if (moduleGenerator.outputList.Count > 0) | if (moduleGenerator.outputList.Count > 0) |
{ | { |
infoItems.Add(PartInfoItem.Create("Generator Output")); | infoItems.Add(PartInfoItem.Create("Generator Output")); |
for (int i = 0; i < moduleGenerator.outputList.Count; ++i) | for (int i = 0; i < moduleGenerator.outputList.Count; ++i) |
{ | { |
generatorResource = moduleGenerator.outputList[i]; | generatorResource = moduleGenerator.outputList[i]; |
infoItems.Add(PartInfoItem.Create("\t" + generatorResource.name, generatorResource.rate.ToRate())); | infoItems.Add(PartInfoItem.Create("\t" + generatorResource.name, generatorResource.rate.ToRate())); |
} | } |
} | } |
if (moduleGenerator.isAlwaysActive) | if (moduleGenerator.isAlwaysActive) |
{ | { |
infoItems.Add(PartInfoItem.Create("Generator is Always Active")); | infoItems.Add(PartInfoItem.Create("Generator is Always Active")); |
} | } |
} | } |
} | } |
private void SetGimbalInfo() | private void SetGimbalInfo() |
{ | { |
moduleGimbal = selectedPart.GetModule<ModuleGimbal>(); | moduleGimbal = selectedPart.GetModule<ModuleGimbal>(); |
if (moduleGimbal != null) | if (moduleGimbal != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Thrust Vectoring", moduleGimbal.gimbalRange.ToString("F2"))); | infoItems.Add(PartInfoItem.Create("Thrust Vectoring", moduleGimbal.gimbalRange.ToString("F2"))); |
} | } |
} | } |
private void SetMassItems() | private void SetMassItems() |
{ | { |
if (selectedPart.physicalSignificance == Part.PhysicalSignificance.FULL) | if (selectedPart.physicalSignificance == Part.PhysicalSignificance.FULL) |
{ | { |
infoItems.Add(PartInfoItem.Create("Mass", Units.ToMass(selectedPart.GetDryMass(), selectedPart.GetWetMass()))); | infoItems.Add(PartInfoItem.Create("Mass", Units.ToMass(selectedPart.GetDryMass(), selectedPart.GetWetMass()))); |
} | } |
} | } |
private void SetParachuteInfo() | private void SetParachuteInfo() |
{ | { |
moduleParachute = selectedPart.GetModule<ModuleParachute>(); | moduleParachute = selectedPart.GetModule<ModuleParachute>(); |
if (moduleParachute != null) | if (moduleParachute != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Deployed Drag", Units.ConcatF(moduleParachute.semiDeployedDrag, moduleParachute.fullyDeployedDrag))); | infoItems.Add(PartInfoItem.Create("Deployed Drag", Units.ConcatF(moduleParachute.semiDeployedDrag, moduleParachute.fullyDeployedDrag))); |
infoItems.Add(PartInfoItem.Create("Deployment Altitude", moduleParachute.deployAltitude.ToDistance())); | infoItems.Add(PartInfoItem.Create("Deployment Altitude", moduleParachute.deployAltitude.ToDistance())); |
infoItems.Add(PartInfoItem.Create("Deployment Pressure", moduleParachute.minAirPressureToOpen.ToString("F2"))); | infoItems.Add(PartInfoItem.Create("Deployment Pressure", moduleParachute.minAirPressureToOpen.ToString("F2"))); |
} | } |
} | } |
private void SetRcsInfo() | private void SetRcsInfo() |
{ | { |
moduleRcs = selectedPart.GetModule<ModuleRCS>(); | moduleRcs = selectedPart.GetModule<ModuleRCS>(); |
if (moduleRcs != null) | if (moduleRcs != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Thruster Power", moduleRcs.thrusterPower.ToForce())); | infoItems.Add(PartInfoItem.Create("Thruster Power", moduleRcs.thrusterPower.ToForce())); |
infoItems.Add(PartInfoItem.Create("Specific Impulse", Units.ConcatF(moduleRcs.atmosphereCurve.Evaluate(1.0f), moduleRcs.atmosphereCurve.Evaluate(0.0f)) + "s")); | infoItems.Add(PartInfoItem.Create("Specific Impulse", Units.ConcatF(moduleRcs.atmosphereCurve.Evaluate(1.0f), moduleRcs.atmosphereCurve.Evaluate(0.0f)) + "s")); |
} | } |
} | } |
private void SetReactionWheelInfo() | private void SetReactionWheelInfo() |
{ | { |
moduleReactionWheel = selectedPart.GetModule<ModuleReactionWheel>(); | moduleReactionWheel = selectedPart.GetModule<ModuleReactionWheel>(); |
if (moduleReactionWheel != null) | if (moduleReactionWheel != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Reaction Wheel Torque")); | infoItems.Add(PartInfoItem.Create("Reaction Wheel Torque")); |
infoItems.Add(PartInfoItem.Create("\tPitch", moduleReactionWheel.PitchTorque.ToTorque())); | infoItems.Add(PartInfoItem.Create("\tPitch", moduleReactionWheel.PitchTorque.ToTorque())); |
infoItems.Add(PartInfoItem.Create("\tRoll", moduleReactionWheel.RollTorque.ToTorque())); | infoItems.Add(PartInfoItem.Create("\tRoll", moduleReactionWheel.RollTorque.ToTorque())); |
infoItems.Add(PartInfoItem.Create("\tYaw", moduleReactionWheel.YawTorque.ToTorque())); | infoItems.Add(PartInfoItem.Create("\tYaw", moduleReactionWheel.YawTorque.ToTorque())); |
for (int i = 0; i < moduleReactionWheel.inputResources.Count; ++i) | for (int i = 0; i < moduleReactionWheel.inputResources.Count; ++i) |
{ | { |
moduleResource = moduleReactionWheel.inputResources[i]; | moduleResource = moduleReactionWheel.inputResources[i]; |
infoItems.Add(PartInfoItem.Create("\t" + moduleResource.name, moduleResource.rate.ToRate())); | infoItems.Add(PartInfoItem.Create("\t" + moduleResource.name, moduleResource.rate.ToRate())); |
} | } |
} | } |
} | } |
private void SetResourceItems() | private void SetResourceItems() |
{ | { |
bool visibleResources = false; | bool visibleResources = false; |
for (int i = 0; i < selectedPart.Resources.list.Count; ++i) | for (int i = 0; i < selectedPart.Resources.list.Count; ++i) |
{ | { |
if (selectedPart.Resources.list[i].hideFlow == false) | if (selectedPart.Resources.list[i].hideFlow == false) |
{ | { |
visibleResources = true; | visibleResources = true; |
break; | break; |
} | } |
} | } |
if (visibleResources) | if (visibleResources) |
{ | { |
infoItems.Add(PartInfoItem.Create("Resources")); | infoItems.Add(PartInfoItem.Create("Resources")); |
for (int i = 0; i < selectedPart.Resources.list.Count; ++i) | for (int i = 0; i < selectedPart.Resources.list.Count; ++i) |
{ | { |
partResource = selectedPart.Resources.list[i]; | partResource = selectedPart.Resources.list[i]; |
if (partResource.hideFlow == false) | if (partResource.hideFlow == false) |
{ | { |
infoItems.Add(partResource.GetDensity() > 0 | infoItems.Add(partResource.GetDensity() > 0 |
? PartInfoItem.Create("\t" + partResource.info.name, "(" + partResource.GetMass().ToMass() + ") " + partResource.amount.ToString("F1")) | ? PartInfoItem.Create("\t" + partResource.info.name, "(" + partResource.GetMass().ToMass() + ") " + partResource.amount.ToString("F1")) |
: PartInfoItem.Create("\t" + partResource.info.name, partResource.amount.ToString("F1"))); | : PartInfoItem.Create("\t" + partResource.info.name, partResource.amount.ToString("F1"))); |
} | } |
} | } |
} | } |
} | } |
private void SetSasInfo() | private void SetSasInfo() |
{ | { |
if (selectedPart.HasModule<ModuleSAS>()) | if (selectedPart.HasModule<ModuleSAS>()) |
{ | { |
infoItems.Add(PartInfoItem.Create("SAS Equiped")); | infoItems.Add(PartInfoItem.Create("SAS Equiped")); |
} | } |
} | } |
private void SetScienceContainerInfo() | private void SetScienceContainerInfo() |
{ | { |
if (selectedPart.HasModule<ModuleScienceContainer>()) | if (selectedPart.HasModule<ModuleScienceContainer>()) |
{ | { |
infoItems.Add(PartInfoItem.Create("Science Container")); | infoItems.Add(PartInfoItem.Create("Science Container")); |
} | } |
} | } |
private void SetScienceExperimentInfo() | private void SetScienceExperimentInfo() |
{ | { |
moduleScienceExperiment = selectedPart.GetModule<ModuleScienceExperiment>(); | moduleScienceExperiment = selectedPart.GetModule<ModuleScienceExperiment>(); |
if (moduleScienceExperiment != null) | if (moduleScienceExperiment != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Science Experiment", moduleScienceExperiment.experimentActionName)); | infoItems.Add(PartInfoItem.Create("Science Experiment", moduleScienceExperiment.experimentActionName)); |
infoItems.Add(PartInfoItem.Create("\tTransmit Efficiency", moduleScienceExperiment.xmitDataScalar.ToPercent())); | infoItems.Add(PartInfoItem.Create("\tTransmit Efficiency", moduleScienceExperiment.xmitDataScalar.ToPercent())); |
if (moduleScienceExperiment.rerunnable == false) | if (moduleScienceExperiment.rerunnable == false) |
{ | { |
infoItems.Add(PartInfoItem.Create("\tSingle Usage")); | infoItems.Add(PartInfoItem.Create("\tSingle Usage")); |
} | } |
} | } |
} | } |
private void SetSingleActivationInfo() | private void SetSingleActivationInfo() |
{ | { |
if (selectedPart.HasModule<ModuleAnimateGeneric>(m => m.isOneShot)) | if (selectedPart.HasModule<ModuleAnimateGeneric>(m => m.isOneShot)) |
{ | { |
infoItems.Add(PartInfoItem.Create("Single Activation")); | infoItems.Add(PartInfoItem.Create("Single Activation")); |
} | } |
} | } |
private void SetSolarPanelInfo() | private void SetSolarPanelInfo() |
{ | { |
moduleDeployableSolarPanel = selectedPart.GetModule<ModuleDeployableSolarPanel>(); | moduleDeployableSolarPanel = selectedPart.GetModule<ModuleDeployableSolarPanel>(); |
if (moduleDeployableSolarPanel != null) | if (moduleDeployableSolarPanel != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Charge Rate", moduleDeployableSolarPanel.chargeRate.ToRate())); | infoItems.Add(PartInfoItem.Create("Charge Rate", moduleDeployableSolarPanel.chargeRate.ToRate())); |
if (moduleDeployableSolarPanel.isBreakable) | if (moduleDeployableSolarPanel.isBreakable) |
{ | { |
infoItems.Add(PartInfoItem.Create("Breakable")); | infoItems.Add(PartInfoItem.Create("Breakable")); |
} | } |
if (moduleDeployableSolarPanel.sunTracking) | if (moduleDeployableSolarPanel.sunTracking) |
{ | { |
infoItems.Add(PartInfoItem.Create("Sun Tracking")); | infoItems.Add(PartInfoItem.Create("Sun Tracking")); |
} | } |
} | } |
} | } |
private void SetTransmitterInfo() | private void SetTransmitterInfo() |
{ | { |
moduleDataTransmitter = selectedPart.GetModule<ModuleDataTransmitter>(); | moduleDataTransmitter = selectedPart.GetModule<ModuleDataTransmitter>(); |
if (moduleDataTransmitter != null) | if (moduleDataTransmitter != null) |
{ | { |
infoItems.Add(PartInfoItem.Create("Packet Size", moduleDataTransmitter.packetSize.ToString("F2") + " Mits")); | infoItems.Add(PartInfoItem.Create("Packet Size", moduleDataTransmitter.packetSize.ToString("F2") + " Mits")); |
infoItems.Add(PartInfoItem.Create("Bandwidth", (moduleDataTransmitter.packetInterval * moduleDataTransmitter.packetSize).ToString("F2") + "Mits/sec")); | infoItems.Add(PartInfoItem.Create("Bandwidth", (moduleDataTransmitter.packetInterval * moduleDataTransmitter.packetSize).ToString("F2") + "Mits/sec")); |
infoItems.Add(PartInfoItem.Create(moduleDataTransmitter.requiredResource, moduleDataTransmitter.packetResourceCost.ToString("F2") + "/Packet")); | infoItems.Add(PartInfoItem.Create(moduleDataTransmitter.requiredResource, moduleDataTransmitter.packetResourceCost.ToString("F2") + "/Packet")); |
} | } |
} | } |
private void Window(int windowId) | private void Window(int windowId) |
{ | { |
try | try |
{ | { |
GUILayout.Label(selectedPart.partInfo.title, BuildOverlay.TitleStyle); | GUILayout.Label(selectedPart.partInfo.title, BuildOverlay.TitleStyle); |
if (showInfo) | if (showInfo) |
{ | { |
for (int i = 0; i < infoItems.Count; ++i) | for (int i = 0; i < infoItems.Count; ++i) |
{ | { |
partInfoItem = infoItems[i]; | partInfoItem = infoItems[i]; |
GUILayout.Space(2.0f); | GUILayout.Space(2.0f); |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
if (partInfoItem.Value != null) | if (partInfoItem.Value != null) |
{ | { |
GUILayout.Label(partInfoItem.Name + ":", BuildOverlay.NameStyle); | GUILayout.Label(partInfoItem.Name + ":", BuildOverlay.NameStyle); |
GUILayout.Space(25.0f); | GUILayout.Space(25.0f); |
GUILayout.Label(partInfoItem.Value, BuildOverlay.ValueStyle); | GUILayout.Label(partInfoItem.Value, BuildOverlay.ValueStyle); |
} | } |
else | else |
{ | { |
GUILayout.Label(partInfoItem.Name, BuildOverlay.NameStyle); | GUILayout.Label(partInfoItem.Name, BuildOverlay.NameStyle); |
} | } |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
} | } |
} | } |
else if (clickToOpen && namesOnly == false) | else if (clickToOpen && namesOnly == false) |
{ | { |
GUILayout.Space(2.0f); | GUILayout.Space(2.0f); |
GUILayout.Label("Click middle mouse to show more info...", BuildOverlay.NameStyle); | GUILayout.Label("Click middle mouse to show more info...", BuildOverlay.NameStyle); |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
} | } |
} | } |
// | |
// Kerbal Engineer Redux | |
// | |
// Copyright (C) 2014 CYBUTEK | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// GNU General Public License for more details. | |
// | |
// You should have received a copy of the GNU General Public License | |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
// | |
#region Using Directives | |
using System; | |
using UnityEngine; | |
#endregion | |
namespace KerbalEngineer.Editor | |
{ | |
[KSPAddon(KSPAddon.Startup.EditorAny, false)] | |
public class BuildToolbar : MonoBehaviour | |
{ | |
#region Fields | |
private ApplicationLauncherButton button; | |
#endregion | |
#region Methods: private | |
private void Awake() | |
{ | |
GameEvents.onGUIApplicationLauncherReady.Add(this.OnGuiAppLauncherReady); | |
Logger.Log("BuildToolbar->Awake"); | |
} | |
private void Start() | |
{ | |
if (button == null) | |
{ | |
OnGuiAppLauncherReady(); | |
} | |
} | |
private void OnDestroy() | |
{ | |
GameEvents.onGUIApplicationLauncherReady.Remove(this.OnGuiAppLauncherReady); | |
if (this.button != null) | |
{ | |
ApplicationLauncher.Instance.RemoveModApplication(this.button); | |
} | |
Logger.Log("BuildToolbar->OnDestroy"); | |
} | |
private void OnGuiAppLauncherReady() | |
{ | |
try | |
{ | |
this.button = ApplicationLauncher.Instance.AddModApplication( | |
() => BuildAdvanced.Instance.Visible = true, | |
() => BuildAdvanced.Instance.Visible = false, | |
null, | |
null, | |
null, | |
null, | |
ApplicationLauncher.AppScenes.ALWAYS, | |
GameDatabase.Instance.GetTexture("KerbalEngineer/Textures/ToolbarIcon", false) | |
); | |
Logger.Log("BuildToolbar->OnGuiAppLauncherReady"); | |
} | |
catch (Exception ex) | |
{ | |
Logger.Exception(ex, "BuildToolbar->OnGuiAppLauncherReady"); | |
} | |
} | |
private void Update() | |
{ | |
try | |
{ | |
if (this.button == null) | |
{ | |
return; | |
} | |
if (EditorLogic.fetch != null && EditorLogic.fetch.ship.parts.Count > 0) | |
{ | |
if (BuildAdvanced.Instance.Visible && this.button.State != RUIToggleButton.ButtonState.TRUE) | |
{ | |
this.button.SetTrue(); | |
} | |
else if (!BuildAdvanced.Instance.Visible && this.button.State != RUIToggleButton.ButtonState.FALSE) | |
{ | |
this.button.SetFalse(); | |
} | |
} | |
else if (this.button.State != RUIToggleButton.ButtonState.DISABLED) | |
{ | |
this.button.Disable(); | |
} | |
} | |
catch (Exception ex) | |
{ | |
Logger.Exception(ex, "BuildToolbar->Update"); | |
} | |
} | |
#endregion | |
} | |
} |
// | // |
// Copyright (C) 2015 CYBUTEK | // Copyright (C) 2015 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
namespace KerbalEngineer | namespace KerbalEngineer |
{ | { |
using System.IO; | using System.IO; |
using System.Reflection; | using System.Reflection; |
public static class EngineerGlobals | public static class EngineerGlobals |
{ | { |
/// <summary> | /// <summary> |
/// Current version of the Kerbal Engineer assembly. | /// Current version of the Kerbal Engineer assembly. |
/// </summary> | /// </summary> |
public const string ASSEMBLY_VERSION = "1.0.18.1"; | public const string ASSEMBLY_VERSION = "1.0.19.4"; |
private static string assemblyFile; | private static string assemblyFile; |
private static string assemblyName; | private static string assemblyName; |
private static string assemblyPath; | private static string assemblyPath; |
private static string settingsPath; | |
/// <summary> | /// <summary> |
/// Gets the Kerbal Engineer assembly's path including the file name. | /// Gets the Kerbal Engineer assembly's path including the file name. |
/// </summary> | /// </summary> |
public static string AssemblyFile | public static string AssemblyFile |
{ | { |
get | get |
{ | { |
return assemblyFile ?? (assemblyFile = Assembly.GetExecutingAssembly().Location); | return assemblyFile ?? (assemblyFile = Assembly.GetExecutingAssembly().Location); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets the Kerbal Engineer assembly's file name. | /// Gets the Kerbal Engineer assembly's file name. |
/// </summary> | /// </summary> |
public static string AssemblyName | public static string AssemblyName |
{ | { |
get | get |
{ | { |
return assemblyName ?? (assemblyName = new FileInfo(AssemblyFile).Name); | return assemblyName ?? (assemblyName = new FileInfo(AssemblyFile).Name); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Gets the Kerbal Engineer assembly's path excluding the file name. | /// Gets the Kerbal Engineer assembly's path excluding the file name. |
/// </summary> | /// </summary> |
public static string AssemblyPath | public static string AssemblyPath |
{ | { |
get | get |
{ | { |
return assemblyPath ?? (assemblyPath = AssemblyFile.Replace(new FileInfo(AssemblyFile).Name, "")); | return assemblyPath ?? (assemblyPath = AssemblyFile.Replace(new FileInfo(AssemblyFile).Name, "")); |
} | } |
} | } |
/// <summary> | |
/// Gets the settings directory path. | |
/// </summary> | |
public static string SettingsPath | |
{ | |
get | |
{ | |
if (string.IsNullOrEmpty(settingsPath)) | |
{ | |
settingsPath = Path.Combine(AssemblyPath, "Settings"); | |
} | |
return settingsPath; | |
} | |
} | |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
using UnityEngine; | using UnityEngine; |
#endregion | #endregion |
namespace KerbalEngineer.Extensions | namespace KerbalEngineer.Extensions |
{ | { |
public static class OrbitExtensions | public static class OrbitExtensions |
{ | { |
#region Constants | #region Constants |
public const double Tau = Math.PI * 2.0; | public const double Tau = Math.PI * 2.0; |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public static double GetAngleToAscendingNode(this Orbit orbit) | public static double GetAngleToAscendingNode(this Orbit orbit) |
{ | { |
return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyOfAscendingNode(orbit)); | return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyOfAscendingNode(orbit)); |
} | } |
public static double GetAngleToDescendingNode(this Orbit orbit) | public static double GetAngleToDescendingNode(this Orbit orbit) |
{ | { |
return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyOfDescendingNode(orbit)); | return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyOfDescendingNode(orbit)); |
} | } |
public static double GetAngleToPrograde(this Orbit orbit) | public static double GetAngleToPrograde(this Orbit orbit) |
{ | { |
return GetAngleToPrograde(orbit, Planetarium.GetUniversalTime()); | return GetAngleToPrograde(orbit, Planetarium.GetUniversalTime()); |
} | } |
public static double GetAngleToPrograde(this Orbit orbit, double universalTime) | public static double GetAngleToPrograde(this Orbit orbit, double universalTime) |
{ | { |
if (orbit.referenceBody == CelestialBodies.SystemBody.CelestialBody) | if (orbit.referenceBody == CelestialBodies.SystemBody.CelestialBody) |
{ | { |
return 0.0; | return 0.0; |
} | } |
var angle = AngleHelper.GetAngleBetweenVectors(orbit.getRelativePositionAtUT(universalTime), | Vector3d orbitVector = orbit.getRelativePositionAtUT(universalTime); |
Vector3d.Exclude(orbit.GetOrbitNormal(), orbit.referenceBody.orbit.getRelativePositionAtUT(universalTime))); | orbitVector.z = 0.0; |
angle = AngleHelper.Clamp360(angle - 90.0); | Vector3d bodyVector = orbit.referenceBody.orbit.getOrbitalVelocityAtUT(universalTime); |
bodyVector.z = 0.0; | |
return orbit.inclination > 90.0 ? angle : 360.0 - angle; | double angle = AngleHelper.GetAngleBetweenVectors(bodyVector, orbitVector); |
return AngleHelper.Clamp360(orbit.inclination < 90.0 ? angle : 360.0 - angle); | |
} | } |
public static double GetAngleToRetrograde(this Orbit orbit) | public static double GetAngleToRetrograde(this Orbit orbit) |
{ | { |
return GetAngleToRetrograde(orbit, Planetarium.GetUniversalTime()); | return GetAngleToRetrograde(orbit, Planetarium.GetUniversalTime()); |
} | } |
public static double GetAngleToRetrograde(this Orbit orbit, double universalTime) | public static double GetAngleToRetrograde(this Orbit orbit, double universalTime) |
{ | { |
if (orbit.referenceBody == CelestialBodies.SystemBody.CelestialBody) | if (orbit.referenceBody == CelestialBodies.SystemBody.CelestialBody) |
{ | { |
return 0.0; | return 0.0; |
} | } |
var angle = AngleHelper.GetAngleBetweenVectors(orbit.getRelativePositionAtUT(universalTime), | Vector3d orbitVector = orbit.getRelativePositionAtUT(universalTime); |
Vector3d.Exclude(orbit.GetOrbitNormal(), orbit.referenceBody.orbit.getRelativePositionAtUT(universalTime))); | orbitVector.z = 0.0; |
angle = AngleHelper.Clamp360(angle + 90.0); | Vector3d bodyVector = orbit.referenceBody.orbit.getOrbitalVelocityAtUT(universalTime); |
bodyVector.z = 0.0; | |
return orbit.inclination > 90.0 ? angle : 360.0 - angle; | double angle = AngleHelper.GetAngleBetweenVectors(-bodyVector, orbitVector); |
return AngleHelper.Clamp360(orbit.inclination < 90.0 ? angle : 360.0 - angle); | |
} | } |
public static double GetAngleToTrueAnomaly(this Orbit orbit, double trueAnomaly) | public static double GetAngleToTrueAnomaly(this Orbit orbit, double trueAnomaly) |
{ | { |
return AngleHelper.Clamp360(trueAnomaly - orbit.trueAnomaly); | return AngleHelper.Clamp360(trueAnomaly - orbit.trueAnomaly); |
} | } |
public static double GetAngleToVector(this Orbit orbit, Vector3d vector) | public static double GetAngleToVector(this Orbit orbit, Vector3d vector) |
{ | { |
return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyFromVector(orbit, Vector3d.Exclude(orbit.GetOrbitNormal(), vector))); | return GetAngleToTrueAnomaly(orbit, GetTrueAnomalyFromVector(orbit, Vector3d.Exclude(orbit.GetOrbitNormal(), vector))); |
} | } |
public static double GetPhaseAngle(this Orbit orbit, Orbit target) | public static double GetPhaseAngle(this Orbit orbit, Orbit target) |
{ | { |
var angle = AngleHelper.GetAngleBetweenVectors(Vector3d.Exclude(orbit.GetOrbitNormal(), target.pos), orbit.pos); | var angle = AngleHelper.GetAngleBetweenVectors(Vector3d.Exclude(orbit.GetOrbitNormal(), target.pos), orbit.pos); |
return (orbit.semiMajorAxis < target.semiMajorAxis) ? angle : angle - 360.0; | return (orbit.semiMajorAxis < target.semiMajorAxis) ? angle : angle - 360.0; |
} | } |
public static double GetRelativeInclination(this Orbit orbit, Orbit target) | public static double GetRelativeInclination(this Orbit orbit, Orbit target) |
{ | { |
return Vector3d.Angle(orbit.GetOrbitNormal(), target.GetOrbitNormal()); | return Vector3d.Angle(orbit.GetOrbitNormal(), target.GetOrbitNormal()); |
} | } |
public static double GetTimeToAscendingNode(this Orbit orbit) | public static double GetTimeToAscendingNode(this Orbit orbit) |
{ | { |
return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyOfAscendingNode(orbit)); | return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyOfAscendingNode(orbit)); |
} | } |
public static double GetTimeToDescendingNode(this Orbit orbit) | public static double GetTimeToDescendingNode(this Orbit orbit) |
{ | { |
return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyOfDescendingNode(orbit)); | return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyOfDescendingNode(orbit)); |
} | } |
public static double GetTimeToTrueAnomaly(this Orbit orbit, double trueAnomaly) | public static double GetTimeToTrueAnomaly(this Orbit orbit, double trueAnomaly) |
{ | { |
var time = orbit.GetDTforTrueAnomaly(trueAnomaly * Mathf.Deg2Rad, orbit.period); | var time = orbit.GetDTforTrueAnomaly(trueAnomaly * Mathf.Deg2Rad, orbit.period); |
return time < 0.0 ? time + orbit.period : time; | return time < 0.0 ? time + orbit.period : time; |
} | } |
public static double GetTimeToVector(this Orbit orbit, Vector3d vector) | public static double GetTimeToVector(this Orbit orbit, Vector3d vector) |
{ | { |
return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyFromVector(orbit, vector)); | return GetTimeToTrueAnomaly(orbit, GetTrueAnomalyFromVector(orbit, vector)); |
} | } |
public static double GetTrueAnomalyFromVector(this Orbit orbit, Vector3d vector) | public static double GetTrueAnomalyFromVector(this Orbit orbit, Vector3d vector) |
{ | { |
return orbit.GetTrueAnomalyOfZupVector(vector) * Mathf.Rad2Deg; | return orbit.GetTrueAnomalyOfZupVector(vector) * Mathf.Rad2Deg; |
} | } |
public static double GetTrueAnomalyOfAscendingNode(this Orbit orbit) | public static double GetTrueAnomalyOfAscendingNode(this Orbit orbit) |
{ | { |
return 360.0 - orbit.argumentOfPeriapsis; | return 360.0 - orbit.argumentOfPeriapsis; |
} | } |
public static double GetTrueAnomalyOfDescendingNode(this Orbit orbit) | public static double GetTrueAnomalyOfDescendingNode(this Orbit orbit) |
{ | { |
return 180.0 - orbit.argumentOfPeriapsis; | return 180.0 - orbit.argumentOfPeriapsis; |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using UnityEngine; | using UnityEngine; |
#endregion | #endregion |
namespace KerbalEngineer.Flight | namespace KerbalEngineer.Flight |
{ | { |
using KSP.UI.Screens; | |
/// <summary> | /// <summary> |
/// Graphical controller for section interaction in the form of a menu system. | /// Graphical controller for section interaction in the form of a menu system. |
/// </summary> | /// </summary> |
[KSPAddon(KSPAddon.Startup.Flight, false)] | //[KSPAddon(KSPAddon.Startup.Flight, false)] |
public class ActionMenu : MonoBehaviour | public class ActionMenu : MonoBehaviour |
{ | { |
#region Fields | #region Fields |
private ActionMenuGui actionMenuGui; | private ActionMenuGui actionMenuGui; |
private ApplicationLauncherButton button; | private ApplicationLauncherButton button; |
#endregion | #endregion |
#region Methods: protected | #region Methods: protected |
protected void Awake() | protected void Awake() |
{ | { |
try | try |
{ | { |
GameEvents.onGUIApplicationLauncherReady.Add(this.OnGuiAppLauncherReady); | GameEvents.onGUIApplicationLauncherReady.Add(this.OnGuiAppLauncherReady); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
Logger.Log("ActionMenu was created."); | Logger.Log("ActionMenu was created."); |
} | } |
protected void Start() | protected void Start() |
{ | { |
if (button == null) | if (button == null) |
{ | { |
OnGuiAppLauncherReady(); | OnGuiAppLauncherReady(); |
} | } |
} | } |
protected void OnDestroy() | protected void OnDestroy() |
{ | { |
try | try |
{ | { |
GameEvents.onGUIApplicationLauncherReady.Remove(this.OnGuiAppLauncherReady); | GameEvents.onGUIApplicationLauncherReady.Remove(this.OnGuiAppLauncherReady); |
GameEvents.onHideUI.Remove(this.OnHide); | GameEvents.onHideUI.Remove(this.OnHide); |
GameEvents.onShowUI.Remove(this.OnShow); | GameEvents.onShowUI.Remove(this.OnShow); |
if (button != null) | if (button != null) |
{ | { |
ApplicationLauncher.Instance.RemoveModApplication(this.button); | ApplicationLauncher.Instance.RemoveModApplication(this.button); |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
Logger.Log("ActionMenu was destroyed."); | Logger.Log("ActionMenu was destroyed."); |
} | } |
protected void Update() | protected void Update() |
{ | { |
try | try |
{ | { |
if (this.button == null) | if (this.button == null) |
{ | { |
return; | return; |
} | } |
if (FlightEngineerCore.IsDisplayable && this.button.State == RUIToggleButton.ButtonState.DISABLED) | if (FlightEngineerCore.IsDisplayable && this.button.toggleButton.Interactable == false) |
{ | { |
this.button.Enable(); | this.button.Enable(); |
} | } |
else if (!FlightEngineerCore.IsDisplayable && this.button.State != RUIToggleButton.ButtonState.DISABLED) | else if (!FlightEngineerCore.IsDisplayable && this.button.toggleButton.Interactable) |
{ | { |
this.button.Disable(); | this.button.Disable(); |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
#endregion | #endregion |
#region Methods: private | #region Methods: private |
private void OnFalse() | private void OnFalse() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.enabled = false; | this.actionMenuGui.enabled = false; |
this.actionMenuGui.StayOpen = false; | this.actionMenuGui.StayOpen = false; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnGuiAppLauncherReady() | private void OnGuiAppLauncherReady() |
{ | { |
try | try |
{ | { |
this.button = ApplicationLauncher.Instance.AddModApplication( | this.button = ApplicationLauncher.Instance.AddModApplication( |
this.OnTrue, | this.OnTrue, |
this.OnFalse, | this.OnFalse, |
this.OnHover, | this.OnHover, |
this.OnHoverOut, | this.OnHoverOut, |
null, | null, |
null, | null, |
ApplicationLauncher.AppScenes.ALWAYS, | ApplicationLauncher.AppScenes.ALWAYS, |
GameDatabase.Instance.GetTexture("KerbalEngineer/Textures/ToolbarIcon", false)); | GameDatabase.Instance.GetTexture("KerbalEngineer/Textures/ToolbarIcon", false)); |
this.actionMenuGui = this.button.gameObject.AddComponent<ActionMenuGui>(); | this.actionMenuGui = this.button.gameObject.AddComponent<ActionMenuGui>(); |
this.actionMenuGui.transform.parent = this.button.transform; | this.actionMenuGui.transform.parent = this.button.transform; |
ApplicationLauncher.Instance.EnableMutuallyExclusive(this.button); | ApplicationLauncher.Instance.EnableMutuallyExclusive(this.button); |
GameEvents.onHideUI.Add(this.OnHide); | GameEvents.onHideUI.Add(this.OnHide); |
GameEvents.onShowUI.Add(this.OnShow); | GameEvents.onShowUI.Add(this.OnShow); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnHide() | private void OnHide() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.Hidden = true; | this.actionMenuGui.Hidden = true; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnHover() | private void OnHover() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.enabled = true; | this.actionMenuGui.enabled = true; |
this.actionMenuGui.Hovering = true; | this.actionMenuGui.Hovering = true; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnHoverOut() | private void OnHoverOut() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.Hovering = false; | this.actionMenuGui.Hovering = false; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnShow() | private void OnShow() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.Hidden = false; | this.actionMenuGui.Hidden = false; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
private void OnTrue() | private void OnTrue() |
{ | { |
try | try |
{ | { |
this.actionMenuGui.enabled = true; | this.actionMenuGui.enabled = true; |
this.actionMenuGui.StayOpen = true; | this.actionMenuGui.StayOpen = true; |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using System.Collections.Generic; | using System.Collections.Generic; |
using System.Linq; | using System.Linq; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Settings; | using KerbalEngineer.Settings; |
using UnityEngine; | using UnityEngine; |
#endregion | #endregion |
namespace KerbalEngineer.Flight | namespace KerbalEngineer.Flight |
{ | { |
using KeyBinding; | |
using Upgradeables; | using Upgradeables; |
/// <summary> | /// <summary> |
/// Graphical controller for displaying stacked sections. | /// Graphical controller for displaying stacked sections. |
/// </summary> | /// </summary> |
[KSPAddon(KSPAddon.Startup.Flight, false)] | [KSPAddon(KSPAddon.Startup.Flight, false)] |
public class DisplayStack : MonoBehaviour | public class DisplayStack : MonoBehaviour |
{ | { |
#region Fields | #region Fields |
private GUIStyle buttonStyle; | private GUIStyle buttonStyle; |
private int numberOfStackSections; | private int numberOfStackSections; |
private bool resizeRequested; | private bool resizeRequested; |
private bool showControlBar = true; | private bool showControlBar = true; |
private GUIStyle titleStyle; | private GUIStyle titleStyle; |
private int windowId; | private int windowId; |
private Rect windowPosition; | private Rect windowPosition; |
private GUIStyle windowStyle; | private GUIStyle windowStyle; |
#endregion | #endregion |
#region Properties | #region Properties |
/// <summary> | /// <summary> |
/// Gets the current instance of the DisplayStack. | /// Gets the current instance of the DisplayStack. |
/// </summary> | /// </summary> |
public static DisplayStack Instance { get; private set; } | public static DisplayStack Instance { get; private set; } |
public bool Hidden { get; set; } | public bool Hidden { get; set; } |
/// <summary> | /// <summary> |
/// Gets and sets the visibility of the control bar. | /// Gets and sets the visibility of the control bar. |
/// </summary> | /// </summary> |
public bool ShowControlBar | public bool ShowControlBar |
{ | { |
get { return this.showControlBar; } | get { return this.showControlBar; } |
set { this.showControlBar = value; } | set { this.showControlBar = value; } |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
/// <summary> | /// <summary> |
/// Request that the display stack's size is reset in the next draw call. | /// Request that the display stack's size is reset in the next draw call. |
/// </summary> | /// </summary> |
public void RequestResize() | public void RequestResize() |
{ | { |
this.resizeRequested = true; | this.resizeRequested = true; |
} | } |
#endregion | #endregion |
#region Methods: protected | #region Methods: protected |
/// <summary> | /// <summary> |
/// Sets the instance to this object. | /// Sets the instance to this object. |
/// </summary> | /// </summary> |
protected void Awake() | protected void Awake() |
{ | { |
try | try |
{ | { |
if (Instance == null) | if (Instance == null) |
{ | { |
Instance = this; | Instance = this; |
GuiDisplaySize.OnSizeChanged += this.OnSizeChanged; | GuiDisplaySize.OnSizeChanged += this.OnSizeChanged; |
Logger.Log("ActionMenu->Awake"); | Logger.Log("ActionMenu->Awake"); |
} | } |
else | else |
{ | { |
Destroy(this); | Destroy(this); |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Runs when the object is destroyed. | /// Runs when the object is destroyed. |
/// </summary> | /// </summary> |
protected void OnDestroy() | protected void OnDestroy() |
{ | { |
try | try |
{ | { |
this.Save(); | this.Save(); |
RenderingManager.RemoveFromPostDrawQueue(0, this.Draw); | RenderingManager.RemoveFromPostDrawQueue(0, this.Draw); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
Logger.Log("ActionMenu->OnDestroy"); | Logger.Log("ActionMenu->OnDestroy"); |
} | } |
/// <summary> | /// <summary> |
/// Initialises the object's state on creation. | /// Initialises the object's state on creation. |
/// </summary> | /// </summary> |
protected void Start() | protected void Start() |
{ | { |
try | try |
{ | { |
this.windowId = this.GetHashCode(); | this.windowId = this.GetHashCode(); |
this.InitialiseStyles(); | this.InitialiseStyles(); |
this.Load(); | this.Load(); |
RenderingManager.AddToPostDrawQueue(0, this.Draw); | RenderingManager.AddToPostDrawQueue(0, this.Draw); |
Logger.Log("ActionMenu->Start"); | Logger.Log("ActionMenu->Start"); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
protected void Update() | protected void Update() |
{ | { |
try | try |
{ | { |
if (!FlightEngineerCore.IsDisplayable) | if (!FlightEngineerCore.IsDisplayable) |
{ | { |
return; | return; |
} | } |
if (Input.GetKeyDown(KeyBinder.FlightShowHide)) | if (Input.GetKeyDown(KeyBinder.FlightShowHide)) |
{ | { |
this.Hidden = !this.Hidden; | this.Hidden = !this.Hidden; |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
#endregion | #endregion |
#region Methods: private | #region Methods: private |
/// <summary> | /// <summary> |
/// Called to draw the display stack when the UI is enabled. | /// Called to draw the display stack when the UI is enabled. |
/// </summary> | /// </summary> |
private void Draw() | private void Draw() |
{ | { |
try | try |
{ | { |
if (!FlightEngineerCore.IsDisplayable) | if (!FlightEngineerCore.IsDisplayable) |
{ | { |
return; | return; |
} | } |
if (this.resizeRequested || this.numberOfStackSections != SectionLibrary.NumberOfStackSections) | if (this.resizeRequested || this.numberOfStackSections != SectionLibrary.NumberOfStackSections) |
{ | { |
this.numberOfStackSections = SectionLibrary.NumberOfStackSections; | this.numberOfStackSections = SectionLibrary.NumberOfStackSections; |
this.windowPosition.width = 0; | this.windowPosition.width = 0; |
this.windowPosition.height = 0; | this.windowPosition.height = 0; |
this.resizeRequested = false; | this.resizeRequested = false; |
} | } |
if (!this.Hidden && (SectionLibrary.NumberOfStackSections > 0 || this.ShowControlBar)) | if (!this.Hidden && (SectionLibrary.NumberOfStackSections > 0 || this.ShowControlBar)) |
{ | { |
var shouldCentre = this.windowPosition.min == Vector2.zero; | var shouldCentre = this.windowPosition.min == Vector2.zero; |
GUI.skin = null; | GUI.skin = null; |
this.windowPosition = GUILayout.Window(this.windowId, this.windowPosition, this.Window, string.Empty, this.windowStyle).ClampToScreen(); | this.windowPosition = GUILayout.Window(this.windowId, this.windowPosition, this.Window, string.Empty, this.windowStyle).ClampToScreen(); |
if (shouldCentre) | if (shouldCentre) |
{ | { |
this.windowPosition.center = new Vector2(Screen.width * 0.5f, Screen.height * 0.5f); | this.windowPosition.center = new Vector2(Screen.width * 0.5f, Screen.height * 0.5f); |
} | } |
} | } |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex); | Logger.Exception(ex); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Draws the control bar. | /// Draws the control bar. |
/// </summary> | /// </summary> |
private void DrawControlBar() | private void DrawControlBar() |
{ | { |
GUILayout.Label("FLIGHT ENGINEER " + EngineerGlobals.ASSEMBLY_VERSION, this.titleStyle); | GUILayout.Label("FLIGHT ENGINEER " + EngineerGlobals.ASSEMBLY_VERSION, this.titleStyle); |
this.DrawControlBarButtons(SectionLibrary.StockSections); | this.DrawControlBarButtons(SectionLibrary.StockSections); |
this.DrawControlBarButtons(SectionLibrary.CustomSections); | this.DrawControlBarButtons(SectionLibrary.CustomSections); |
} | } |
/// <summary> | /// <summary> |
/// Draws a button list for a set of sections. | /// Draws a button list for a set of sections. |
/// </summary> | /// </summary> |
private void DrawControlBarButtons(IEnumerable<SectionModule> sections) | private void DrawControlBarButtons(IEnumerable<SectionModule> sections) |
{ | { |
var index = 0; | var index = 0; |
foreach (var section in sections.Where(s => !string.IsNullOrEmpty(s.Abbreviation) || !s.IsCustom)) | foreach (var section in sections.Where(s => !string.IsNullOrEmpty(s.Abbreviation) || !s.IsCustom)) |
{ | { |
if (index % 4 == 0) | if (index % 4 == 0) |
{ | { |
if (index > 0) | if (index > 0) |
{ | { |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
} | } |
GUILayout.BeginHorizontal(); | GUILayout.BeginHorizontal(); |
} | } |
section.IsVisible = GUILayout.Toggle(section.IsVisible, section.Abbreviation.ToUpper(), this.buttonStyle); | section.IsVisible = GUILayout.Toggle(section.IsVisible, section.Abbreviation.ToUpper(), this.buttonStyle); |
index++; | index++; |
} | } |
if (index > 0) | if (index > 0) |
{ | { |
GUILayout.EndHorizontal(); | GUILayout.EndHorizontal(); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Draws a list of sections. | /// Draws a list of sections. |
/// </summary> | /// </summary> |
private void DrawSections(IEnumerable<SectionModule> sections) | private void DrawSections(IEnumerable<SectionModule> sections) |
{ | { |
foreach (var section in sections) | foreach (var section in sections) |
{ | { |
if (!section.IsFloating) | if (!section.IsFloating) |
{ | { |
section.Draw(); | section.Draw(); |
} | } |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Initialises all the styles required for this object. | /// Initialises all the styles required for this object. |
/// </summary> | /// </summary> |
private void InitialiseStyles() | private void InitialiseStyles() |
{ | { |
this.windowStyle = new GUIStyle(HighLogic.Skin.window) | this.windowStyle = new GUIStyle(HighLogic.Skin.window) |
{ | { |
margin = new RectOffset(), | margin = new RectOffset(), |
padding = new RectOffset(5, 5, 0, 5) | padding = new RectOffset(5, 5, 0, 5) |
}; | }; |
this.titleStyle = new GUIStyle(HighLogic.Skin.label) | this.titleStyle = new GUIStyle(HighLogic.Skin.label) |
{ | { |
margin = new RectOffset(0, 0, 5, 3), | margin = new RectOffset(0, 0, 5, 3), |
padding = new RectOffset(), | padding = new RectOffset(), |
alignment = TextAnchor.MiddleCenter, | alignment = TextAnchor.MiddleCenter, |
fontSize = (int)(13 * GuiDisplaySize.Offset), | fontSize = (int)(13 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
stretchWidth = true | stretchWidth = true |
}; | }; |
this.buttonStyle = new GUIStyle(HighLogic.Skin.button) | this.buttonStyle = new GUIStyle(HighLogic.Skin.button) |
{ | { |
normal = | normal = |
{ | { |
textColor = Color.white | textColor = Color.white |
}, | }, |
margin = new RectOffset(), | margin = new RectOffset(), |
padding = new RectOffset(), | padding = new RectOffset(), |
alignment = TextAnchor.MiddleCenter, | alignment = TextAnchor.MiddleCenter, |
fontSize = (int)(11 * GuiDisplaySize.Offset), | fontSize = (int)(11 * GuiDisplaySize.Offset), |
fontStyle = FontStyle.Bold, | fontStyle = FontStyle.Bold, |
fixedWidth = 60.0f * GuiDisplaySize.Offset, | fixedWidth = 60.0f * GuiDisplaySize.Offset, |
fixedHeight = 25.0f * GuiDisplaySize.Offset, | fixedHeight = 25.0f * GuiDisplaySize.Offset, |
}; | }; |
} | } |
/// <summary> | /// <summary> |
/// Load the stack's state. | /// Load the stack's state. |
/// </summary> | /// </summary> |
private void Load() | private void Load() |
{ | { |
try | try |
{ | { |
var handler = SettingHandler.Load("DisplayStack.xml"); | var handler = SettingHandler.Load("DisplayStack.xml"); |
this.Hidden = handler.Get("hidden", this.Hidden); | this.Hidden = handler.Get("hidden", this.Hidden); |
this.ShowControlBar = handler.Get("showControlBar", this.ShowControlBar); | this.ShowControlBar = handler.Get("showControlBar", this.ShowControlBar); |
this.windowPosition.x = handler.Get("windowPositionX", this.windowPosition.x); | this.windowPosition.x = handler.Get("windowPositionX", this.windowPosition.x); |
this.windowPosition.y = handler.Get("windowPositionY", this.windowPosition.y); | this.windowPosition.y = handler.Get("windowPositionY", this.windowPosition.y); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "DisplayStack->Load"); | Logger.Exception(ex, "DisplayStack->Load"); |
} | } |
} | } |
private void OnSizeChanged() | private void OnSizeChanged() |
{ | { |
this.InitialiseStyles(); | this.InitialiseStyles(); |
this.RequestResize(); | this.RequestResize(); |
} | } |
/// <summary> | /// <summary> |
/// Saves the stack's state. | /// Saves the stack's state. |
/// </summary> | /// </summary> |
private void Save() | private void Save() |
{ | { |
try | try |
{ | { |
var handler = new SettingHandler(); | var handler = new SettingHandler(); |
handler.Set("hidden", this.Hidden); | handler.Set("hidden", this.Hidden); |
handler.Set("showControlBar", this.ShowControlBar); | handler.Set("showControlBar", this.ShowControlBar); |
handler.Set("windowPositionX", this.windowPosition.x); | handler.Set("windowPositionX", this.windowPosition.x); |
handler.Set("windowPositionY", this.windowPosition.y); | handler.Set("windowPositionY", this.windowPosition.y); |
handler.Save("DisplayStack.xml"); | handler.Save("DisplayStack.xml"); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "DisplayStack->Save"); | Logger.Exception(ex, "DisplayStack->Save"); |
} | } |
} | } |
/// <summary> | /// <summary> |
/// Draws the display stack window. | /// Draws the display stack window. |
/// </summary> | /// </summary> |
private void Window(int windowId) | private void Window(int windowId) |
{ | { |
try | try |
{ | { |
if (this.ShowControlBar) | if (this.ShowControlBar) |
{ | { |
this.DrawControlBar(); | this.DrawControlBar(); |
} | } |
if (SectionLibrary.NumberOfStackSections > 0) | if (SectionLibrary.NumberOfStackSections > 0) |
{ | { |
this.DrawSections(SectionLibrary.StockSections); | this.DrawSections(SectionLibrary.StockSections); |
this.DrawSections(SectionLibrary.CustomSections); | this.DrawSections(SectionLibrary.CustomSections); |
} | } |
GUI.DragWindow(); | GUI.DragWindow(); |
} | } |
catch (Exception ex) | catch (Exception ex) |
{ | { |
Logger.Exception(ex, "DisplayStack->Widnow"); | Logger.Exception(ex, "DisplayStack->Widnow"); |
} | } |
} | } |
#endregion | #endregion |
} | } |
} | } |
namespace KerbalEngineer.Flight | |
{ | |
using System; | |
using UnityEngine; | |
[KSPAddon(KSPAddon.Startup.Flight, false)] | |
public class FlightAppLauncher : AppLauncherButton | |
{ | |
private static FlightAppLauncher m_Instance; | |
private GameObject m_MenuObject; | |
private GameObject m_MenuPrefab; | |
public static event Action ButtonHover; | |
public static event Action MenuClosed; | |
/// <summary> | |
/// Gets the current instance of the FlightAppLauncher object. | |
/// </summary> | |
public static FlightAppLauncher instance | |
{ | |
get | |
{ | |
return m_Instance; | |
} | |
} | |
protected override void Awake() | |
{ | |
base.Awake(); | |
// set singleton instance | |
m_Instance = this; | |
// cache menu prefab | |
if (m_MenuPrefab == null && AssetBundleLoader.prefabs != null) | |
{ | |
m_MenuPrefab = AssetBundleLoader.prefabs.LoadAsset<GameObject>("flight-menu"); | |
} | |
} | |
protected override void OnFalse() | |
{ | |
Close(); | |
} | |
protected override void OnHover() | |
{ | |
Open(); | |
ButtonHover?.Invoke(); | |
} | |
protected override void OnHoverOut() | |
{ | |
if (isOn == false) | |
{ | |
Close(); | |
} | |
} | |
protected override void OnTrue() | |
{ | |
Open(); | |
} | |
/// <summary> | |
/// Closes the menu. | |
/// </summary> | |
private void Close() | |
{ | |
if (m_MenuObject == null) | |
{ | |
return; | |
} | |
if (MenuClosed != null) | |
{ | |
MenuClosed(); | |
} | |
else | |
{ | |
Destroy(m_MenuObject); | |
} | |
} | |
/// <summary> | |
/// Opens the menu. | |
/// </summary> | |
private void Open() | |
{ | |
if (m_MenuPrefab == null || m_MenuObject != null) | |
{ | |
return; | |
} | |
// create object | |
m_MenuObject = Instantiate(m_MenuPrefab, GetAnchor(), Quaternion.identity) as GameObject; | |
if (m_MenuObject == null) | |
{ | |
return; | |
} | |
// set object as a child of the main canvas | |
m_MenuObject.transform.SetParent(MainCanvasUtil.MainCanvas.transform); | |
} | |
} | |
} |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
using UnityEngine; | using UnityEngine; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Miscellaneous | namespace KerbalEngineer.Flight.Readouts.Miscellaneous |
{ | { |
public class Separator : ReadoutModule | public class Separator : ReadoutModule |
{ | { |
#region Fields | #region Fields |
private GUIStyle boxStyle; | private GUIStyle boxStyle; |
private GUIStyle boxStyleHud; | private GUIStyle boxStyleHud; |
#endregion | #endregion |
#region Constructors | #region Constructors |
public Separator() | public Separator() |
{ | { |
this.Name = "Separator"; | this.Name = "Separator"; |
this.Category = ReadoutCategory.GetCategory("Miscellaneous"); | this.Category = ReadoutCategory.GetCategory("Miscellaneous"); |
this.HelpString = String.Empty; | this.HelpString = "Creats a line to help seperate subsections in a module."; |
this.IsDefault = false; | this.IsDefault = false; |
this.Cloneable = true; | this.Cloneable = true; |
this.InitialiseStyles(); | this.InitialiseStyles(); |
GuiDisplaySize.OnSizeChanged += this.InitialiseStyles; | GuiDisplaySize.OnSizeChanged += this.InitialiseStyles; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
GUILayout.Box(String.Empty, section.IsHud ? this.boxStyleHud : this.boxStyle); | GUILayout.Box(String.Empty, section.IsHud ? this.boxStyleHud : this.boxStyle); |
} | } |
#endregion | #endregion |
#region Methods: private | #region Methods: private |
private void InitialiseStyles() | private void InitialiseStyles() |
{ | { |
this.boxStyle = new GUIStyle | this.boxStyle = new GUIStyle |
{ | { |
normal = | normal = |
{ | { |
background = TextureHelper.CreateTextureFromColour(new Color(1.0f, 1.0f, 1.0f, 0.5f)) | background = TextureHelper.CreateTextureFromColour(new Color(1.0f, 1.0f, 1.0f, 0.5f)) |
}, | }, |
fixedHeight = 1.0f, | fixedHeight = 1.0f, |
stretchWidth = true | stretchWidth = true |
}; | }; |
this.boxStyleHud = new GUIStyle(this.boxStyle) | this.boxStyleHud = new GUIStyle(this.boxStyle) |
{ | { |
margin = new RectOffset(0, 0, (int)(8 * GuiDisplaySize.Offset), 0) | margin = new RectOffset(0, 0, (int)(8 * GuiDisplaySize.Offset), 0) |
}; | }; |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
using UnityEngine; | using UnityEngine; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Miscellaneous | namespace KerbalEngineer.Flight.Readouts.Miscellaneous |
{ | { |
public class SystemTime : ReadoutModule | public class SystemTime : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public SystemTime() | public SystemTime() |
{ | { |
this.Name = "System Time"; | this.Name = "System Time"; |
this.Category = ReadoutCategory.GetCategory("Miscellaneous"); | this.Category = ReadoutCategory.GetCategory("Miscellaneous"); |
this.HelpString = String.Empty; | this.HelpString = "Shows the System Time in 12 hour format (AM/PM)"; |
this.IsDefault = false; | this.IsDefault = false; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(DateTime.Now.ToLongTimeString(), section.IsHud); | this.DrawLine(DateTime.Now.ToLongTimeString(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | |
// Kerbal Engineer Redux | |
// | |
// Copyright (C) 2014 CYBUTEK | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// GNU General Public License for more details. | |
// | |
// You should have received a copy of the GNU General Public License | |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
// | |
#region Using Directives | |
using System; | |
using KerbalEngineer.Flight.Sections; | |
using KerbalEngineer.Helpers; | |
using UnityEngine; | |
#endregion | |
namespace KerbalEngineer.Flight.Readouts.Miscellaneous | |
{ | |
public class TimeReference : ReadoutModule | |
{ | |
#region Constructors | |
public TimeReference() | |
{ | |
this.Name = "Time Reference Adjuster"; | |
this.Category = ReadoutCategory.GetCategory("Miscellaneous"); | |
this.HelpString = String.Empty; | |
this.IsDefault = false; | |
} | |
#endregion | |
#region Methods: public | |
public override void Draw(SectionModule section) | |
{ | |
GUILayout.BeginHorizontal(); | |
GUILayout.Label("Time Ref.: " + TimeFormatter.Reference, this.NameStyle); | |
if (GUILayout.Button("Earth", this.ButtonStyle)) | |
{ | |
TimeFormatter.SetReference(); | |
} | |
if (GUILayout.Button("Kerbin", this.ButtonStyle)) | |
{ | |
TimeFormatter.SetReference(PSystemManager.Instance.localBodies.Find(body => body.bodyName.Equals("Kerbin"))); | |
} | |
GUILayout.EndHorizontal(); | |
} | |
#endregion | |
} | |
} |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class AngleToEquatorialAscendingNode : ReadoutModule | public class AngleToEquatorialAscendingNode : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public AngleToEquatorialAscendingNode() | public AngleToEquatorialAscendingNode() |
{ | { |
this.Name = "Angle to Equ. AN"; | this.Name = "Angle to Equ. AN"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = string.Empty; | this.HelpString = "Angular Distance from the vessel to crossing the Equator of the central body, going north of it."; |
this.IsDefault = false; | this.IsDefault = false; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ActiveVessel.orbit.GetAngleToAscendingNode().ToAngle(), section.IsHud); | this.DrawLine(FlightGlobals.ActiveVessel.orbit.GetAngleToAscendingNode().ToAngle(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class AngleToEquatorialDescendingNode : ReadoutModule | public class AngleToEquatorialDescendingNode : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public AngleToEquatorialDescendingNode() | public AngleToEquatorialDescendingNode() |
{ | { |
this.Name = "Angle to Equ. DN"; | this.Name = "Angle to Equ. DN"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = string.Empty; | this.HelpString = "Angular Distance from the vessel to crossing the Equator of the central body, going south of it."; |
this.IsDefault = false; | this.IsDefault = false; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ActiveVessel.orbit.GetAngleToDescendingNode().ToAngle(), section.IsHud); | this.DrawLine(FlightGlobals.ActiveVessel.orbit.GetAngleToDescendingNode().ToAngle(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class AngleToPrograde : ReadoutModule | public class AngleToPrograde : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public AngleToPrograde() | public AngleToPrograde() |
{ | { |
this.Name = "Angle to Prograde"; | this.Name = "Angle to Prograde"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Angular Distance from the vessel to crossing the Orbit of the central body on it's retrograde side."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ship_orbit.GetAngleToPrograde().ToAngle(), section.IsHud); | this.DrawLine(FlightGlobals.ship_orbit.GetAngleToPrograde().ToAngle(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class AngleToRetrograde : ReadoutModule | public class AngleToRetrograde : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public AngleToRetrograde() | public AngleToRetrograde() |
{ | { |
this.Name = "Angle to Retrograde"; | this.Name = "Angle to Retrograde"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Angular Distance from the vessel to crossing the Orbit of the central body on it's retrograde side."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ship_orbit.GetAngleToRetrograde().ToAngle(), section.IsHud); | this.DrawLine(FlightGlobals.ship_orbit.GetAngleToRetrograde().ToAngle(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class ApoapsisHeight : ReadoutModule | public class ApoapsisHeight : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public ApoapsisHeight() | public ApoapsisHeight() |
{ | { |
this.Name = "Apoapsis Height"; | this.Name = "Apoapsis Height"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = "Shows the vessel's apoapsis height relative to sea level. (Apoapsis is the highest point of an orbit.)"; | this.HelpString = "Shows the vessel's apoapsis height relative to sea level. (Apoapsis is the highest point of an orbit.)"; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ship_orbit.ApA.ToDistance(), section.IsHud); | this.DrawLine(FlightGlobals.ship_orbit.ApA.ToDistance(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2015 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | |
using System; | |
using KerbalEngineer.Extensions; | |
using KerbalEngineer.Flight.Sections; | |
#endregion | |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
using Extensions; | |
using Helpers; | |
using Sections; | |
public class EccentricAnomaly : ReadoutModule | public class EccentricAnomaly : ReadoutModule |
{ | { |
#region Constructors | |
public EccentricAnomaly() | public EccentricAnomaly() |
{ | { |
this.Name = "Eccentric Anomaly"; | Name = "Eccentric Anomaly"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | HelpString = string.Empty; |
this.IsDefault = false; | IsDefault = false; |
} | } |
#endregion | |
#region Methods: public | |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ship_orbit.eccentricAnomaly.ToAngle(), section.IsHud); | DrawLine((FlightGlobals.ship_orbit.eccentricAnomaly * Units.RAD_TO_DEG).ToAngle(), section.IsHud); |
} | } |
#endregion | |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital | namespace KerbalEngineer.Flight.Readouts.Orbital |
{ | { |
public class Inclination : ReadoutModule | public class Inclination : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public Inclination() | public Inclination() |
{ | { |
this.Name = "Inclination"; | this.Name = "Inclination"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = "Shows the vessel's orbital inclination."; | this.HelpString = "Shows the vessel's orbital inclination relative to the Equator."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
this.DrawLine(FlightGlobals.ship_orbit.inclination.ToAngle(), section.IsHud); | this.DrawLine(FlightGlobals.ship_orbit.inclination.ToAngle(), section.IsHud); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeAngleToPrograde : ReadoutModule | public class NodeAngleToPrograde : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeAngleToPrograde() | public NodeAngleToPrograde() |
{ | { |
this.Name = "Manoeuvre Node Angle to Prograde"; | this.Name = "Manoeuvre Node Angle to Prograde"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Angular Distance from the Node to crossing the Orbit of the central body on it's prograde side."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node Angle to Prograde", ManoeuvreProcessor.AngleToPrograde.ToAngle(), section.IsHud); | this.DrawLine("Node Angle to Prograde", ManoeuvreProcessor.AngleToPrograde.ToAngle(), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeAngleToRetrograde : ReadoutModule | public class NodeAngleToRetrograde : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeAngleToRetrograde() | public NodeAngleToRetrograde() |
{ | { |
this.Name = "Manoeuvre Node Angle to Retrograde"; | this.Name = "Manoeuvre Node Angle to Retrograde"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Angular Distance from the Node to crossing the Orbit of the central body on it's retrograde side."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node Angle to Retrograde", ManoeuvreProcessor.AngleToRetrograde.ToAngle(), section.IsHud); | this.DrawLine("Node Angle to Retrograde", ManoeuvreProcessor.AngleToRetrograde.ToAngle(), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeBurnTime : ReadoutModule | public class NodeBurnTime : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeBurnTime() | public NodeBurnTime() |
{ | { |
this.Name = "Manoeuvre Node Burn Time"; | this.Name = "Manoeuvre Node Burn Time"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "The burn's total duration."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node Burn Time", TimeFormatter.ConvertToString(ManoeuvreProcessor.BurnTime), section.IsHud); | this.DrawLine("Node Burn Time", TimeFormatter.ConvertToString(ManoeuvreProcessor.BurnTime), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeHalfBurnTime : ReadoutModule | public class NodeHalfBurnTime : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeHalfBurnTime() | public NodeHalfBurnTime() |
{ | { |
this.Name = "Manoeuvre Node Half Burn Time"; | this.Name = "Manoeuvre Node Half Burn Time"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Half of the burn's total duration."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node Burn Time (½)", TimeFormatter.ConvertToString(ManoeuvreProcessor.HalfBurnTime), section.IsHud); | this.DrawLine("Node Burn Time (½)", TimeFormatter.ConvertToString(ManoeuvreProcessor.HalfBurnTime), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeNormalDeltaV : ReadoutModule | public class NodeNormalDeltaV : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeNormalDeltaV() | public NodeNormalDeltaV() |
{ | { |
this.Name = "Manoeuvre Node DeltaV (Normal)"; | this.Name = "Manoeuvre Node DeltaV (Normal)"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Normal component of the total change in velocity."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node DeltaV (Normal)", ManoeuvreProcessor.NormalDeltaV.ToSpeed(), section.IsHud); | this.DrawLine("Node DeltaV (Normal)", ManoeuvreProcessor.NormalDeltaV.ToSpeed(), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeProgradeDeltaV : ReadoutModule | public class NodeProgradeDeltaV : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeProgradeDeltaV() | public NodeProgradeDeltaV() |
{ | { |
this.Name = "Manoeuvre Node DeltaV (Prograde)"; | this.Name = "Manoeuvre Node DeltaV (Prograde)"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Prograde/Retrograde component of the total change in velocity."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node DeltaV (Prograde)", ManoeuvreProcessor.ProgradeDeltaV.ToSpeed(), section.IsHud); | this.DrawLine("Node DeltaV (Prograde)", ManoeuvreProcessor.ProgradeDeltaV.ToSpeed(), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeRadialDeltaV : ReadoutModule | public class NodeRadialDeltaV : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeRadialDeltaV() | public NodeRadialDeltaV() |
{ | { |
this.Name = "Manoeuvre Node DeltaV (Radial)"; | this.Name = "Manoeuvre Node DeltaV (Radial)"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Radial component of the total change in velocity."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Node DeltaV (Radial)", ManoeuvreProcessor.RadialDeltaV.ToSpeed(), section.IsHud); | this.DrawLine("Node DeltaV (Radial)", ManoeuvreProcessor.RadialDeltaV.ToSpeed(), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeTimeToHalfBurn : ReadoutModule | public class NodeTimeToHalfBurn : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeTimeToHalfBurn() | public NodeTimeToHalfBurn() |
{ | { |
this.Name = "Time to Manoeuvre Burn"; | this.Name = "Time to Manoeuvre Burn"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Time until the Manoeuvre should be started."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Time to Node Burn", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - ManoeuvreProcessor.HalfBurnTime - Planetarium.GetUniversalTime()), section.IsHud); | this.DrawLine("Time to Node Burn", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - ManoeuvreProcessor.HalfBurnTime - Planetarium.GetUniversalTime()), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
using KerbalEngineer.Helpers; | using KerbalEngineer.Helpers; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeTimeToManoeuvre : ReadoutModule | public class NodeTimeToManoeuvre : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeTimeToManoeuvre() | public NodeTimeToManoeuvre() |
{ | { |
this.Name = "Time to Manoeuvre Node"; | this.Name = "Time to Manoeuvre Node"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Time until the vessel reaches the position of the Manoeuvre Node."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |
#region Methods: public | #region Methods: public |
public override void Draw(SectionModule section) | public override void Draw(SectionModule section) |
{ | { |
if (!ManoeuvreProcessor.ShowDetails) | if (!ManoeuvreProcessor.ShowDetails) |
{ | { |
return; | return; |
} | } |
this.DrawLine("Time to Node", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - Planetarium.GetUniversalTime()), section.IsHud); | this.DrawLine("Time to Node", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - Planetarium.GetUniversalTime()), section.IsHud); |
} | } |
public override void Reset() | public override void Reset() |
{ | { |
ManoeuvreProcessor.Reset(); | ManoeuvreProcessor.Reset(); |
} | } |
public override void Update() | public override void Update() |
{ | { |
ManoeuvreProcessor.RequestUpdate(); | ManoeuvreProcessor.RequestUpdate(); |
} | } |
#endregion | #endregion |
} | } |
} | } |
// | // |
// Kerbal Engineer Redux | // Kerbal Engineer Redux |
// | // |
// Copyright (C) 2014 CYBUTEK | // Copyright (C) 2014 CYBUTEK |
// | // |
// This program is free software: you can redistribute it and/or modify | // This program is free software: you can redistribute it and/or modify |
// it under the terms of the GNU General Public License as published by | // it under the terms of the GNU General Public License as published by |
// the Free Software Foundation, either version 3 of the License, or | // the Free Software Foundation, either version 3 of the License, or |
// (at your option) any later version. | // (at your option) any later version. |
// | // |
// This program is distributed in the hope that it will be useful, | // This program is distributed in the hope that it will be useful, |
// but WITHOUT ANY WARRANTY; without even the implied warranty of | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// GNU General Public License for more details. | // GNU General Public License for more details. |
// | // |
// You should have received a copy of the GNU General Public License | // You should have received a copy of the GNU General Public License |
// along with this program. If not, see <http://www.gnu.org/licenses/>. | // along with this program. If not, see <http://www.gnu.org/licenses/>. |
// | // |
#region Using Directives | #region Using Directives |
using System; | using System; |
using KerbalEngineer.Extensions; | using KerbalEngineer.Extensions; |
using KerbalEngineer.Flight.Sections; | using KerbalEngineer.Flight.Sections; |
#endregion | #endregion |
namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode | namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode |
{ | { |
public class NodeTotalDeltaV : ReadoutModule | public class NodeTotalDeltaV : ReadoutModule |
{ | { |
#region Constructors | #region Constructors |
public NodeTotalDeltaV() | public NodeTotalDeltaV() |
{ | { |
this.Name = "Manoeuvre Node DeltaV (Total)"; | this.Name = "Manoeuvre Node DeltaV (Total)"; |
this.Category = ReadoutCategory.GetCategory("Orbital"); | this.Category = ReadoutCategory.GetCategory("Orbital"); |
this.HelpString = String.Empty; | this.HelpString = "Total change in velocity during the burn."; |
this.IsDefault = true; | this.IsDefault = true; |
} | } |
#endregion | #endregion |