Curation round 2, wave A: anm2 (Anm2Ed JSON), text, config as idiomatic classes; SDL3 platform opens a window

- anm2.h/.cpp take over ANM2, AnimationState, LayerState, AnmCache and the frame data. They read Anm2Ed's JSON documents
  with simdjson and play them as the game does (interpolation baked at load). src/anm2/ and msvc.h are retired.
- font, formatted_text, string_table and rich_text take over the text classes. FormattedText::parse is still bit-exact
  against its assembly.
- options_config and challenge_params take over OptionsConfig, ChallengeParams and the .ini helpers. The tests include
  Save's exact bytes.
- platform.h/.cpp and main.cpp run IsaacMain on SDL3: the window and GL context open, and the run stops at the first
  built-in shader (FUN_00a13fa0).
- source_tree.py: a taken-over parent stays bytes, taken-over methods are not re-emitted as a namespace, and every
  address in a (a, b, c to d) list on a comment counts as taken over.
- log.h: reconstruction_missing() for a taken-over class's methods that are not written yet.
206 functions taken over, boot path 89/615. The full build waits for wave B: item_config, entity_config and mod_manager
still use the old APIs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
shweetandClaude Opus 5.5 committed 2026-11-19 23:04:54 -05:00
1 parent d6e1ca7c6c
commit 780767f5e1
161 files changed
+8646 -21919

No files matched your search

+20 -20
View File
@@ -174,9 +174,9 @@ NetplayManager::~NetplayManager()
local_8 = 1;
NetplayTextPopup::clear();
local_8 = CONCAT31((*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(local_8)) + 0x1))),2);
(GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))))))->ANM2::Reset();
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>((this + 0x5ac)))))->AnimationState::~AnimationState();
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x5a1])) + 0x1)))))))->AnimationState::~AnimationState();
ANM2::Reset(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))));
AnimationState::~AnimationState(GHIDRA_CAST<AnimationState *>((this + 0x5ac)));
AnimationState::~AnimationState(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x5a1])) + 0x1)))));
(GHIDRA_CAST<msvc::string *>((&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x599])) + 0x1))))))->msvc::string::_Tidy_deallocate();
(GHIDRA_CAST<msvc::string *>((&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1))))))->msvc::string::_Tidy_deallocate();
msvc::deque<36byte>::_Tidy();
@@ -263,7 +263,7 @@ void NetplayManager::Init()
local_40._capacity = 0x1f;
builtin_strncpy((*GHIDRA_CAST<uint32_t *>((GHIDRA_CAST<char *>(&(GHIDRA_CAST<char *>(local_40._buf))) + 0x0))),"gfx/ui/ui_streak.anm2",0x16);
local_14 = 0;
(GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))))))->ANM2::Load(&local_40,1);
ANM2::Load(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))),&local_40,1);
local_14 = 0xffffffff;
if (0xf < local_40._capacity) {
size = local_40._capacity + 1;
@@ -278,7 +278,7 @@ void NetplayManager::Init()
}
operator_delete(strBuf,size);
}
paperLayer = (GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))))))->ANM2::GetLayer(GHIDRA_CAST<uint8_t *>("paper"));
paperLayer = ANM2::GetLayer(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x591])) + 0x1)))),GHIDRA_CAST<uint8_t *>("paper"));
paperLayer->_visible = 0;
msvc::list<msvc::pair<int_int>>::push_back();
msvc::list<msvc::pair<int_int>>::push_back();
@@ -415,7 +415,7 @@ void NetplayManager::Init()
local_14 = CONCAT31((*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(local_14)) + 0x1))),3);
*GHIDRA_CAST<uint32_t *>((pNVar1 + 0x61c)) = *extraout_EAX_00;
*GHIDRA_CAST<uint32_t *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(pNVar1[0x61e])) + 0x2)))) = extraout_EAX_00[2];
(GHIDRA_CAST<FormattedText *>((pNVar1 + 0x620)))->FormattedText::operator_assign(extraout_EAX_00 + 3);
FormattedText::operator_assign(pNVar1 + 0x620,extraout_EAX_00 + 3);
*GHIDRA_CAST<uint32_t *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(pNVar1[0x625])) + 0x1)))) = extraout_EAX_00[7];
*GHIDRA_CAST<uint32_t *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(pNVar1[0x626])) + 0x2)))) = extraout_EAX_00[8];
*GHIDRA_CAST<uint32_t *>((pNVar1 + 0x628)) = extraout_EAX_00[9];
@@ -1569,10 +1569,10 @@ uint8_t NetplayManager::Update()
puVar2 = received + 0x34;
if ((*GHIDRA_CAST<int *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x85d])) + 0x1)))) != 0) &&
(puVar2 = received + 0x34, (*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x862])) + 0x2))) != '\0')) {
(GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>((this + 0x84c)))))->ANM2::update_appear_then_idle();
ANM2::update_appear_then_idle(GHIDRA_CAST<ANM2 *>((this + 0x84c)));
if (*GHIDRA_CAST<char *>((this + 0x90b)) != '\0') {
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x8c2])) + 0x2)))))))->AnimationState::Update();
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x8cd])) + 0x1)))))))->AnimationState::Update();
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x8c2])) + 0x2)))));
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x8cd])) + 0x1)))));
}
local_2c = GHIDRA_CAST<int *>(&DAT_0000000f);
cVar3 = (**(code **)(PTR_vftable_00c57b18 + 0x74))(0xffffffff,FUN_00a209e0,&local_2c);
@@ -1888,7 +1888,7 @@ void NetplayManager::Render()
if (0xf < *GHIDRA_CAST<uint32_t *>((str + 0x14))) {
str = *GHIDRA_CAST<uint8_t **>(str);
}
(GHIDRA_CAST<Font *>((&manager->_font2_TeamMeatEx12)))->Font::DrawString(str,&drawPos,GHIDRA_CAST<Vector *>((centerNull + 4)),&white,
Font::DrawString(&manager->_font2_TeamMeatEx12,str,&drawPos,GHIDRA_CAST<Vector *>((centerNull + 4)),&white,
&drawParams);
}
local_8 = 0xffffffff;
@@ -1903,7 +1903,7 @@ void NetplayManager::Render()
if (isActive != '\0') {
drawPos.x = (g_screenWidth - 480.0) * 0.5 + 240.0;
drawPos.y = (g_screenHeight - 270.0) * 0.5 + 150.0;
(GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(topAnimState[0x8b2])) + 0x2)))))))->ANM2::Render(&drawPos,&g_vectorZero,&g_vectorZero);
ANM2::Render(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(topAnimState[0x8b2])) + 0x2)))),&drawPos,&g_vectorZero,&g_vectorZero);
}
}
if ((*GHIDRA_CAST<int *>((topAnimState + 0x924)) != 0) && ((*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(topAnimState[0x929])) + 0x1))) != '\0')) {
@@ -4500,9 +4500,9 @@ LAB_00910e26:
currentAnimData = *GHIDRA_CAST<uint8_t **>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2834))));
if (currentAnimData == GHIDRA_CAST<uint8_t *>(0x0)) {
LAB_00910ee9:
bVar5 = (GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2800)))))))->ANM2::SetAnimation(GHIDRA_CAST<uint8_t *>(local_3c),1);
bVar5 = ANM2::SetAnimation(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2800)))),GHIDRA_CAST<uint8_t *>(local_3c),1);
if (bVar5 != 0) {
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2830)))))))->AnimationState::Rewind();
AnimationState::Rewind(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2830)))));
(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2844))) = 1;
}
}
@@ -4533,8 +4533,8 @@ LAB_00910ed5:
goto LAB_00910ee9;
}
if ((*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2909))) != '\0') {
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2830)))))))->AnimationState::Update();
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2850)))))))->AnimationState::Update();
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2830)))));
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>((player)) + 0x2850)))));
}
LAB_00910f7e:
uVar11 = uVar11 + 1;
@@ -7285,8 +7285,8 @@ void NetplayManager::update_text_popup()
local_8 = GHIDRA_CAST<std_string *>((__security_cookie ^ GHIDRA_UINT((GHIDRA_INT(&animName) + 0x1cU))));
bVar13 = false;
if (*GHIDRA_CAST<char *>((this + 0x5f)) != '\0') {
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))))))->AnimationState::Update();
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x21])) + 0x1)))))))->AnimationState::Update();
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))));
AnimationState::Update(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x21])) + 0x1)))));
}
if (*(void **)(this + 0x18) == (void *)0x0) {
(*GHIDRA_CAST<uint32_t *>((GHIDRA_CAST<char *>(&(animName._buf)) + 0x0))) = GHIDRA_CAST<std_string *>(0x0);
@@ -7440,7 +7440,7 @@ LAB_00923b55:
goto LAB_00923c61;
}
if ((*GHIDRA_CAST<int *>((this + 0x18)) == 0) || ((*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x1d])) + 0x1))) == '\0')) {
psVar7 = (GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))))))->ANM2::GetAnimation(&animName);
psVar7 = ANM2::GetAnimation(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))),&animName);
bVar13 = true;
puVar1 = &psVar7->_size;
if (0xf < psVar7->_capacity) {
@@ -7508,9 +7508,9 @@ LAB_00923c4c:
}
pcVar10 = "TextIn";
LAB_00923c61:
bVar5 = (GHIDRA_CAST<ANM2 *>((GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[6])) + 0x2)))))))->ANM2::SetAnimation(GHIDRA_CAST<uint8_t *>(pcVar10),1);
bVar5 = ANM2::SetAnimation(GHIDRA_CAST<ANM2 *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[6])) + 0x2)))),GHIDRA_CAST<uint8_t *>(pcVar10),1);
if (bVar5 != 0) {
(GHIDRA_CAST<AnimationState *>((GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))))))->AnimationState::Rewind();
AnimationState::Rewind(GHIDRA_CAST<AnimationState *>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x16])) + 0x2)))));
(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&(this[0x1d])) + 0x1))) = 1;
}
return;