Fix softlock in shiftorium gui boot

This commit is contained in:
Michael 2017-07-02 08:34:17 -04:00
parent 1e5a7ea9b3
commit 01c347c562
3 changed files with 2 additions and 4 deletions

View file

@ -109,7 +109,6 @@ namespace ShiftOS.WinForms.Applications
});
t.Start();
}
while (numComplete < cats.Length) { } // wait for all threads to finish their job
}
private void SetList()

View file

@ -248,9 +248,7 @@ namespace ShiftOS.Engine
var upg = Shiftorium.GetAvailable().FirstOrDefault(x => x.ID == upgrade);
if(upg != null)
{
if (Shiftorium.Buy(upg.ID, upg.Cost) == true)
Console.WriteLine("{RES_UPGRADEINSTALLED}");
else
if (!Shiftorium.Buy(upg.ID, upg.Cost) == true)
Console.WriteLine("{ERR_NOTENOUGHCODEPOINTS}");
}
else

View file

@ -82,6 +82,7 @@ namespace ShiftOS.Engine
public void Complete()
{
Thread.Sleep(20);
onComplete?.Invoke();
}
}