Change BuildHierarchy type signature

This commit is contained in:
Jarrod Doyle 2024-08-26 15:24:07 +01:00
parent d3e58af75c
commit 9605c36303
Signed by: Jayrude
GPG Key ID: 38B57B16E7C0ADF7
1 changed files with 3 additions and 3 deletions

View File

@ -66,7 +66,7 @@ public partial class Mission : Node3D
{ {
if (Build) if (Build)
{ {
RebuildMap(); Timing.TimeStage("Build", () => RebuildMap());
Build = false; Build = false;
} }
if (Clear) if (Clear)
@ -106,13 +106,13 @@ public partial class Mission : Node3D
if (_file.Chunks.TryGetValue("BRLIST", out var brList)) if (_file.Chunks.TryGetValue("BRLIST", out var brList))
{ {
var objHierarchy = Timing.TimeStage("Hierarchy", () => BuildHierarchy(_file)); var objHierarchy = Timing.TimeStage("Hierarchy", BuildHierarchy);
Timing.TimeStage("Object Placement", () => PlaceObjects((BrList)brList, objHierarchy)); Timing.TimeStage("Object Placement", () => PlaceObjects((BrList)brList, objHierarchy));
} }
} }
// TODO: Make this less of a mess // TODO: Make this less of a mess
private ObjectHierarchy BuildHierarchy(DbFile db) private ObjectHierarchy BuildHierarchy()
{ {
ObjectHierarchy objHierarchy; ObjectHierarchy objHierarchy;
if (_file.Chunks.TryGetValue("GAM_FILE", out var gamFileChunk)) if (_file.Chunks.TryGetValue("GAM_FILE", out var gamFileChunk))