Name generic parameters of dialog string, DC6 draw, skill text, party and SID functions
Ghidra v1805 · 8293ab3
Each name comes from the instruction that stores or forwards the value. AddStringData's are the pDialog->aStringData fields they fill. IMAGE_DrawDC6ImageOnScreen branches 1 to center and 2 to right-align. SKILLDESC_DrawTwoLineText's reach UI_DrawTextCentered's end X and color. UI_CloseTradeWindow toggles UI_INVENTORY after closing when ECX is nonzero. SendPlayerEvent's is the 0x5A kind 7 party code, confirmed by a live lan capture in the repo that holds my packet captures: byte [7] picks the text and the sender picks the color from it. SendRelationshipStatus sets or clears dwFlagMask's bits. NET_SID_CLIENT_GetRequiredAnswer indexes the same table by the same value as its siblings. Least proven: that last one, which rests on those siblings. Left out: NET_D2GS_CLIENT_Send_INT (26 callers with different opcodes), FORMS_SetGlobalFormImage (31 callers, only one read).
Changes 12, applied together
Rename variable
win 0x004b85f0 Stack[0xc]namenParam1→nLineTypeRename variable
win 0x004b85f0 Stack[0x10]namenParam→nFontRename variable
win 0x004b85f0 Stack[0x14]namenParam2→pfnOnClickRename variable
win 0x004b85f0 Stack[0x18]namenParam3→nCallbackParamRename variable
win 0x00502680 Stack[0x8]namenParam→nAlignmentRename variable
win 0x004e9870 Stack[0xc]namenParam1→nXRightRename variable
win 0x004e9870 Stack[0x10]namenParam2→dwColor1Rename variable
win 0x004e9870 Stack[0x14]namenParam3→dwColor2Rename variable
win 0x004b8940 ECXnamenParam→bToggleInventoryRename variable
win 0x005a5690 Stack[0x8]namebParam→nPartyEventCodeRename variable
win 0x0055b260 Stack[0xc]namenParam→bSetRename variable
win 0x00520bf0 CLnamebParam→nPacketId