added (broken) content installer, moved instruction to GUI

still depends on the hacky bash script and CD extractor crashes
This commit is contained in:
Matthias Mailänder
2012-06-02 17:46:31 +02:00
parent 9b1e798b35
commit accaf027fe
7 changed files with 221 additions and 65 deletions

View File

@@ -37,7 +37,7 @@ namespace OpenRA.Mods.D2k
// can display loadscreen as early as possible
r = Game.Renderer;
if (r == null) return;
var s = new Sheet(Path.Combine(Path.Combine(Path.Combine("mods", "d2k"), "uibits"), "loadscreen.png"));
var s = new Sheet("mods/d2k/uibits/loadscreen.png");
Logo = new Sprite(s, new Rectangle(0,0,256,256), TextureChannel.Alpha);
Stripe = new Sprite(s, new Rectangle(256,0,256,256), TextureChannel.Alpha);
StripeRect = new Rectangle(0, Renderer.Resolution.Height/2 - 128, Renderer.Resolution.Width, 256);
@@ -73,9 +73,21 @@ namespace OpenRA.Mods.D2k
void TestAndContinue()
{
Ui.ResetAll();
Game.LoadShellMap();
Ui.ResetAll();
Ui.OpenWindow("MAINMENU_BG");
if (!FileSystem.Exists(Info["TestFile"]))
{
var args = new WidgetArgs()
{
{ "continueLoading", () => TestAndContinue() },
{ "installData", Info }
};
Ui.OpenWindow(Info["InstallerMenuWidget"], args);
}
else
{
Game.LoadShellMap();
Ui.ResetAll();
Ui.OpenWindow("MAINMENU_BG");
}
}
}
}