Files
Cesarus85--mjolnir-vr/source
Jonas VolmanandClaude Opus 5 884f9db1e1 Close unit_animation_set_state with a graph-index carrier local
Route the three animation_choose_random_permutation_internal call sites
through a long animation_graph_index local, matching the byte-exact
unit_start_animation_impulse idiom at units.c:8535 and units.c:3245.
unit_animation_set_state was the file's only site that inlined the field
expression into the call.

That flips one allocator decision: January spends EDI on the unit_seat
pointer (mov edi,eax / lea eax,[edi+0x58] / mov [ebp-0x1c],edi, then
direct mov ecx,[edi+0x40] and [edi+0x44] later) and homes animation_index
at [ebp-0xc); we did the reverse and reloaded the pointer at every use.
The frame going 0x18 -> 0x1c and all three or edx,0ffffffffh sites were
consequences, not separate differences.

units.obj code census 186/3/0 -> 187/2/0; data unchanged at 129/0/0.

Also reproduce January's setcc spelling in unit_update_animation: split
the shared alert/suspicious case arm and write the in_combat arm with no
byte-typed intermediate. setcc r8 ; movzx r16,r8 occurs zero times in all
9352 January functions; the new shape emits January's
xor ebx,ebx / test cl,cl / setne bl / add ebx,2 and matches January's
relocation layout exactly (relocation_infos_equal was False, now True).
Still non-exact: 23 bytes, all register choices.

CL /Zs /W3 unchanged at 43 diagnostics with identical codes.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-28 21:17:04 -07:00
..
2026-08-28 14:30:41 -07:00
2026-08-21 03:48:32 -07:00
2026-08-26 12:30:04 -07:00
2026-08-28 09:57:47 -07:00
2026-08-27 02:55:03 -07:00
2026-06-08 02:44:47 +01:00
2025-11-28 00:16:20 +00:00
2026-08-27 18:10:20 -07:00
2026-08-28 14:39:34 -07:00
2026-08-13 05:20:30 -07:00
2026-07-14 21:25:03 -07:00
2026-08-28 15:17:13 -07:00
2026-08-26 02:52:49 -07:00
2026-06-08 02:47:21 +01:00