strip 'locate game root' crap from game & editor; chrono both CAs

This commit is contained in:
Chris Forbes
2010-05-27 21:13:35 +12:00
parent ce9f7666b4
commit a399e0b682
3 changed files with 6 additions and 22 deletions

View File

@@ -37,7 +37,6 @@ namespace OpenRA.Editor
{
InitializeComponent();
AppDomain.CurrentDomain.AssemblyResolve += FileSystem.ResolveAssembly;
LocateGameRoot();
currentMod = mods.FirstOrDefault() ?? "ra";
@@ -213,17 +212,6 @@ namespace OpenRA.Editor
foreach (var p in palettes) { p.Visible = true; p.ResumeLayout(); }
}
void LocateGameRoot()
{
while (!Directory.Exists("mods"))
{
var current = Directory.GetCurrentDirectory();
if (Directory.GetDirectoryRoot(current) == current)
throw new InvalidOperationException("Unable to find game root.");
Directory.SetCurrentDirectory("..");
}
}
static Bitmap RenderTemplate(TileSet ts, ushort n, Palette p)
{
var template = ts.walk[n];

View File

@@ -532,13 +532,6 @@ namespace OpenRA
internal static void Initialize(Settings settings)
{
AppDomain.CurrentDomain.AssemblyResolve += FileSystem.ResolveAssembly;
while (!Directory.Exists("mods"))
{
var current = Directory.GetCurrentDirectory();
if (Directory.GetDirectoryRoot(current) == current)
throw new InvalidOperationException("Unable to find game root.");
Directory.SetCurrentDirectory("..");
}
LoadUserSettings(settings);
LobbyInfo.GlobalSettings.Mods = Settings.InitialMods;

View File

@@ -55,7 +55,10 @@ namespace OpenRA.Mods.RA
public void Tick(Actor self)
{
if (ticks == 250)
{
MapActors["pdox"].traits.Get<Chronosphere>().Teleport(MapActors["ca1"], new int2(90, 70));
MapActors["pdox"].traits.Get<Chronosphere>().Teleport(MapActors["ca2"], new int2(92, 71));
}
if (ticks == 100)
MapActors["mslo1"].traits.Get<NukeSilo>().Attack(new int2(96,53));
if (ticks == 110)