Fixes for what the first 0.1.3 recording from a real game showed, a more honest estimate of what the mod itself costs, and one new opt-in setting. Still a preview, and none of this has been played yet; docs/TESTING.md lists what each change needs a recording to confirm. Nothing here changes what the game simulates.
Recording
- Beavers are one row again. A beaver loaded from a save was keyed by its own name (
BeaverAdult Malak), one born during play byBeaverAdult(Clone), so beavers showed as 14% of entity time instead of 85%. Entities are now keyed by kind. (#1) overheadUscounts what the per-call patches really cost.patchCallNsis now the real entity patch bodies (newpatchBodyNsin the# calibration|line) plus Harmony's cost; up to 0.1.3 it timed an empty patch and read 0 in every recording. (#2)Watchmethods are sampled at their own rate, sharing the watched methods' budget, so one busy method no longer leaves the rest timed on 1 call in 30. Windows nobody timed are written withsampled0, not counted as 0 ms. (#2)- Frames with a garbage collection are counted as "allocation not measured" (new
# capability-final|allocSource|line) and left out of allocation-per-second, instead of read as 0 KB. (#3) - New:
AutoWatch(PerformanceLog.cfgonly, off by default) times other mods' prefixes/postfixes/finalizers on the game's hot methods in the free Watch slots (40 in all), leaving out patches on the random numbers,GuidandDateTime. It patches once, when the first game loads, and restores the game's random state afterwards for BeaverBuddies co-op. Keep it off in co-op until it has been played with two players. (#5)
summary.md and perflog.py
- Slow frames are blamed on a singleton only if it took 10% of the frame or 5 ms; otherwise it says none stood out and whether the frame had a save or a collection. (#3)
otherMsis split by Unity phase (Update, LateUpdate,plPost, the phases before Update, between phases), and the "not the game's code" finding points at scripts or at the graphics card accordingly. (#3)reportnames the other mods whose patches run inside a singleton's time;comparelists patches only one session has. (#3)- Older recordings: entity rows are added up by kind so
comparelines 0.1.3 and 0.1.4 up, and aKNOWN ISSUEis printed when a recording's rows are split or itsoverheadUsunderstated the patches. (#1, #2)
Full list: CHANGELOG.md.
Install
- Close Timberborn. Extract
PerformanceLog-0.1.4.zipintoDocuments\Timberborn\Mods, replacing your existing install. - Still requires Harmony (2.4.1+) and Mod Settings (1.1.0.0+) from the Steam Workshop.
- Enable Performance Log in the mod manager and restart.
Verified before release
113 checks of the mod (against the game's real assemblies) and 65 checks of the analysis tool, all passing. Each fix has a check that fails without it.
SHA-256 of PerformanceLog-0.1.4.zip: 70CB7791F9BA4FCC64A69D010CFA8C4AC52D483CB230507AC687780A4CEF1F0C