mirror of
https://github.com/pret/pmd-sky.git
synced 2026-10-01 14:48:14 -05:00
Decompile from asm: SetCollectionMenuField0x1BC 0x0202C5E0 SetCollectionMenuField0x1C8 0x0202C794 SetCollectionMenuField0x1A0 0x0202C7A8 SetCollectionMenuField0x1A4 0x0202C7BC SetCollectionMenuVoidFn 0x0202C7D0 SetCollectionMenuField0x1B2 0x0202D0D8 These reach the same buffer as the parent, simple and advanced menu accessors, through the same GetWindowContents, but they do not share its layout: this set writes a word at 0x1A0 where CheckParentMenuField0x1A0 reads a byte there, and a byte at 0x1B2 which falls inside the word the advanced text box uses at 0x1B0. So they are given their own view, struct unk_0202C5E0, named for the lowest-addressed function that takes it, rather than forcing one struct to describe both. GetWindowContents returns void *, so each menu type casting the buffer to its own layout is consistent with what the target does; a single merged struct would have to assert that the two layouts agree, which the stores show they do not. Two of the offsets are inferred from the store width alone and nothing else: 0x1A8 is written with a word and the function is named VoidFn, so it is typed void *, but the target would look the same for any pointer or 32-bit value. No comments are added to any pmd-sky file. Authored by Claude (Opus 5) under human direction. Confirmed by a matching build: build/pmdsky.us/pmdsky.us.nds: OK. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
10 lines
305 B
C
10 lines
305 B
C
#ifndef PMDSKY_MAIN_0202C794_H
|
|
#define PMDSKY_MAIN_0202C794_H
|
|
|
|
void SetCollectionMenuField0x1C8(s32 window_id, u8 value);
|
|
void SetCollectionMenuField0x1A0(s32 window_id, s32 value);
|
|
void SetCollectionMenuField0x1A4(s32 window_id, s32 value);
|
|
void SetCollectionMenuVoidFn(s32 window_id, void* fn);
|
|
|
|
#endif
|