Add ability to disable the shellmap

This commit is contained in:
Tirili
2011-10-23 13:13:43 +13:00
committed by Chris Forbes
parent 6174ccc882
commit 4f505eb6a1
7 changed files with 30 additions and 6 deletions

View File

@@ -205,13 +205,13 @@ namespace OpenRA
}
public static event Action BeforeGameStart = () => {};
internal static void StartGame(string mapUID)
internal static void StartGame(string mapUID, bool isShellmap)
{
BeforeGameStart();
var map = modData.PrepareMap(mapUID);
viewport = new Viewport(new int2(Renderer.Resolution), map.Bounds, Renderer);
orderManager.world = new World(modData.Manifest, map, orderManager);
orderManager.world = new World(modData.Manifest, map, orderManager) { IsShellmap = isShellmap };
worldRenderer = new WorldRenderer(orderManager.world);
if (orderManager.GameStarted) return;
@@ -306,7 +306,7 @@ namespace OpenRA
public static void LoadShellMap()
{
StartGame(ChooseShellmap());
StartGame(ChooseShellmap(), true);
}
static string ChooseShellmap()