Repository navigation
Description
Context
AntHill (test/AntHill/) is the ant-colony simulation that exercises the Typhon engine, rendered with Godot. Today it is one Godot project (AntHill.csproj) plus a no-Godot console runner (profiling/AntHill.ProfileRunner.csproj) that compiles the sim code via <Compile Include> globs — a fragile seam that duplicates the source set instead of consuming a real library.
A feasibility assessment confirmed the Godot coupling is already cleanly separated: Engine/ECS/AI/Pheromone (24 files) are Godot-free; Scripts/ (13 files) is all-Godot; only HeightmapResource straddles, and it is already a .cs + .Godot.cs partial.
Goal — split AntHill into three projects under a new demo/AntHill/ root
AntHill.Core— class library: all gameplay + Typhon-engine code, zero Godot dependency.AntHill.Demo— the Godot application; consumesAntHill.Core, owns rendering/UI.AntHill.Harness— console app; consumesAntHill.Corefor profiling / regression / validation runs. SupersedesAntHill.ProfileRunner.
This is Phase A — the structural split only. AntHill.Harness ships as today's profiler runner re-homed onto the library. Growing it into a general scriptable validation harness is Phase B — tracked separately.
Acceptance Criteria
- AC1 — new layout
demo/AntHill/{AntHill.Core,AntHill.Demo,AntHill.Harness}/;test/AntHill/removed;git mvpreserves history. - AC2 —
AntHill.Core—Microsoft.NET.Sdkclass library,net10.0,AllowUnsafeBlocks,RootNamespace=AntHill, assemblyAntHill.Core; containsEngine/(sim),ECS/,AI/,Pheromone/,GlobalUsings.cs; referencesTyphon.Engine+ analyzers + generators; no Godot reference. - AC3 —
HeightmapResourcebecomes a non-partialpublic sealed classinAntHill.Core(public ctor); the Godot generation/export half becomesHeightmapFactoryinAntHill.Demo. - AC4 —
AntHill.Demo—Godot.NET.Sdkapp, assemblyAntHill.Demo,project.godotassembly_name="AntHill.Demo";Scripts/,Scenes/,HeightmapFactory.cs;ProjectReference→AntHill.Core; compiles. - AC5 —
AntHill.Harness—Microsoft.NET.SdkExe, assemblyAntHill.Harness;Program.csfromAntHill.ProfileRunner;ProjectReference→AntHill.Corereplaces the<Compile Include>globs; builds + runs. - AC6 —
Typhon.EngineInternalsVisibleToupdated to the three new assemblies;Typhon.slnxupdated. - AC7 —
dotnet build Typhon.slnxclean;AntHill.Harness --traceruns end-to-end; fullTyphon.Engine.Testssuite green.
Related
- Phase B follow-up: AntHill.Harness scriptable validation harness — see the linked issue.
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
nockawa commentedon May 16, 2026
Phase A — three-project split — complete ✅
All acceptance criteria met. AntHill is now three projects under
demo/AntHill/.Layout
demo/AntHill/AntHill.Core/—Microsoft.NET.Sdkclass library, assemblyAntHill.Core. All gameplay + Typhon-engine code (Engine/,ECS/,AI/,Pheromone/,GlobalUsings.cs). Zero Godot reference. GrantsInternalsVisibleTotoAntHill.Demo/AntHill.Harness(they were one assembly before the split).demo/AntHill/AntHill.Demo/—Godot.NET.Sdk/4.6.2app, assemblyAntHill.Demo.Scripts/,Scenes/,project.godot(assembly_name="AntHill.Demo"),HeightmapFactory.cs.ProjectReference→AntHill.Core.demo/AntHill/AntHill.Harness/—Microsoft.NET.SdkExe, assemblyAntHill.Harness.Program.csfromAntHill.ProfileRunner(nownamespace AntHill.Harness).ProjectReference→AntHill.Corereplaces the old<Compile Include>globs. SupersedesAntHill.ProfileRunner.Key changes
HeightmapResource— was a cross-filepartial; now a non-partialpublic sealed classinAntHill.Corewith apublicconstructor. The Godot generation/export half isHeightmapFactory(static class) inAntHill.Demo. Callers inMain.cs/Terrain.csupdated.Typhon.EngineInternalsVisibleTo—AntHill/AntHill.ProfileRunner→AntHill.Core/AntHill.Demo.Typhon.slnx— new/demo/folder with the three projects; the oldtest/AntHill/AntHill.csprojentry removed.git mv(history preserved — 60 renames); staleAntHill.sln/.DotSettingsand Godot.uidcruft from the non-Godot projects dropped.Verified
dotnet build Typhon.slnx -c Debug— clean, 0 errors (incl.AntHill.DemoviaGodot.NET.Sdkfrom NuGet).AntHill.Harness --trace … --duration 4with CPU sampling — completes with zero exceptions, headerCpuSampleSectionOffset != 0,.nettracedeleted (the CPU Sampling Integration — in-process EventPipe capture + Call Tree view #351 CPU-sampling path works through the new library).Typhon.Engine.Testssuite — green, 3703 passed / 34 skipped.Phase B (#353) — growing
AntHill.Harnessinto a scriptable validation harness — builds on this.Ready for review + commit (not committed — per convention).
CPU Sampling Integration (#351) + AntHill refactoring (#352) (#355)
nockawa commentedon May 18, 2026
Completed in PR #355 (commit
a179e51— "CPU Sampling Integration (#351) + AntHill refactoring (#352)"). The issue was left open because #355 didn't use a closing keyword for #352.Verified against the acceptance criteria:
demo/AntHill/{AntHill.Core, AntHill.Demo, AntHill.Harness}all present with their.csprojfiles;test/AntHill/no longer holds tracked content.Typhon.slnxreferences all three new projects.main(CI green).Closing as done. Phase B follow-up tracked in #353.