Add more perf measurements
This commit is contained in:
@@ -251,8 +251,11 @@ namespace OpenRA
|
|||||||
{
|
{
|
||||||
map = modData.PrepareMap(mapUID);
|
map = modData.PrepareMap(mapUID);
|
||||||
}
|
}
|
||||||
orderManager.world = new World(modData.Manifest, map, orderManager, isShellmap);
|
using (new PerfTimer("NewWorld"))
|
||||||
orderManager.world.Timestep = Timestep;
|
{
|
||||||
|
orderManager.world = new World(modData.Manifest, map, orderManager, isShellmap);
|
||||||
|
orderManager.world.Timestep = Timestep;
|
||||||
|
}
|
||||||
worldRenderer = new WorldRenderer(orderManager.world);
|
worldRenderer = new WorldRenderer(orderManager.world);
|
||||||
using (new PerfTimer("LoadComplete"))
|
using (new PerfTimer("LoadComplete"))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -47,9 +47,12 @@ namespace OpenRA
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var map = new Map(path, manifest.Mod.Id);
|
using (new Support.PerfTimer(path))
|
||||||
if (manifest.MapCompatibility.Contains(map.RequiresMod))
|
{
|
||||||
previews[map.Uid].UpdateFromMap(map);
|
var map = new Map(path, manifest.Mod.Id);
|
||||||
|
if (manifest.MapCompatibility.Contains(map.RequiresMod))
|
||||||
|
previews[map.Uid].UpdateFromMap(map);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -148,7 +148,10 @@ namespace OpenRA
|
|||||||
public void LoadComplete(WorldRenderer wr)
|
public void LoadComplete(WorldRenderer wr)
|
||||||
{
|
{
|
||||||
foreach (var wlh in WorldActor.TraitsImplementing<IWorldLoaded>())
|
foreach (var wlh in WorldActor.TraitsImplementing<IWorldLoaded>())
|
||||||
wlh.WorldLoaded(this, wr);
|
{
|
||||||
|
using (new Support.PerfTimer(wlh.GetType().Name + ".WorldLoaded"))
|
||||||
|
wlh.WorldLoaded(this, wr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public Actor CreateActor(string name, TypeDictionary initDict)
|
public Actor CreateActor(string name, TypeDictionary initDict)
|
||||||
|
|||||||
Reference in New Issue
Block a user