Skip to content

Commit 7cff7aa

Browse files
committed
* **FIX**: Hotfix to fix issue with R&D window not working under certain conditions
1 parent b880208 commit 7cff7aa

File tree

1 file changed

+2
-25
lines changed

1 file changed

+2
-25
lines changed

TestFlightCore/TestFlightCore/TestFlightEditor.cs

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -103,17 +103,13 @@ public class TestFlightEditorWindow : MonoBehaviourWindowPlus
103103
{
104104
internal static TestFlightEditorWindow Instance;
105105
internal TestFlightEditorInfoWindow infoWindow = null;
106-
private bool locked = false;
107106
private Part _selectedPart;
108107
internal Part SelectedPart
109108
{
110109
set
111110
{
112-
if (!locked)
113-
{
114-
this._selectedPart = value;
115-
CalculateWindowBounds();
116-
}
111+
this._selectedPart = value;
112+
CalculateWindowBounds();
117113
}
118114
get
119115
{
@@ -129,16 +125,10 @@ internal Part SelectedPart
129125

130126
public void LockPart(Part partToLock, string alias)
131127
{
132-
locked = true;
133128
SelectedPart = partToLock;
134129
selectedAlias = alias;
135130
}
136131

137-
public void UnlockPart()
138-
{
139-
locked = false;
140-
}
141-
142132
internal void Log(string message)
143133
{
144134
if (TestFlightManagerScenario.Instance == null || TestFlightManagerScenario.Instance.userSettings == null)
@@ -196,19 +186,6 @@ IEnumerator ConnectToScenario()
196186

197187
internal override void Update()
198188
{
199-
if (tfScenario == null || !tfScenario.SettingsEnabled)
200-
return;
201-
202-
if (locked)
203-
return;
204-
205-
Part selectedPart = EditorLogic.SelectedPart;
206-
207-
if (selectedPart == null)
208-
selectedPart = EditorLogic.fetch.ship.parts.Find(p => p.stackIcon.Highlighted);
209-
210-
if (selectedPart != null)
211-
SelectedPart = selectedPart;
212189
}
213190

214191
internal void Startup()

0 commit comments

Comments
 (0)