Skip to content

Commit

Permalink
removing log lines and useless GC.collect()
Browse files Browse the repository at this point in the history
  • Loading branch information
chacha committed Apr 24, 2024
1 parent 5a65e3c commit e1801b2
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions OpenRA.Game/Map/MapCache.cs
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ public void LoadMaps()
foreach (var map in kv.Key.Contents)
{
LoadMapInternal(map, kv.Key, kv.Value, mapGrid, null, modDataRules);
GC.Collect();
}
}

Expand All @@ -151,8 +150,6 @@ void LoadMapInternal(string map, IReadOnlyPackage package, MapClassification cla
using (new PerfTimer(map))
{
mapPackage = package.OpenPackage(map, modData.ModFiles);
Log.Write("debug", $"Loading Map: {map} FROM {mapPackage.Name}");
Console.WriteLine($"Loading Map: {map} FROM {mapPackage.Name}");
if (mapPackage != null)
{
var uid = Map.ComputeUID(mapPackage);
Expand All @@ -175,14 +172,10 @@ void LoadMapInternal(string map, IReadOnlyPackage package, MapClassification cla
mapPackage?.Dispose();
Console.WriteLine($"Failed to load map: {map}");
Console.WriteLine("Details:");
Console.WriteLine(e);
Console.WriteLine("StackTrace:");
Console.WriteLine(System.Environment.StackTrace);
Log.Write("debug", $"Failed to load map: {map}");
Log.Write("debug", "Details:");
Log.Write("debug", e);
Log.Write("debug", "StackTrace:");
Log.Write("debug", System.Environment.StackTrace);
}
}

Expand Down

0 comments on commit e1801b2

Please sign in to comment.