diff --git a/asm/43U/layout/GUIManager.s b/asm/43U/layout/GUIManager.s new file mode 100644 index 00000000..f7aa7bc4 --- /dev/null +++ b/asm/43U/layout/GUIManager.s @@ -0,0 +1,1581 @@ +.include "macros.inc" +.file "GUIManager.cpp" + +# 0x81368918..0x81369ABC | size: 0x11A4 +.text +.balign 4 + +# .text:0x0 | 0x81368918 | size: 0x2C0 +# gui::Component::update(int, float, float, unsigned long, unsigned long, unsigned long, void*) +.fn update__Q23gui9ComponentFiffUlUlUlPv, global +/* 81368918 00036D18 94 21 FF C0 */ stwu r1, -0x40(r1) +/* 8136891C 00036D1C 7C 08 02 A6 */ mflr r0 +/* 81368920 00036D20 90 01 00 44 */ stw r0, 0x44(r1) +/* 81368924 00036D24 DB E1 00 30 */ stfd f31, 0x30(r1) +/* 81368928 00036D28 F3 E1 00 38 */ psq_st f31, 0x38(r1), 0, qr0 +/* 8136892C 00036D2C DB C1 00 20 */ stfd f30, 0x20(r1) +/* 81368930 00036D30 F3 C1 00 28 */ psq_st f30, 0x28(r1), 0, qr0 +/* 81368934 00036D34 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368938 00036D38 48 29 0B 85 */ bl _savegpr_26 +/* 8136893C 00036D3C 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368940 00036D40 FF C0 08 90 */ fmr f30, f1 +/* 81368944 00036D44 FF E0 10 90 */ fmr f31, f2 +/* 81368948 00036D48 7C 7A 1B 78 */ mr r26, r3 +/* 8136894C 00036D4C 81 8C 00 5C */ lwz r12, 0x5c(r12) +/* 81368950 00036D50 7C 9B 23 78 */ mr r27, r4 +/* 81368954 00036D54 7C DC 33 78 */ mr r28, r6 +/* 81368958 00036D58 7D 1D 43 78 */ mr r29, r8 +/* 8136895C 00036D5C 3B C0 00 00 */ li r30, 0x0 +/* 81368960 00036D60 7D 89 03 A6 */ mtctr r12 +/* 81368964 00036D64 4E 80 04 21 */ bctrl +/* 81368968 00036D68 2C 03 00 00 */ cmpwi r3, 0x0 +/* 8136896C 00036D6C 41 82 02 20 */ beq .L_81368B8C +/* 81368970 00036D70 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368974 00036D74 FC 20 F0 90 */ fmr f1, f30 +/* 81368978 00036D78 FC 40 F8 90 */ fmr f2, f31 +/* 8136897C 00036D7C 7F 43 D3 78 */ mr r3, r26 +/* 81368980 00036D80 81 8C 00 68 */ lwz r12, 0x68(r12) +/* 81368984 00036D84 7D 89 03 A6 */ mtctr r12 +/* 81368988 00036D88 4E 80 04 21 */ bctrl +/* 8136898C 00036D8C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368990 00036D90 41 82 00 F4 */ beq .L_81368A84 +/* 81368994 00036D94 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368998 00036D98 7F 43 D3 78 */ mr r3, r26 +/* 8136899C 00036D9C 7F 64 DB 78 */ mr r4, r27 +/* 813689A0 00036DA0 81 8C 00 24 */ lwz r12, 0x24(r12) +/* 813689A4 00036DA4 7D 89 03 A6 */ mtctr r12 +/* 813689A8 00036DA8 4E 80 04 21 */ bctrl +/* 813689AC 00036DAC 2C 03 00 00 */ cmpwi r3, 0x0 +/* 813689B0 00036DB0 41 82 00 60 */ beq .L_81368A10 +/* 813689B4 00036DB4 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 813689B8 00036DB8 FC 20 F0 90 */ fmr f1, f30 +/* 813689BC 00036DBC FC 40 F8 90 */ fmr f2, f31 +/* 813689C0 00036DC0 7F 43 D3 78 */ mr r3, r26 +/* 813689C4 00036DC4 81 8C 00 3C */ lwz r12, 0x3c(r12) +/* 813689C8 00036DC8 7F 64 DB 78 */ mr r4, r27 +/* 813689CC 00036DCC 7D 89 03 A6 */ mtctr r12 +/* 813689D0 00036DD0 4E 80 04 21 */ bctrl +/* 813689D4 00036DD4 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 813689D8 00036DD8 7F 43 D3 78 */ mr r3, r26 +/* 813689DC 00036DDC 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 813689E0 00036DE0 7D 89 03 A6 */ mtctr r12 +/* 813689E4 00036DE4 4E 80 04 21 */ bctrl +/* 813689E8 00036DE8 7C 64 1B 78 */ mr r4, r3 +/* 813689EC 00036DEC 80 7A 00 80 */ lwz r3, 0x80(r26) +/* 813689F0 00036DF0 7F 66 DB 78 */ mr r6, r27 +/* 813689F4 00036DF4 7F A7 EB 78 */ mr r7, r29 +/* 813689F8 00036DF8 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813689FC 00036DFC 38 A0 00 03 */ li r5, 0x3 +/* 81368A00 00036E00 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368A04 00036E04 7D 89 03 A6 */ mtctr r12 +/* 81368A08 00036E08 4E 80 04 21 */ bctrl +/* 81368A0C 00036E0C 48 00 00 70 */ b .L_81368A7C +.L_81368A10: +/* 81368A10 00036E10 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368A14 00036E14 7F 43 D3 78 */ mr r3, r26 +/* 81368A18 00036E18 7F 64 DB 78 */ mr r4, r27 +/* 81368A1C 00036E1C 38 A0 00 01 */ li r5, 0x1 +/* 81368A20 00036E20 81 8C 00 2C */ lwz r12, 0x2c(r12) +/* 81368A24 00036E24 7D 89 03 A6 */ mtctr r12 +/* 81368A28 00036E28 4E 80 04 21 */ bctrl +/* 81368A2C 00036E2C 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368A30 00036E30 7F 43 D3 78 */ mr r3, r26 +/* 81368A34 00036E34 7F 64 DB 78 */ mr r4, r27 +/* 81368A38 00036E38 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368A3C 00036E3C 7D 89 03 A6 */ mtctr r12 +/* 81368A40 00036E40 4E 80 04 21 */ bctrl +/* 81368A44 00036E44 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368A48 00036E48 7F 43 D3 78 */ mr r3, r26 +/* 81368A4C 00036E4C 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81368A50 00036E50 7D 89 03 A6 */ mtctr r12 +/* 81368A54 00036E54 4E 80 04 21 */ bctrl +/* 81368A58 00036E58 7C 64 1B 78 */ mr r4, r3 +/* 81368A5C 00036E5C 80 7A 00 80 */ lwz r3, 0x80(r26) +/* 81368A60 00036E60 7F 66 DB 78 */ mr r6, r27 +/* 81368A64 00036E64 7F A7 EB 78 */ mr r7, r29 +/* 81368A68 00036E68 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368A6C 00036E6C 38 A0 00 01 */ li r5, 0x1 +/* 81368A70 00036E70 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368A74 00036E74 7D 89 03 A6 */ mtctr r12 +/* 81368A78 00036E78 4E 80 04 21 */ bctrl +.L_81368A7C: +/* 81368A7C 00036E7C 3B C0 00 01 */ li r30, 0x1 +/* 81368A80 00036E80 48 00 00 90 */ b .L_81368B10 +.L_81368A84: +/* 81368A84 00036E84 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368A88 00036E88 7F 43 D3 78 */ mr r3, r26 +/* 81368A8C 00036E8C 7F 64 DB 78 */ mr r4, r27 +/* 81368A90 00036E90 81 8C 00 24 */ lwz r12, 0x24(r12) +/* 81368A94 00036E94 7D 89 03 A6 */ mtctr r12 +/* 81368A98 00036E98 4E 80 04 21 */ bctrl +/* 81368A9C 00036E9C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368AA0 00036EA0 41 82 00 70 */ beq .L_81368B10 +/* 81368AA4 00036EA4 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368AA8 00036EA8 7F 43 D3 78 */ mr r3, r26 +/* 81368AAC 00036EAC 7F 64 DB 78 */ mr r4, r27 +/* 81368AB0 00036EB0 38 A0 00 00 */ li r5, 0x0 +/* 81368AB4 00036EB4 81 8C 00 2C */ lwz r12, 0x2c(r12) +/* 81368AB8 00036EB8 7D 89 03 A6 */ mtctr r12 +/* 81368ABC 00036EBC 4E 80 04 21 */ bctrl +/* 81368AC0 00036EC0 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368AC4 00036EC4 7F 43 D3 78 */ mr r3, r26 +/* 81368AC8 00036EC8 7F 64 DB 78 */ mr r4, r27 +/* 81368ACC 00036ECC 81 8C 00 34 */ lwz r12, 0x34(r12) +/* 81368AD0 00036ED0 7D 89 03 A6 */ mtctr r12 +/* 81368AD4 00036ED4 4E 80 04 21 */ bctrl +/* 81368AD8 00036ED8 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368ADC 00036EDC 7F 43 D3 78 */ mr r3, r26 +/* 81368AE0 00036EE0 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81368AE4 00036EE4 7D 89 03 A6 */ mtctr r12 +/* 81368AE8 00036EE8 4E 80 04 21 */ bctrl +/* 81368AEC 00036EEC 7C 64 1B 78 */ mr r4, r3 +/* 81368AF0 00036EF0 80 7A 00 80 */ lwz r3, 0x80(r26) +/* 81368AF4 00036EF4 7F 66 DB 78 */ mr r6, r27 +/* 81368AF8 00036EF8 7F A7 EB 78 */ mr r7, r29 +/* 81368AFC 00036EFC 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368B00 00036F00 38 A0 00 02 */ li r5, 0x2 +/* 81368B04 00036F04 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368B08 00036F08 7D 89 03 A6 */ mtctr r12 +/* 81368B0C 00036F0C 4E 80 04 21 */ bctrl +.L_81368B10: +/* 81368B10 00036F10 7C 7A DA 14 */ add r3, r26, r27 +/* 81368B14 00036F14 88 03 00 0C */ lbz r0, 0xc(r3) +/* 81368B18 00036F18 2C 00 00 00 */ cmpwi r0, 0x0 +/* 81368B1C 00036F1C 41 82 00 70 */ beq .L_81368B8C +/* 81368B20 00036F20 1C 1B 00 0C */ mulli r0, r27, 0xc +/* 81368B24 00036F24 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368B28 00036F28 7F 43 D3 78 */ mr r3, r26 +/* 81368B2C 00036F2C 81 8C 00 38 */ lwz r12, 0x38(r12) +/* 81368B30 00036F30 7F FA 02 14 */ add r31, r26, r0 +/* 81368B34 00036F34 C0 3F 00 14 */ lfs f1, 0x14(r31) +/* 81368B38 00036F38 C0 1F 00 18 */ lfs f0, 0x18(r31) +/* 81368B3C 00036F3C EC 3E 08 28 */ fsubs f1, f30, f1 +/* 81368B40 00036F40 EC 5F 00 28 */ fsubs f2, f31, f0 +/* 81368B44 00036F44 7D 89 03 A6 */ mtctr r12 +/* 81368B48 00036F48 4E 80 04 21 */ bctrl +/* 81368B4C 00036F4C D3 DF 00 14 */ stfs f30, 0x14(r31) +/* 81368B50 00036F50 7F 43 D3 78 */ mr r3, r26 +/* 81368B54 00036F54 D3 FF 00 18 */ stfs f31, 0x18(r31) +/* 81368B58 00036F58 81 9A 00 00 */ lwz r12, 0x0(r26) +/* 81368B5C 00036F5C 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81368B60 00036F60 7D 89 03 A6 */ mtctr r12 +/* 81368B64 00036F64 4E 80 04 21 */ bctrl +/* 81368B68 00036F68 7C 64 1B 78 */ mr r4, r3 +/* 81368B6C 00036F6C 80 7A 00 80 */ lwz r3, 0x80(r26) +/* 81368B70 00036F70 7F 66 DB 78 */ mr r6, r27 +/* 81368B74 00036F74 7F A7 EB 78 */ mr r7, r29 +/* 81368B78 00036F78 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368B7C 00036F7C 38 A0 00 04 */ li r5, 0x4 +/* 81368B80 00036F80 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368B84 00036F84 7D 89 03 A6 */ mtctr r12 +/* 81368B88 00036F88 4E 80 04 21 */ bctrl +.L_81368B8C: +/* 81368B8C 00036F8C 2C 1C 00 00 */ cmpwi r28, 0x0 +/* 81368B90 00036F90 40 82 00 1C */ bne .L_81368BAC +/* 81368B94 00036F94 7C 7A DA 14 */ add r3, r26, r27 +/* 81368B98 00036F98 88 03 00 0C */ lbz r0, 0xc(r3) +/* 81368B9C 00036F9C 2C 00 00 00 */ cmpwi r0, 0x0 +/* 81368BA0 00036FA0 41 82 00 0C */ beq .L_81368BAC +/* 81368BA4 00036FA4 38 00 00 00 */ li r0, 0x0 +/* 81368BA8 00036FA8 98 03 00 0C */ stb r0, 0xc(r3) +.L_81368BAC: +/* 81368BAC 00036FAC 7F C3 F3 78 */ mr r3, r30 +/* 81368BB0 00036FB0 E3 E1 00 38 */ psq_l f31, 0x38(r1), 0, qr0 +/* 81368BB4 00036FB4 CB E1 00 30 */ lfd f31, 0x30(r1) +/* 81368BB8 00036FB8 E3 C1 00 28 */ psq_l f30, 0x28(r1), 0, qr0 +/* 81368BBC 00036FBC CB C1 00 20 */ lfd f30, 0x20(r1) +/* 81368BC0 00036FC0 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368BC4 00036FC4 48 29 09 45 */ bl _restgpr_26 +/* 81368BC8 00036FC8 80 01 00 44 */ lwz r0, 0x44(r1) +/* 81368BCC 00036FCC 7C 08 03 A6 */ mtlr r0 +/* 81368BD0 00036FD0 38 21 00 40 */ addi r1, r1, 0x40 +/* 81368BD4 00036FD4 4E 80 00 20 */ blr +.endfn update__Q23gui9ComponentFiffUlUlUlPv + +# .text:0x2C0 | 0x81368BD8 | size: 0x8 +# gui::Component::isVisible() +.fn isVisible__Q23gui9ComponentFv, global +/* 81368BD8 00036FD8 38 60 00 01 */ li r3, 0x1 +/* 81368BDC 00036FDC 4E 80 00 20 */ blr +.endfn isVisible__Q23gui9ComponentFv + +# .text:0x2C8 | 0x81368BE0 | size: 0xC +# gui::Component::isPointed(int) +.fn isPointed__Q23gui9ComponentFi, global +/* 81368BE0 00036FE0 7C 63 22 14 */ add r3, r3, r4 +/* 81368BE4 00036FE4 88 63 00 04 */ lbz r3, 0x4(r3) +/* 81368BE8 00036FE8 4E 80 00 20 */ blr +.endfn isPointed__Q23gui9ComponentFi + +# .text:0x2D4 | 0x81368BEC | size: 0x18 +# gui::Component::onMove(int, float, float) +.fn onMove__Q23gui9ComponentFiff, global +/* 81368BEC 00036FEC 54 80 08 3C */ slwi r0, r4, 1 +/* 81368BF0 00036FF0 7C 83 02 14 */ add r4, r3, r0 +/* 81368BF4 00036FF4 A0 64 00 84 */ lhz r3, 0x84(r4) +/* 81368BF8 00036FF8 38 03 00 01 */ addi r0, r3, 0x1 +/* 81368BFC 00036FFC B0 04 00 84 */ sth r0, 0x84(r4) +/* 81368C00 00037000 4E 80 00 20 */ blr +.endfn onMove__Q23gui9ComponentFiff + +# .text:0x2EC | 0x81368C04 | size: 0x8 +# gui::Component::getID() +.fn getID__Q23gui9ComponentFv, global +/* 81368C04 00037004 80 63 00 78 */ lwz r3, 0x78(r3) +/* 81368C08 00037008 4E 80 00 20 */ blr +.endfn getID__Q23gui9ComponentFv + +# .text:0x2F4 | 0x81368C0C | size: 0xC +# gui::Component::setPointed(int, bool) +.fn setPointed__Q23gui9ComponentFib, global +/* 81368C0C 0003700C 7C 63 22 14 */ add r3, r3, r4 +/* 81368C10 00037010 98 A3 00 04 */ stb r5, 0x4(r3) +/* 81368C14 00037014 4E 80 00 20 */ blr +.endfn setPointed__Q23gui9ComponentFib + +# .text:0x300 | 0x81368C18 | size: 0x14 +# gui::Component::onPoint(int) +.fn onPoint__Q23gui9ComponentFi, global +/* 81368C18 00037018 54 80 08 3C */ slwi r0, r4, 1 +/* 81368C1C 0003701C 38 80 00 00 */ li r4, 0x0 +/* 81368C20 00037020 7C 63 02 14 */ add r3, r3, r0 +/* 81368C24 00037024 B0 83 00 84 */ sth r4, 0x84(r3) +/* 81368C28 00037028 4E 80 00 20 */ blr +.endfn onPoint__Q23gui9ComponentFi + +# .text:0x314 | 0x81368C2C | size: 0x14 +# gui::Component::offPoint(int) +.fn offPoint__Q23gui9ComponentFi, global +/* 81368C2C 0003702C 54 80 08 3C */ slwi r0, r4, 1 +/* 81368C30 00037030 38 80 00 00 */ li r4, 0x0 +/* 81368C34 00037034 7C 63 02 14 */ add r3, r3, r0 +/* 81368C38 00037038 B0 83 00 84 */ sth r4, 0x84(r3) +/* 81368C3C 0003703C 4E 80 00 20 */ blr +.endfn offPoint__Q23gui9ComponentFi + +# .text:0x328 | 0x81368C40 | size: 0x4 +# gui::Component::onDrag(float, float) +.fn onDrag__Q23gui9ComponentFff, global +/* 81368C40 00037040 4E 80 00 20 */ blr +.endfn onDrag__Q23gui9ComponentFff + +# .text:0x32C | 0x81368C44 | size: 0xB4 +# gui::Manager::~Manager() +.fn __dt__Q23gui7ManagerFv, global +/* 81368C44 00037044 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 81368C48 00037048 7C 08 02 A6 */ mflr r0 +/* 81368C4C 0003704C 90 01 00 24 */ stw r0, 0x24(r1) +/* 81368C50 00037050 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368C54 00037054 48 29 08 75 */ bl _savegpr_29 +/* 81368C58 00037058 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368C5C 0003705C 7C 7D 1B 78 */ mr r29, r3 +/* 81368C60 00037060 7C 9E 23 78 */ mr r30, r4 +/* 81368C64 00037064 41 82 00 78 */ beq .L_81368CDC +/* 81368C68 00037068 3C A0 81 64 */ lis r5, lbl_816427E0@ha +/* 81368C6C 0003706C 38 80 00 00 */ li r4, 0x0 +/* 81368C70 00037070 38 A5 27 E0 */ addi r5, r5, lbl_816427E0@l +/* 81368C74 00037074 90 A3 00 00 */ stw r5, 0x0(r3) +/* 81368C78 00037078 38 63 00 08 */ addi r3, r3, 0x8 +/* 81368C7C 0003707C 48 1A 96 61 */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 81368C80 00037080 7C 7F 1B 78 */ mr r31, r3 +/* 81368C84 00037084 48 00 00 40 */ b .L_81368CC4 +.L_81368C88: +/* 81368C88 00037088 7F E4 FB 78 */ mr r4, r31 +/* 81368C8C 0003708C 38 7D 00 08 */ addi r3, r29, 0x8 +/* 81368C90 00037090 48 1A 95 E1 */ bl List_Remove__Q24nw4r2utFPQ34nw4r2ut4ListPv +/* 81368C94 00037094 80 7D 00 14 */ lwz r3, 0x14(r29) +/* 81368C98 00037098 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368C9C 0003709C 41 82 00 10 */ beq .L_81368CAC +/* 81368CA0 000370A0 7F E4 FB 78 */ mr r4, r31 +/* 81368CA4 000370A4 48 1F 29 D5 */ bl fn_8155B678 +/* 81368CA8 000370A8 48 00 00 0C */ b .L_81368CB4 +.L_81368CAC: +/* 81368CAC 000370AC 7F E3 FB 78 */ mr r3, r31 +/* 81368CB0 000370B0 48 28 F4 35 */ bl __dl__FPv +.L_81368CB4: +/* 81368CB4 000370B4 38 7D 00 08 */ addi r3, r29, 0x8 +/* 81368CB8 000370B8 38 80 00 00 */ li r4, 0x0 +/* 81368CBC 000370BC 48 1A 96 21 */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 81368CC0 000370C0 7C 7F 1B 78 */ mr r31, r3 +.L_81368CC4: +/* 81368CC4 000370C4 2C 1F 00 00 */ cmpwi r31, 0x0 +/* 81368CC8 000370C8 40 82 FF C0 */ bne .L_81368C88 +/* 81368CCC 000370CC 2C 1E 00 00 */ cmpwi r30, 0x0 +/* 81368CD0 000370D0 40 81 00 0C */ ble .L_81368CDC +/* 81368CD4 000370D4 7F A3 EB 78 */ mr r3, r29 +/* 81368CD8 000370D8 48 28 F4 0D */ bl __dl__FPv +.L_81368CDC: +/* 81368CDC 000370DC 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368CE0 000370E0 7F A3 EB 78 */ mr r3, r29 +/* 81368CE4 000370E4 48 29 08 31 */ bl _restgpr_29 +/* 81368CE8 000370E8 80 01 00 24 */ lwz r0, 0x24(r1) +/* 81368CEC 000370EC 7C 08 03 A6 */ mtlr r0 +/* 81368CF0 000370F0 38 21 00 20 */ addi r1, r1, 0x20 +/* 81368CF4 000370F4 4E 80 00 20 */ blr +.endfn __dt__Q23gui7ManagerFv + +# .text:0x3E0 | 0x81368CF8 | size: 0x68 +# gui::Manager::init() +.fn init__Q23gui7ManagerFv, global +/* 81368CF8 000370F8 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 81368CFC 000370FC 7C 08 02 A6 */ mflr r0 +/* 81368D00 00037100 90 01 00 14 */ stw r0, 0x14(r1) +/* 81368D04 00037104 93 E1 00 0C */ stw r31, 0xc(r1) +/* 81368D08 00037108 3B E0 00 00 */ li r31, 0x0 +/* 81368D0C 0003710C 93 C1 00 08 */ stw r30, 0x8(r1) +/* 81368D10 00037110 7C 7E 1B 78 */ mr r30, r3 +/* 81368D14 00037114 48 00 00 28 */ b .L_81368D3C +.L_81368D18: +/* 81368D18 00037118 38 7E 00 08 */ addi r3, r30, 0x8 +/* 81368D1C 0003711C 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 81368D20 00037120 48 1A 95 F9 */ bl fn_81512318 +/* 81368D24 00037124 80 63 00 04 */ lwz r3, 0x4(r3) +/* 81368D28 00037128 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368D2C 0003712C 81 8C 00 0C */ lwz r12, 0xc(r12) +/* 81368D30 00037130 7D 89 03 A6 */ mtctr r12 +/* 81368D34 00037134 4E 80 04 21 */ bctrl +/* 81368D38 00037138 3B FF 00 01 */ addi r31, r31, 0x1 +.L_81368D3C: +/* 81368D3C 0003713C A0 1E 00 10 */ lhz r0, 0x10(r30) +/* 81368D40 00037140 7C 1F 00 40 */ cmplw r31, r0 +/* 81368D44 00037144 41 80 FF D4 */ blt .L_81368D18 +/* 81368D48 00037148 80 01 00 14 */ lwz r0, 0x14(r1) +/* 81368D4C 0003714C 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 81368D50 00037150 83 C1 00 08 */ lwz r30, 0x8(r1) +/* 81368D54 00037154 7C 08 03 A6 */ mtlr r0 +/* 81368D58 00037158 38 21 00 10 */ addi r1, r1, 0x10 +/* 81368D5C 0003715C 4E 80 00 20 */ blr +.endfn init__Q23gui7ManagerFv + +# .text:0x448 | 0x81368D60 | size: 0x54 +# gui::Component::init() +.fn init__Q23gui9ComponentFv, global +/* 81368D60 00037160 39 40 00 00 */ li r10, 0x0 +/* 81368D64 00037164 38 00 00 08 */ li r0, 0x8 +/* 81368D68 00037168 7D 47 53 78 */ mr r7, r10 +/* 81368D6C 0003716C C0 02 82 78 */ lfs f0, lbl_81694678@sda21(r0) +/* 81368D70 00037170 38 80 00 00 */ li r4, 0x0 +/* 81368D74 00037174 38 A0 00 00 */ li r5, 0x0 +/* 81368D78 00037178 7C 09 03 A6 */ mtctr r0 +.L_81368D7C: +/* 81368D7C 0003717C 7D 23 52 14 */ add r9, r3, r10 +/* 81368D80 00037180 7D 03 22 14 */ add r8, r3, r4 +/* 81368D84 00037184 98 E9 00 04 */ stb r7, 0x4(r9) +/* 81368D88 00037188 7C C3 2A 14 */ add r6, r3, r5 +/* 81368D8C 0003718C 39 4A 00 01 */ addi r10, r10, 0x1 +/* 81368D90 00037190 38 84 00 0C */ addi r4, r4, 0xc +/* 81368D94 00037194 D0 08 00 14 */ stfs f0, 0x14(r8) +/* 81368D98 00037198 38 A5 00 02 */ addi r5, r5, 0x2 +/* 81368D9C 0003719C D0 08 00 18 */ stfs f0, 0x18(r8) +/* 81368DA0 000371A0 D0 08 00 1C */ stfs f0, 0x1c(r8) +/* 81368DA4 000371A4 98 E9 00 0C */ stb r7, 0xc(r9) +/* 81368DA8 000371A8 B0 E6 00 84 */ sth r7, 0x84(r6) +/* 81368DAC 000371AC 42 00 FF D0 */ bdnz .L_81368D7C +/* 81368DB0 000371B0 4E 80 00 20 */ blr +.endfn init__Q23gui9ComponentFv + +# .text:0x49C | 0x81368DB4 | size: 0xBC +# gui::Manager::addComponent(gui::Component*) +.fn addComponent__Q23gui7ManagerFPQ23gui9Component, global +/* 81368DB4 000371B4 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 81368DB8 000371B8 7C 08 02 A6 */ mflr r0 +/* 81368DBC 000371BC 90 01 00 24 */ stw r0, 0x24(r1) +/* 81368DC0 000371C0 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368DC4 000371C4 48 29 07 05 */ bl _savegpr_29 +/* 81368DC8 000371C8 7C 9E 23 78 */ mr r30, r4 +/* 81368DCC 000371CC 7C 7D 1B 78 */ mr r29, r3 +/* 81368DD0 000371D0 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 81368DD4 000371D4 7F C3 F3 78 */ mr r3, r30 +/* 81368DD8 000371D8 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81368DDC 000371DC 7D 89 03 A6 */ mtctr r12 +/* 81368DE0 000371E0 4E 80 04 21 */ bctrl +/* 81368DE4 000371E4 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 81368DE8 000371E8 7C 7F 1B 78 */ mr r31, r3 +/* 81368DEC 000371EC 7F C3 F3 78 */ mr r3, r30 +/* 81368DF0 000371F0 7F A4 EB 78 */ mr r4, r29 +/* 81368DF4 000371F4 81 8C 00 58 */ lwz r12, 0x58(r12) +/* 81368DF8 000371F8 7D 89 03 A6 */ mtctr r12 +/* 81368DFC 000371FC 4E 80 04 21 */ bctrl +/* 81368E00 00037200 80 7D 00 14 */ lwz r3, 0x14(r29) +/* 81368E04 00037204 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368E08 00037208 41 82 00 2C */ beq .L_81368E34 +/* 81368E0C 0003720C 38 80 00 10 */ li r4, 0x10 +/* 81368E10 00037210 48 1F 28 59 */ bl fn_8155B668 +/* 81368E14 00037214 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368E18 00037218 41 82 00 0C */ beq .L_81368E24 +/* 81368E1C 0003721C 93 E3 00 00 */ stw r31, 0x0(r3) +/* 81368E20 00037220 93 C3 00 04 */ stw r30, 0x4(r3) +.L_81368E24: +/* 81368E24 00037224 7C 64 1B 78 */ mr r4, r3 +/* 81368E28 00037228 38 7D 00 08 */ addi r3, r29, 0x8 +/* 81368E2C 0003722C 48 1A 92 49 */ bl List_Append__Q24nw4r2utFPQ34nw4r2ut4ListPv +/* 81368E30 00037230 48 00 00 28 */ b .L_81368E58 +.L_81368E34: +/* 81368E34 00037234 38 60 00 10 */ li r3, 0x10 +/* 81368E38 00037238 48 28 F2 65 */ bl __nw__FUl +/* 81368E3C 0003723C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368E40 00037240 41 82 00 0C */ beq .L_81368E4C +/* 81368E44 00037244 93 E3 00 00 */ stw r31, 0x0(r3) +/* 81368E48 00037248 93 C3 00 04 */ stw r30, 0x4(r3) +.L_81368E4C: +/* 81368E4C 0003724C 7C 64 1B 78 */ mr r4, r3 +/* 81368E50 00037250 38 7D 00 08 */ addi r3, r29, 0x8 +/* 81368E54 00037254 48 1A 92 21 */ bl List_Append__Q24nw4r2utFPQ34nw4r2ut4ListPv +.L_81368E58: +/* 81368E58 00037258 39 61 00 20 */ addi r11, r1, 0x20 +/* 81368E5C 0003725C 48 29 06 B9 */ bl _restgpr_29 +/* 81368E60 00037260 80 01 00 24 */ lwz r0, 0x24(r1) +/* 81368E64 00037264 7C 08 03 A6 */ mtlr r0 +/* 81368E68 00037268 38 21 00 20 */ addi r1, r1, 0x20 +/* 81368E6C 0003726C 4E 80 00 20 */ blr +.endfn addComponent__Q23gui7ManagerFPQ23gui9Component + +# .text:0x558 | 0x81368E70 | size: 0x8 +# gui::Component::setManager(gui::Manager*) +.fn setManager__Q23gui9ComponentFPQ23gui7Manager, global +/* 81368E70 00037270 90 83 00 80 */ stw r4, 0x80(r3) +/* 81368E74 00037274 4E 80 00 20 */ blr +.endfn setManager__Q23gui9ComponentFPQ23gui7Manager + +# .text:0x560 | 0x81368E78 | size: 0x2C +# gui::Manager::getComponent(unsigned long) +.fn getComponent__Q23gui7ManagerFUl, global +/* 81368E78 00037278 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 81368E7C 0003727C 7C 08 02 A6 */ mflr r0 +/* 81368E80 00037280 54 84 04 3E */ clrlwi r4, r4, 16 +/* 81368E84 00037284 38 63 00 08 */ addi r3, r3, 0x8 +/* 81368E88 00037288 90 01 00 14 */ stw r0, 0x14(r1) +/* 81368E8C 0003728C 48 1A 94 8D */ bl fn_81512318 +/* 81368E90 00037290 80 01 00 14 */ lwz r0, 0x14(r1) +/* 81368E94 00037294 80 63 00 04 */ lwz r3, 0x4(r3) +/* 81368E98 00037298 7C 08 03 A6 */ mtlr r0 +/* 81368E9C 0003729C 38 21 00 10 */ addi r1, r1, 0x10 +/* 81368EA0 000372A0 4E 80 00 20 */ blr +.endfn getComponent__Q23gui7ManagerFUl + +# .text:0x58C | 0x81368EA4 | size: 0x1B0 +# gui::Manager::update(int, float, float, unsigned long, unsigned long, unsigned long, void*) +.fn update__Q23gui7ManagerFiffUlUlUlPv, global +/* 81368EA4 000372A4 94 21 FF B0 */ stwu r1, -0x50(r1) +/* 81368EA8 000372A8 7C 08 02 A6 */ mflr r0 +/* 81368EAC 000372AC 90 01 00 54 */ stw r0, 0x54(r1) +/* 81368EB0 000372B0 39 61 00 40 */ addi r11, r1, 0x40 +/* 81368EB4 000372B4 DB E1 00 48 */ stfd f31, 0x48(r1) +/* 81368EB8 000372B8 DB C1 00 40 */ stfd f30, 0x40(r1) +/* 81368EBC 000372BC 48 29 05 F5 */ bl _savegpr_23 +/* 81368EC0 000372C0 FF C0 08 90 */ fmr f30, f1 +/* 81368EC4 000372C4 7C 77 1B 78 */ mr r23, r3 +/* 81368EC8 000372C8 FF E0 10 90 */ fmr f31, f2 +/* 81368ECC 000372CC 7C 98 23 78 */ mr r24, r4 +/* 81368ED0 000372D0 7C B9 2B 78 */ mr r25, r5 +/* 81368ED4 000372D4 7C DA 33 78 */ mr r26, r6 +/* 81368ED8 000372D8 7C FB 3B 78 */ mr r27, r7 +/* 81368EDC 000372DC 7D 1C 43 78 */ mr r28, r8 +/* 81368EE0 000372E0 3B E0 00 00 */ li r31, 0x0 +/* 81368EE4 000372E4 3B C0 00 00 */ li r30, 0x0 +/* 81368EE8 000372E8 38 80 00 00 */ li r4, 0x0 +/* 81368EEC 000372EC 38 63 00 08 */ addi r3, r3, 0x8 +/* 81368EF0 000372F0 48 1A 93 ED */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 81368EF4 000372F4 7C 7D 1B 78 */ mr r29, r3 +/* 81368EF8 000372F8 48 00 00 70 */ b .L_81368F68 +.L_81368EFC: +/* 81368EFC 000372FC 80 7D 00 04 */ lwz r3, 0x4(r29) +/* 81368F00 00037300 FC 20 F0 90 */ fmr f1, f30 +/* 81368F04 00037304 FC 40 F8 90 */ fmr f2, f31 +/* 81368F08 00037308 7F 04 C3 78 */ mr r4, r24 +/* 81368F0C 0003730C 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368F10 00037310 7F 25 CB 78 */ mr r5, r25 +/* 81368F14 00037314 7F 46 D3 78 */ mr r6, r26 +/* 81368F18 00037318 81 8C 00 4C */ lwz r12, 0x4c(r12) +/* 81368F1C 0003731C 7F 67 DB 78 */ mr r7, r27 +/* 81368F20 00037320 7F 88 E3 78 */ mr r8, r28 +/* 81368F24 00037324 7D 89 03 A6 */ mtctr r12 +/* 81368F28 00037328 4E 80 04 21 */ bctrl +/* 81368F2C 0003732C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368F30 00037330 41 82 00 28 */ beq .L_81368F58 +/* 81368F34 00037334 80 7D 00 04 */ lwz r3, 0x4(r29) +/* 81368F38 00037338 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81368F3C 0003733C 81 8C 00 50 */ lwz r12, 0x50(r12) +/* 81368F40 00037340 7D 89 03 A6 */ mtctr r12 +/* 81368F44 00037344 4E 80 04 21 */ bctrl +/* 81368F48 00037348 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81368F4C 0003734C 41 82 00 08 */ beq .L_81368F54 +/* 81368F50 00037350 83 DD 00 04 */ lwz r30, 0x4(r29) +.L_81368F54: +/* 81368F54 00037354 3B E0 00 01 */ li r31, 0x1 +.L_81368F58: +/* 81368F58 00037358 7F A4 EB 78 */ mr r4, r29 +/* 81368F5C 0003735C 38 77 00 08 */ addi r3, r23, 0x8 +/* 81368F60 00037360 48 1A 93 7D */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 81368F64 00037364 7C 7D 1B 78 */ mr r29, r3 +.L_81368F68: +/* 81368F68 00037368 2C 1D 00 00 */ cmpwi r29, 0x0 +/* 81368F6C 0003736C 40 82 FF 90 */ bne .L_81368EFC +/* 81368F70 00037370 2C 1E 00 00 */ cmpwi r30, 0x0 +/* 81368F74 00037374 41 82 00 BC */ beq .L_81369030 +/* 81368F78 00037378 2C 19 00 00 */ cmpwi r25, 0x0 +/* 81368F7C 0003737C 41 82 00 74 */ beq .L_81368FF0 +/* 81368F80 00037380 38 00 00 00 */ li r0, 0x0 +/* 81368F84 00037384 7F C3 F3 78 */ mr r3, r30 +/* 81368F88 00037388 90 01 00 08 */ stw r0, 0x8(r1) +/* 81368F8C 0003738C 7F 04 C3 78 */ mr r4, r24 +/* 81368F90 00037390 7F 25 CB 78 */ mr r5, r25 +/* 81368F94 00037394 38 C1 00 08 */ addi r6, r1, 0x8 +/* 81368F98 00037398 90 01 00 0C */ stw r0, 0xc(r1) +/* 81368F9C 0003739C 90 01 00 10 */ stw r0, 0x10(r1) +/* 81368FA0 000373A0 D3 C1 00 08 */ stfs f30, 0x8(r1) +/* 81368FA4 000373A4 D3 E1 00 0C */ stfs f31, 0xc(r1) +/* 81368FA8 000373A8 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 81368FAC 000373AC 81 8C 00 40 */ lwz r12, 0x40(r12) +/* 81368FB0 000373B0 7D 89 03 A6 */ mtctr r12 +/* 81368FB4 000373B4 4E 80 04 21 */ bctrl +/* 81368FB8 000373B8 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 81368FBC 000373BC 7F C3 F3 78 */ mr r3, r30 +/* 81368FC0 000373C0 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81368FC4 000373C4 7D 89 03 A6 */ mtctr r12 +/* 81368FC8 000373C8 4E 80 04 21 */ bctrl +/* 81368FCC 000373CC 81 97 00 00 */ lwz r12, 0x0(r23) +/* 81368FD0 000373D0 7C 64 1B 78 */ mr r4, r3 +/* 81368FD4 000373D4 7E E3 BB 78 */ mr r3, r23 +/* 81368FD8 000373D8 7F 06 C3 78 */ mr r6, r24 +/* 81368FDC 000373DC 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81368FE0 000373E0 7F 87 E3 78 */ mr r7, r28 +/* 81368FE4 000373E4 38 A0 00 00 */ li r5, 0x0 +/* 81368FE8 000373E8 7D 89 03 A6 */ mtctr r12 +/* 81368FEC 000373EC 4E 80 04 21 */ bctrl +.L_81368FF0: +/* 81368FF0 000373F0 2C 1B 00 00 */ cmpwi r27, 0x0 +/* 81368FF4 000373F4 41 82 00 3C */ beq .L_81369030 +/* 81368FF8 000373F8 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 81368FFC 000373FC 7F C3 F3 78 */ mr r3, r30 +/* 81369000 00037400 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81369004 00037404 7D 89 03 A6 */ mtctr r12 +/* 81369008 00037408 4E 80 04 21 */ bctrl +/* 8136900C 0003740C 81 97 00 00 */ lwz r12, 0x0(r23) +/* 81369010 00037410 7C 64 1B 78 */ mr r4, r3 +/* 81369014 00037414 7E E3 BB 78 */ mr r3, r23 +/* 81369018 00037418 7F 06 C3 78 */ mr r6, r24 +/* 8136901C 0003741C 81 8C 00 30 */ lwz r12, 0x30(r12) +/* 81369020 00037420 7F 87 E3 78 */ mr r7, r28 +/* 81369024 00037424 38 A0 00 05 */ li r5, 0x5 +/* 81369028 00037428 7D 89 03 A6 */ mtctr r12 +/* 8136902C 0003742C 4E 80 04 21 */ bctrl +.L_81369030: +/* 81369030 00037430 CB E1 00 48 */ lfd f31, 0x48(r1) +/* 81369034 00037434 7F E3 FB 78 */ mr r3, r31 +/* 81369038 00037438 CB C1 00 40 */ lfd f30, 0x40(r1) +/* 8136903C 0003743C 39 61 00 40 */ addi r11, r1, 0x40 +/* 81369040 00037440 48 29 04 BD */ bl _restgpr_23 +/* 81369044 00037444 80 01 00 54 */ lwz r0, 0x54(r1) +/* 81369048 00037448 7C 08 03 A6 */ mtlr r0 +/* 8136904C 0003744C 38 21 00 50 */ addi r1, r1, 0x50 +/* 81369050 00037450 4E 80 00 20 */ blr +.endfn update__Q23gui7ManagerFiffUlUlUlPv + +# .text:0x73C | 0x81369054 | size: 0x8 +# gui::Component::isTriggerTarger() +.fn isTriggerTarger__Q23gui9ComponentFv, global +/* 81369054 00037454 88 63 00 7C */ lbz r3, 0x7c(r3) +/* 81369058 00037458 4E 80 00 20 */ blr +.endfn isTriggerTarger__Q23gui9ComponentFv + +# .text:0x744 | 0x8136905C | size: 0x4C +# gui::Component::onTrig(int, unsigned long, Vec&) +.fn onTrig__Q23gui9ComponentFiUlR3Vec, global +/* 8136905C 0003745C 80 03 00 74 */ lwz r0, 0x74(r3) +/* 81369060 00037460 7C A0 00 39 */ and. r0, r5, r0 +/* 81369064 00037464 4D 82 00 20 */ beqlr +/* 81369068 00037468 1C E4 00 0C */ mulli r7, r4, 0xc +/* 8136906C 0003746C 54 80 08 3C */ slwi r0, r4, 1 +/* 81369070 00037470 C0 06 00 00 */ lfs f0, 0x0(r6) +/* 81369074 00037474 7C 83 22 14 */ add r4, r3, r4 +/* 81369078 00037478 38 A0 00 01 */ li r5, 0x1 +/* 8136907C 0003747C 7C E3 3A 14 */ add r7, r3, r7 +/* 81369080 00037480 D0 07 00 14 */ stfs f0, 0x14(r7) +/* 81369084 00037484 7C 63 02 14 */ add r3, r3, r0 +/* 81369088 00037488 38 00 00 00 */ li r0, 0x0 +/* 8136908C 0003748C C0 06 00 04 */ lfs f0, 0x4(r6) +/* 81369090 00037490 D0 07 00 18 */ stfs f0, 0x18(r7) +/* 81369094 00037494 C0 06 00 08 */ lfs f0, 0x8(r6) +/* 81369098 00037498 D0 07 00 1C */ stfs f0, 0x1c(r7) +/* 8136909C 0003749C 98 A4 00 0C */ stb r5, 0xc(r4) +/* 813690A0 000374A0 B0 03 00 84 */ sth r0, 0x84(r3) +/* 813690A4 000374A4 4E 80 00 20 */ blr +.endfn onTrig__Q23gui9ComponentFiUlR3Vec + +# .text:0x790 | 0x813690A8 | size: 0x68 +# gui::Manager::calc() +.fn calc__Q23gui7ManagerFv, global +/* 813690A8 000374A8 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 813690AC 000374AC 7C 08 02 A6 */ mflr r0 +/* 813690B0 000374B0 90 01 00 14 */ stw r0, 0x14(r1) +/* 813690B4 000374B4 93 E1 00 0C */ stw r31, 0xc(r1) +/* 813690B8 000374B8 3B E0 00 00 */ li r31, 0x0 +/* 813690BC 000374BC 93 C1 00 08 */ stw r30, 0x8(r1) +/* 813690C0 000374C0 7C 7E 1B 78 */ mr r30, r3 +/* 813690C4 000374C4 48 00 00 28 */ b .L_813690EC +.L_813690C8: +/* 813690C8 000374C8 38 7E 00 08 */ addi r3, r30, 0x8 +/* 813690CC 000374CC 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 813690D0 000374D0 48 1A 92 49 */ bl fn_81512318 +/* 813690D4 000374D4 80 63 00 04 */ lwz r3, 0x4(r3) +/* 813690D8 000374D8 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813690DC 000374DC 81 8C 00 10 */ lwz r12, 0x10(r12) +/* 813690E0 000374E0 7D 89 03 A6 */ mtctr r12 +/* 813690E4 000374E4 4E 80 04 21 */ bctrl +/* 813690E8 000374E8 3B FF 00 01 */ addi r31, r31, 0x1 +.L_813690EC: +/* 813690EC 000374EC A0 1E 00 10 */ lhz r0, 0x10(r30) +/* 813690F0 000374F0 7C 1F 00 40 */ cmplw r31, r0 +/* 813690F4 000374F4 41 80 FF D4 */ blt .L_813690C8 +/* 813690F8 000374F8 80 01 00 14 */ lwz r0, 0x14(r1) +/* 813690FC 000374FC 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 81369100 00037500 83 C1 00 08 */ lwz r30, 0x8(r1) +/* 81369104 00037504 7C 08 03 A6 */ mtlr r0 +/* 81369108 00037508 38 21 00 10 */ addi r1, r1, 0x10 +/* 8136910C 0003750C 4E 80 00 20 */ blr +.endfn calc__Q23gui7ManagerFv + +# .text:0x7F8 | 0x81369110 | size: 0x68 +# gui::Manager::draw() +.fn draw__Q23gui7ManagerFv, global +/* 81369110 00037510 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 81369114 00037514 7C 08 02 A6 */ mflr r0 +/* 81369118 00037518 90 01 00 14 */ stw r0, 0x14(r1) +/* 8136911C 0003751C 93 E1 00 0C */ stw r31, 0xc(r1) +/* 81369120 00037520 3B E0 00 00 */ li r31, 0x0 +/* 81369124 00037524 93 C1 00 08 */ stw r30, 0x8(r1) +/* 81369128 00037528 7C 7E 1B 78 */ mr r30, r3 +/* 8136912C 0003752C 48 00 00 28 */ b .L_81369154 +.L_81369130: +/* 81369130 00037530 38 7E 00 08 */ addi r3, r30, 0x8 +/* 81369134 00037534 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 81369138 00037538 48 1A 91 E1 */ bl fn_81512318 +/* 8136913C 0003753C 80 63 00 04 */ lwz r3, 0x4(r3) +/* 81369140 00037540 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81369144 00037544 81 8C 00 18 */ lwz r12, 0x18(r12) +/* 81369148 00037548 7D 89 03 A6 */ mtctr r12 +/* 8136914C 0003754C 4E 80 04 21 */ bctrl +/* 81369150 00037550 3B FF 00 01 */ addi r31, r31, 0x1 +.L_81369154: +/* 81369154 00037554 A0 1E 00 10 */ lhz r0, 0x10(r30) +/* 81369158 00037558 7C 1F 00 40 */ cmplw r31, r0 +/* 8136915C 0003755C 41 80 FF D4 */ blt .L_81369130 +/* 81369160 00037560 80 01 00 14 */ lwz r0, 0x14(r1) +/* 81369164 00037564 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 81369168 00037568 83 C1 00 08 */ lwz r30, 0x8(r1) +/* 8136916C 0003756C 7C 08 03 A6 */ mtlr r0 +/* 81369170 00037570 38 21 00 10 */ addi r1, r1, 0x10 +/* 81369174 00037574 4E 80 00 20 */ blr +.endfn draw__Q23gui7ManagerFv + +# .text:0x860 | 0x81369178 | size: 0x70 +# gui::Manager::setAllComponentTriggerTarget(bool) +.fn setAllComponentTriggerTarget__Q23gui7ManagerFb, global +/* 81369178 00037578 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 8136917C 0003757C 7C 08 02 A6 */ mflr r0 +/* 81369180 00037580 90 01 00 24 */ stw r0, 0x24(r1) +/* 81369184 00037584 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369188 00037588 48 29 03 41 */ bl _savegpr_29 +/* 8136918C 0003758C 7C 7D 1B 78 */ mr r29, r3 +/* 81369190 00037590 7C 9E 23 78 */ mr r30, r4 +/* 81369194 00037594 3B E0 00 00 */ li r31, 0x0 +/* 81369198 00037598 48 00 00 2C */ b .L_813691C4 +.L_8136919C: +/* 8136919C 0003759C 38 7D 00 08 */ addi r3, r29, 0x8 +/* 813691A0 000375A0 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 813691A4 000375A4 48 1A 91 75 */ bl fn_81512318 +/* 813691A8 000375A8 80 63 00 04 */ lwz r3, 0x4(r3) +/* 813691AC 000375AC 7F C4 F3 78 */ mr r4, r30 +/* 813691B0 000375B0 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813691B4 000375B4 81 8C 00 54 */ lwz r12, 0x54(r12) +/* 813691B8 000375B8 7D 89 03 A6 */ mtctr r12 +/* 813691BC 000375BC 4E 80 04 21 */ bctrl +/* 813691C0 000375C0 3B FF 00 01 */ addi r31, r31, 0x1 +.L_813691C4: +/* 813691C4 000375C4 A0 1D 00 10 */ lhz r0, 0x10(r29) +/* 813691C8 000375C8 7C 1F 00 40 */ cmplw r31, r0 +/* 813691CC 000375CC 41 80 FF D0 */ blt .L_8136919C +/* 813691D0 000375D0 39 61 00 20 */ addi r11, r1, 0x20 +/* 813691D4 000375D4 48 29 03 41 */ bl _restgpr_29 +/* 813691D8 000375D8 80 01 00 24 */ lwz r0, 0x24(r1) +/* 813691DC 000375DC 7C 08 03 A6 */ mtlr r0 +/* 813691E0 000375E0 38 21 00 20 */ addi r1, r1, 0x20 +/* 813691E4 000375E4 4E 80 00 20 */ blr +.endfn setAllComponentTriggerTarget__Q23gui7ManagerFb + +# .text:0x8D0 | 0x813691E8 | size: 0x8 +# gui::Component::setTriggerTarget(bool) +.fn setTriggerTarget__Q23gui9ComponentFb, global +/* 813691E8 000375E8 98 83 00 7C */ stb r4, 0x7c(r3) +/* 813691EC 000375EC 4E 80 00 20 */ blr +.endfn setTriggerTarget__Q23gui9ComponentFb + +# .text:0x8D8 | 0x813691F0 | size: 0x70 +# gui::Manager::setDraggingButton(unsigned long) +.fn setDraggingButton__Q23gui7ManagerFUl, global +/* 813691F0 000375F0 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 813691F4 000375F4 7C 08 02 A6 */ mflr r0 +/* 813691F8 000375F8 90 01 00 24 */ stw r0, 0x24(r1) +/* 813691FC 000375FC 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369200 00037600 48 29 02 C9 */ bl _savegpr_29 +/* 81369204 00037604 7C 7D 1B 78 */ mr r29, r3 +/* 81369208 00037608 7C 9E 23 78 */ mr r30, r4 +/* 8136920C 0003760C 3B E0 00 00 */ li r31, 0x0 +/* 81369210 00037610 48 00 00 2C */ b .L_8136923C +.L_81369214: +/* 81369214 00037614 38 7D 00 08 */ addi r3, r29, 0x8 +/* 81369218 00037618 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 8136921C 0003761C 48 1A 90 FD */ bl fn_81512318 +/* 81369220 00037620 80 63 00 04 */ lwz r3, 0x4(r3) +/* 81369224 00037624 7F C4 F3 78 */ mr r4, r30 +/* 81369228 00037628 81 83 00 00 */ lwz r12, 0x0(r3) +/* 8136922C 0003762C 81 8C 00 44 */ lwz r12, 0x44(r12) +/* 81369230 00037630 7D 89 03 A6 */ mtctr r12 +/* 81369234 00037634 4E 80 04 21 */ bctrl +/* 81369238 00037638 3B FF 00 01 */ addi r31, r31, 0x1 +.L_8136923C: +/* 8136923C 0003763C A0 1D 00 10 */ lhz r0, 0x10(r29) +/* 81369240 00037640 7C 1F 00 40 */ cmplw r31, r0 +/* 81369244 00037644 41 80 FF D0 */ blt .L_81369214 +/* 81369248 00037648 39 61 00 20 */ addi r11, r1, 0x20 +/* 8136924C 0003764C 48 29 02 C9 */ bl _restgpr_29 +/* 81369250 00037650 80 01 00 24 */ lwz r0, 0x24(r1) +/* 81369254 00037654 7C 08 03 A6 */ mtlr r0 +/* 81369258 00037658 38 21 00 20 */ addi r1, r1, 0x20 +/* 8136925C 0003765C 4E 80 00 20 */ blr +.endfn setDraggingButton__Q23gui7ManagerFUl + +# .text:0x948 | 0x81369260 | size: 0x8 +# gui::Component::setDraggingButton(unsigned long) +.fn setDraggingButton__Q23gui9ComponentFUl, global +/* 81369260 00037660 90 83 00 74 */ stw r4, 0x74(r3) +/* 81369264 00037664 4E 80 00 20 */ blr +.endfn setDraggingButton__Q23gui9ComponentFUl + +# .text:0x950 | 0x81369268 | size: 0xEC +# gui::PaneManager::~PaneManager() +.fn __dt__Q23gui11PaneManagerFv, global +/* 81369268 00037668 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 8136926C 0003766C 7C 08 02 A6 */ mflr r0 +/* 81369270 00037670 90 01 00 24 */ stw r0, 0x24(r1) +/* 81369274 00037674 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369278 00037678 48 29 02 51 */ bl _savegpr_29 +/* 8136927C 0003767C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369280 00037680 7C 7D 1B 78 */ mr r29, r3 +/* 81369284 00037684 7C 9E 23 78 */ mr r30, r4 +/* 81369288 00037688 41 82 00 B0 */ beq .L_81369338 +/* 8136928C 0003768C 3C A0 81 64 */ lis r5, lbl_81642784@ha +/* 81369290 00037690 38 80 00 00 */ li r4, 0x0 +/* 81369294 00037694 38 A5 27 84 */ addi r5, r5, lbl_81642784@l +/* 81369298 00037698 90 A3 00 00 */ stw r5, 0x0(r3) +/* 8136929C 0003769C 38 63 00 18 */ addi r3, r3, 0x18 +/* 813692A0 000376A0 48 1A 90 3D */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 813692A4 000376A4 7C 7F 1B 78 */ mr r31, r3 +/* 813692A8 000376A8 48 00 00 6C */ b .L_81369314 +.L_813692AC: +/* 813692AC 000376AC 7F E4 FB 78 */ mr r4, r31 +/* 813692B0 000376B0 38 7D 00 18 */ addi r3, r29, 0x18 +/* 813692B4 000376B4 48 1A 8F BD */ bl List_Remove__Q24nw4r2utFPQ34nw4r2ut4ListPv +/* 813692B8 000376B8 80 7D 00 14 */ lwz r3, 0x14(r29) +/* 813692BC 000376BC 2C 03 00 00 */ cmpwi r3, 0x0 +/* 813692C0 000376C0 41 82 00 1C */ beq .L_813692DC +/* 813692C4 000376C4 80 9F 00 04 */ lwz r4, 0x4(r31) +/* 813692C8 000376C8 48 1F 23 B1 */ bl fn_8155B678 +/* 813692CC 000376CC 80 7D 00 14 */ lwz r3, 0x14(r29) +/* 813692D0 000376D0 7F E4 FB 78 */ mr r4, r31 +/* 813692D4 000376D4 48 1F 23 A5 */ bl fn_8155B678 +/* 813692D8 000376D8 48 00 00 2C */ b .L_81369304 +.L_813692DC: +/* 813692DC 000376DC 80 7F 00 04 */ lwz r3, 0x4(r31) +/* 813692E0 000376E0 2C 03 00 00 */ cmpwi r3, 0x0 +/* 813692E4 000376E4 41 82 00 18 */ beq .L_813692FC +/* 813692E8 000376E8 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813692EC 000376EC 38 80 00 01 */ li r4, 0x1 +/* 813692F0 000376F0 81 8C 00 1C */ lwz r12, 0x1c(r12) +/* 813692F4 000376F4 7D 89 03 A6 */ mtctr r12 +/* 813692F8 000376F8 4E 80 04 21 */ bctrl +.L_813692FC: +/* 813692FC 000376FC 7F E3 FB 78 */ mr r3, r31 +/* 81369300 00037700 48 28 ED E5 */ bl __dl__FPv +.L_81369304: +/* 81369304 00037704 38 7D 00 18 */ addi r3, r29, 0x18 +/* 81369308 00037708 38 80 00 00 */ li r4, 0x0 +/* 8136930C 0003770C 48 1A 8F D1 */ bl List_GetNext__Q24nw4r2utFPCQ34nw4r2ut4ListPCv +/* 81369310 00037710 7C 7F 1B 78 */ mr r31, r3 +.L_81369314: +/* 81369314 00037714 2C 1F 00 00 */ cmpwi r31, 0x0 +/* 81369318 00037718 40 82 FF 94 */ bne .L_813692AC +/* 8136931C 0003771C 7F A3 EB 78 */ mr r3, r29 +/* 81369320 00037720 38 80 00 00 */ li r4, 0x0 +/* 81369324 00037724 4B FF F9 21 */ bl __dt__Q23gui7ManagerFv +/* 81369328 00037728 2C 1E 00 00 */ cmpwi r30, 0x0 +/* 8136932C 0003772C 40 81 00 0C */ ble .L_81369338 +/* 81369330 00037730 7F A3 EB 78 */ mr r3, r29 +/* 81369334 00037734 48 28 ED B1 */ bl __dl__FPv +.L_81369338: +/* 81369338 00037738 39 61 00 20 */ addi r11, r1, 0x20 +/* 8136933C 0003773C 7F A3 EB 78 */ mr r3, r29 +/* 81369340 00037740 48 29 01 D5 */ bl _restgpr_29 +/* 81369344 00037744 80 01 00 24 */ lwz r0, 0x24(r1) +/* 81369348 00037748 7C 08 03 A6 */ mtlr r0 +/* 8136934C 0003774C 38 21 00 20 */ addi r1, r1, 0x20 +/* 81369350 00037750 4E 80 00 20 */ blr +.endfn __dt__Q23gui11PaneManagerFv + +# .text:0xA3C | 0x81369354 | size: 0x40 +# gui::PaneComponent::~PaneComponent() +.fn __dt__Q23gui13PaneComponentFv, global +/* 81369354 00037754 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 81369358 00037758 7C 08 02 A6 */ mflr r0 +/* 8136935C 0003775C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369360 00037760 90 01 00 14 */ stw r0, 0x14(r1) +/* 81369364 00037764 93 E1 00 0C */ stw r31, 0xc(r1) +/* 81369368 00037768 7C 7F 1B 78 */ mr r31, r3 +/* 8136936C 0003776C 41 82 00 10 */ beq .L_8136937C +/* 81369370 00037770 2C 04 00 00 */ cmpwi r4, 0x0 +/* 81369374 00037774 40 81 00 08 */ ble .L_8136937C +/* 81369378 00037778 48 28 ED 6D */ bl __dl__FPv +.L_8136937C: +/* 8136937C 0003777C 7F E3 FB 78 */ mr r3, r31 +/* 81369380 00037780 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 81369384 00037784 80 01 00 14 */ lwz r0, 0x14(r1) +/* 81369388 00037788 7C 08 03 A6 */ mtlr r0 +/* 8136938C 0003778C 38 21 00 10 */ addi r1, r1, 0x10 +/* 81369390 00037790 4E 80 00 20 */ blr +.endfn __dt__Q23gui13PaneComponentFv + +# .text:0xA7C | 0x81369394 | size: 0x40 +# gui::Component::~Component() +.fn __dt__Q23gui9ComponentFv, global +/* 81369394 00037794 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 81369398 00037798 7C 08 02 A6 */ mflr r0 +/* 8136939C 0003779C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 813693A0 000377A0 90 01 00 14 */ stw r0, 0x14(r1) +/* 813693A4 000377A4 93 E1 00 0C */ stw r31, 0xc(r1) +/* 813693A8 000377A8 7C 7F 1B 78 */ mr r31, r3 +/* 813693AC 000377AC 41 82 00 10 */ beq .L_813693BC +/* 813693B0 000377B0 2C 04 00 00 */ cmpwi r4, 0x0 +/* 813693B4 000377B4 40 81 00 08 */ ble .L_813693BC +/* 813693B8 000377B8 48 28 ED 2D */ bl __dl__FPv +.L_813693BC: +/* 813693BC 000377BC 7F E3 FB 78 */ mr r3, r31 +/* 813693C0 000377C0 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 813693C4 000377C4 80 01 00 14 */ lwz r0, 0x14(r1) +/* 813693C8 000377C8 7C 08 03 A6 */ mtlr r0 +/* 813693CC 000377CC 38 21 00 10 */ addi r1, r1, 0x10 +/* 813693D0 000377D0 4E 80 00 20 */ blr +.endfn __dt__Q23gui9ComponentFv + +# .text:0xABC | 0x813693D4 | size: 0x20 +# gui::PaneManager::createLayoutScene(const nw4r::lyt::Layout&) +.fn createLayoutScene__Q23gui11PaneManagerFRCQ34nw4r3lyt6Layout, global +/* 813693D4 000377D4 38 00 00 00 */ li r0, 0x0 +/* 813693D8 000377D8 80 84 00 10 */ lwz r4, 0x10(r4) +/* 813693DC 000377DC 90 0D A7 40 */ stw r0, lbl_81698780@sda21(r0) +/* 813693E0 000377E0 38 84 00 10 */ addi r4, r4, 0x10 +/* 813693E4 000377E4 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813693E8 000377E8 81 8C 00 58 */ lwz r12, 0x58(r12) +/* 813693EC 000377EC 7D 89 03 A6 */ mtctr r12 +/* 813693F0 000377F0 4E 80 04 20 */ bctr +.endfn createLayoutScene__Q23gui11PaneManagerFRCQ34nw4r3lyt6Layout + +# .text:0xADC | 0x813693F4 | size: 0x1E4 +# gui::PaneManager::walkInChildren(nw4r::ut::LinkList&) +.fn "walkInChildren__Q23gui11PaneManagerFRQ34nw4r2ut28LinkList", global +/* 813693F4 000377F4 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 813693F8 000377F8 7C 08 02 A6 */ mflr r0 +/* 813693FC 000377FC 90 01 00 24 */ stw r0, 0x24(r1) +/* 81369400 00037800 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369404 00037804 48 29 00 BD */ bl _savegpr_27 +/* 81369408 00037808 83 E4 00 04 */ lwz r31, 0x4(r4) +/* 8136940C 0003780C 7C 7B 1B 78 */ mr r27, r3 +/* 81369410 00037810 3B C4 00 04 */ addi r30, r4, 0x4 +/* 81369414 00037814 48 00 01 A4 */ b .L_813695B8 +.L_81369418: +/* 81369418 00037818 80 7B 00 14 */ lwz r3, 0x14(r27) +/* 8136941C 0003781C 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369420 00037820 41 82 00 50 */ beq .L_81369470 +/* 81369424 00037824 38 80 00 98 */ li r4, 0x98 +/* 81369428 00037828 48 1F 22 41 */ bl fn_8155B668 +/* 8136942C 0003782C 7C 7C 1B 78 */ mr r28, r3 +/* 81369430 00037830 80 7B 00 14 */ lwz r3, 0x14(r27) +/* 81369434 00037834 38 80 00 10 */ li r4, 0x10 +/* 81369438 00037838 48 1F 22 31 */ bl fn_8155B668 +/* 8136943C 0003783C 2C 1C 00 00 */ cmpwi r28, 0x0 +/* 81369440 00037840 7C 7D 1B 78 */ mr r29, r3 +/* 81369444 00037844 41 82 00 14 */ beq .L_81369458 +/* 81369448 00037848 80 8D A7 40 */ lwz r4, lbl_81698780@sda21(r0) +/* 8136944C 0003784C 7F 83 E3 78 */ mr r3, r28 +/* 81369450 00037850 48 00 01 89 */ bl __ct__Q23gui13PaneComponentFUl +/* 81369454 00037854 7C 7C 1B 78 */ mr r28, r3 +.L_81369458: +/* 81369458 00037858 2C 1D 00 00 */ cmpwi r29, 0x0 +/* 8136945C 0003785C 41 82 00 54 */ beq .L_813694B0 +/* 81369460 00037860 38 1F FF FC */ subi r0, r31, 0x4 +/* 81369464 00037864 90 1D 00 00 */ stw r0, 0x0(r29) +/* 81369468 00037868 93 9D 00 04 */ stw r28, 0x4(r29) +/* 8136946C 0003786C 48 00 00 44 */ b .L_813694B0 +.L_81369470: +/* 81369470 00037870 38 60 00 98 */ li r3, 0x98 +/* 81369474 00037874 48 28 EC 29 */ bl __nw__FUl +/* 81369478 00037878 2C 03 00 00 */ cmpwi r3, 0x0 +/* 8136947C 0003787C 7C 7C 1B 78 */ mr r28, r3 +/* 81369480 00037880 41 82 00 10 */ beq .L_81369490 +/* 81369484 00037884 80 8D A7 40 */ lwz r4, lbl_81698780@sda21(r0) +/* 81369488 00037888 48 00 01 51 */ bl __ct__Q23gui13PaneComponentFUl +/* 8136948C 0003788C 7C 7C 1B 78 */ mr r28, r3 +.L_81369490: +/* 81369490 00037890 38 60 00 10 */ li r3, 0x10 +/* 81369494 00037894 48 28 EC 09 */ bl __nw__FUl +/* 81369498 00037898 2C 03 00 00 */ cmpwi r3, 0x0 +/* 8136949C 0003789C 41 82 00 10 */ beq .L_813694AC +/* 813694A0 000378A0 38 1F FF FC */ subi r0, r31, 0x4 +/* 813694A4 000378A4 90 03 00 00 */ stw r0, 0x0(r3) +/* 813694A8 000378A8 93 83 00 04 */ stw r28, 0x4(r3) +.L_813694AC: +/* 813694AC 000378AC 7C 7D 1B 78 */ mr r29, r3 +.L_813694B0: +/* 813694B0 000378B0 7F A4 EB 78 */ mr r4, r29 +/* 813694B4 000378B4 38 7B 00 18 */ addi r3, r27, 0x18 +/* 813694B8 000378B8 48 1A 8B BD */ bl List_Append__Q24nw4r2utFPQ34nw4r2ut4ListPv +/* 813694BC 000378BC 80 8D A7 40 */ lwz r4, lbl_81698780@sda21(r0) +/* 813694C0 000378C0 3B BF FF FC */ subi r29, r31, 0x4 +/* 813694C4 000378C4 7F 83 E3 78 */ mr r3, r28 +/* 813694C8 000378C8 38 04 00 01 */ addi r0, r4, 0x1 +/* 813694CC 000378CC 7F A4 EB 78 */ mr r4, r29 +/* 813694D0 000378D0 90 0D A7 40 */ stw r0, lbl_81698780@sda21(r0) +/* 813694D4 000378D4 81 9C 00 00 */ lwz r12, 0x0(r28) +/* 813694D8 000378D8 81 8C 00 6C */ lwz r12, 0x6c(r12) +/* 813694DC 000378DC 7D 89 03 A6 */ mtctr r12 +/* 813694E0 000378E0 4E 80 04 21 */ bctrl +/* 813694E4 000378E4 81 9D 00 00 */ lwz r12, 0x0(r29) +/* 813694E8 000378E8 7F A3 EB 78 */ mr r3, r29 +/* 813694EC 000378EC 81 8C 00 0C */ lwz r12, 0xc(r12) +/* 813694F0 000378F0 7D 89 03 A6 */ mtctr r12 +/* 813694F4 000378F4 4E 80 04 21 */ bctrl +/* 813694F8 000378F8 38 8D AF 70 */ li r4, lbl_81698FB0@sda21 +/* 813694FC 000378FC 48 00 01 5D */ bl IsDerivedFrom__Q44nw4r2ut6detail15RuntimeTypeInfoCFPCQ44nw4r2ut6detail15RuntimeTypeInfo +/* 81369500 00037900 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369504 00037904 41 82 00 0C */ beq .L_81369510 +/* 81369508 00037908 7F A0 EB 78 */ mr r0, r29 +/* 8136950C 0003790C 48 00 00 08 */ b .L_81369514 +.L_81369510: +/* 81369510 00037910 38 00 00 00 */ li r0, 0x0 +.L_81369514: +/* 81369514 00037914 2C 00 00 00 */ cmpwi r0, 0x0 +/* 81369518 00037918 41 82 00 1C */ beq .L_81369534 +/* 8136951C 0003791C 81 9C 00 00 */ lwz r12, 0x0(r28) +/* 81369520 00037920 7F 83 E3 78 */ mr r3, r28 +/* 81369524 00037924 38 80 00 01 */ li r4, 0x1 +/* 81369528 00037928 81 8C 00 54 */ lwz r12, 0x54(r12) +/* 8136952C 0003792C 7D 89 03 A6 */ mtctr r12 +/* 81369530 00037930 4E 80 04 21 */ bctrl +.L_81369534: +/* 81369534 00037934 81 9D 00 00 */ lwz r12, 0x0(r29) +/* 81369538 00037938 7F A3 EB 78 */ mr r3, r29 +/* 8136953C 0003793C 81 8C 00 0C */ lwz r12, 0xc(r12) +/* 81369540 00037940 7D 89 03 A6 */ mtctr r12 +/* 81369544 00037944 4E 80 04 21 */ bctrl +/* 81369548 00037948 38 8D AF 80 */ li r4, lbl_81698FC0@sda21 +/* 8136954C 0003794C 48 00 01 0D */ bl IsDerivedFrom__Q44nw4r2ut6detail15RuntimeTypeInfoCFPCQ44nw4r2ut6detail15RuntimeTypeInfo +/* 81369550 00037950 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369554 00037954 41 82 00 0C */ beq .L_81369560 +/* 81369558 00037958 7F A0 EB 78 */ mr r0, r29 +/* 8136955C 0003795C 48 00 00 08 */ b .L_81369564 +.L_81369560: +/* 81369560 00037960 38 00 00 00 */ li r0, 0x0 +.L_81369564: +/* 81369564 00037964 2C 00 00 00 */ cmpwi r0, 0x0 +/* 81369568 00037968 41 82 00 1C */ beq .L_81369584 +/* 8136956C 0003796C 81 9C 00 00 */ lwz r12, 0x0(r28) +/* 81369570 00037970 7F 83 E3 78 */ mr r3, r28 +/* 81369574 00037974 38 80 00 01 */ li r4, 0x1 +/* 81369578 00037978 81 8C 00 54 */ lwz r12, 0x54(r12) +/* 8136957C 0003797C 7D 89 03 A6 */ mtctr r12 +/* 81369580 00037980 4E 80 04 21 */ bctrl +.L_81369584: +/* 81369584 00037984 81 9B 00 00 */ lwz r12, 0x0(r27) +/* 81369588 00037988 7F 63 DB 78 */ mr r3, r27 +/* 8136958C 0003798C 7F 84 E3 78 */ mr r4, r28 +/* 81369590 00037990 81 8C 00 20 */ lwz r12, 0x20(r12) +/* 81369594 00037994 7D 89 03 A6 */ mtctr r12 +/* 81369598 00037998 4E 80 04 21 */ bctrl +/* 8136959C 0003799C 81 9B 00 00 */ lwz r12, 0x0(r27) +/* 813695A0 000379A0 7F 63 DB 78 */ mr r3, r27 +/* 813695A4 000379A4 38 9D 00 10 */ addi r4, r29, 0x10 +/* 813695A8 000379A8 81 8C 00 58 */ lwz r12, 0x58(r12) +/* 813695AC 000379AC 7D 89 03 A6 */ mtctr r12 +/* 813695B0 000379B0 4E 80 04 21 */ bctrl +/* 813695B4 000379B4 83 FF 00 00 */ lwz r31, 0x0(r31) +.L_813695B8: +/* 813695B8 000379B8 7C 1F F0 40 */ cmplw r31, r30 +/* 813695BC 000379BC 40 82 FE 5C */ bne .L_81369418 +/* 813695C0 000379C0 39 61 00 20 */ addi r11, r1, 0x20 +/* 813695C4 000379C4 48 28 FF 49 */ bl _restgpr_27 +/* 813695C8 000379C8 80 01 00 24 */ lwz r0, 0x24(r1) +/* 813695CC 000379CC 7C 08 03 A6 */ mtlr r0 +/* 813695D0 000379D0 38 21 00 20 */ addi r1, r1, 0x20 +/* 813695D4 000379D4 4E 80 00 20 */ blr +.endfn "walkInChildren__Q23gui11PaneManagerFRQ34nw4r2ut28LinkList" + +# .text:0xCC0 | 0x813695D8 | size: 0x78 +# gui::PaneComponent::PaneComponent(unsigned long) +.fn __ct__Q23gui13PaneComponentFUl, global +/* 813695D8 000379D8 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 813695DC 000379DC 7C 08 02 A6 */ mflr r0 +/* 813695E0 000379E0 3D 80 81 64 */ lis r12, lbl_81642824@ha +/* 813695E4 000379E4 3C A0 00 01 */ lis r5, 0x1 +/* 813695E8 000379E8 90 01 00 14 */ stw r0, 0x14(r1) +/* 813695EC 000379EC 39 8C 28 24 */ addi r12, r12, lbl_81642824@l +/* 813695F0 000379F0 38 05 FF FF */ subi r0, r5, 0x1 +/* 813695F4 000379F4 93 E1 00 0C */ stw r31, 0xc(r1) +/* 813695F8 000379F8 3B E0 00 00 */ li r31, 0x0 +/* 813695FC 000379FC 93 C1 00 08 */ stw r30, 0x8(r1) +/* 81369600 00037A00 7C 7E 1B 78 */ mr r30, r3 +/* 81369604 00037A04 91 83 00 00 */ stw r12, 0x0(r3) +/* 81369608 00037A08 90 03 00 74 */ stw r0, 0x74(r3) +/* 8136960C 00037A0C 90 83 00 78 */ stw r4, 0x78(r3) +/* 81369610 00037A10 9B E3 00 7C */ stb r31, 0x7c(r3) +/* 81369614 00037A14 93 E3 00 80 */ stw r31, 0x80(r3) +/* 81369618 00037A18 81 8C 00 0C */ lwz r12, 0xc(r12) +/* 8136961C 00037A1C 7D 89 03 A6 */ mtctr r12 +/* 81369620 00037A20 4E 80 04 21 */ bctrl +/* 81369624 00037A24 3C 60 81 64 */ lis r3, lbl_81642710@ha +/* 81369628 00037A28 93 FE 00 94 */ stw r31, 0x94(r30) +/* 8136962C 00037A2C 38 63 27 10 */ addi r3, r3, lbl_81642710@l +/* 81369630 00037A30 90 7E 00 00 */ stw r3, 0x0(r30) +/* 81369634 00037A34 7F C3 F3 78 */ mr r3, r30 +/* 81369638 00037A38 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 8136963C 00037A3C 83 C1 00 08 */ lwz r30, 0x8(r1) +/* 81369640 00037A40 80 01 00 14 */ lwz r0, 0x14(r1) +/* 81369644 00037A44 7C 08 03 A6 */ mtlr r0 +/* 81369648 00037A48 38 21 00 10 */ addi r1, r1, 0x10 +/* 8136964C 00037A4C 4E 80 00 20 */ blr +.endfn __ct__Q23gui13PaneComponentFUl + +# .text:0xD38 | 0x81369650 | size: 0x8 +# gui::PaneComponent::setPane(nw4r::lyt::Pane*) +.fn setPane__Q23gui13PaneComponentFPQ34nw4r3lyt4Pane, global +/* 81369650 00037A50 90 83 00 94 */ stw r4, 0x94(r3) +/* 81369654 00037A54 4E 80 00 20 */ blr +.endfn setPane__Q23gui13PaneComponentFPQ34nw4r3lyt4Pane + +# .text:0xD40 | 0x81369658 | size: 0x28 +# nw4r::ut::detail::RuntimeTypeInfo::IsDerivedFrom(const nw4r::ut::detail::RuntimeTypeInfo*) const +.fn IsDerivedFrom__Q44nw4r2ut6detail15RuntimeTypeInfoCFPCQ44nw4r2ut6detail15RuntimeTypeInfo, global +/* 81369658 00037A58 48 00 00 18 */ b .L_81369670 +.L_8136965C: +/* 8136965C 00037A5C 7C 03 20 40 */ cmplw r3, r4 +/* 81369660 00037A60 40 82 00 0C */ bne .L_8136966C +/* 81369664 00037A64 38 60 00 01 */ li r3, 0x1 +/* 81369668 00037A68 4E 80 00 20 */ blr +.L_8136966C: +/* 8136966C 00037A6C 80 63 00 00 */ lwz r3, 0x0(r3) +.L_81369670: +/* 81369670 00037A70 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369674 00037A74 40 82 FF E8 */ bne .L_8136965C +/* 81369678 00037A78 38 60 00 00 */ li r3, 0x0 +/* 8136967C 00037A7C 4E 80 00 20 */ blr +.endfn IsDerivedFrom__Q44nw4r2ut6detail15RuntimeTypeInfoCFPCQ44nw4r2ut6detail15RuntimeTypeInfo + +# .text:0xD68 | 0x81369680 | size: 0x70 +# gui::PaneManager::getPaneComponentByPane(nw4r::lyt::Pane*) +.fn getPaneComponentByPane__Q23gui11PaneManagerFPQ34nw4r3lyt4Pane, global +/* 81369680 00037A80 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 81369684 00037A84 7C 08 02 A6 */ mflr r0 +/* 81369688 00037A88 90 01 00 24 */ stw r0, 0x24(r1) +/* 8136968C 00037A8C 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369690 00037A90 48 28 FE 39 */ bl _savegpr_29 +/* 81369694 00037A94 7C 7D 1B 78 */ mr r29, r3 +/* 81369698 00037A98 7C 9E 23 78 */ mr r30, r4 +/* 8136969C 00037A9C 3B E0 00 00 */ li r31, 0x0 +/* 813696A0 00037AA0 48 00 00 28 */ b .L_813696C8 +.L_813696A4: +/* 813696A4 00037AA4 38 7D 00 18 */ addi r3, r29, 0x18 +/* 813696A8 00037AA8 57 E4 04 3E */ clrlwi r4, r31, 16 +/* 813696AC 00037AAC 48 1A 8C 6D */ bl fn_81512318 +/* 813696B0 00037AB0 80 03 00 00 */ lwz r0, 0x0(r3) +/* 813696B4 00037AB4 7C 00 F0 40 */ cmplw r0, r30 +/* 813696B8 00037AB8 40 82 00 0C */ bne .L_813696C4 +/* 813696BC 00037ABC 80 63 00 04 */ lwz r3, 0x4(r3) +/* 813696C0 00037AC0 48 00 00 18 */ b .L_813696D8 +.L_813696C4: +/* 813696C4 00037AC4 3B FF 00 01 */ addi r31, r31, 0x1 +.L_813696C8: +/* 813696C8 00037AC8 A0 1D 00 10 */ lhz r0, 0x10(r29) +/* 813696CC 00037ACC 7C 1F 00 40 */ cmplw r31, r0 +/* 813696D0 00037AD0 41 80 FF D4 */ blt .L_813696A4 +/* 813696D4 00037AD4 38 60 00 00 */ li r3, 0x0 +.L_813696D8: +/* 813696D8 00037AD8 39 61 00 20 */ addi r11, r1, 0x20 +/* 813696DC 00037ADC 48 28 FE 39 */ bl _restgpr_29 +/* 813696E0 00037AE0 80 01 00 24 */ lwz r0, 0x24(r1) +/* 813696E4 00037AE4 7C 08 03 A6 */ mtlr r0 +/* 813696E8 00037AE8 38 21 00 20 */ addi r1, r1, 0x20 +/* 813696EC 00037AEC 4E 80 00 20 */ blr +.endfn getPaneComponentByPane__Q23gui11PaneManagerFPQ34nw4r3lyt4Pane + +# .text:0xDD8 | 0x813696F0 | size: 0xAC +# gui::PaneManager::setAllBoundingBoxComponentTriggerTarget(bool) +.fn setAllBoundingBoxComponentTriggerTarget__Q23gui11PaneManagerFb, global +/* 813696F0 00037AF0 94 21 FF E0 */ stwu r1, -0x20(r1) +/* 813696F4 00037AF4 7C 08 02 A6 */ mflr r0 +/* 813696F8 00037AF8 90 01 00 24 */ stw r0, 0x24(r1) +/* 813696FC 00037AFC 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369700 00037B00 48 28 FD C1 */ bl _savegpr_27 +/* 81369704 00037B04 7C 7B 1B 78 */ mr r27, r3 +/* 81369708 00037B08 7C 9C 23 78 */ mr r28, r4 +/* 8136970C 00037B0C 3B A0 00 00 */ li r29, 0x0 +/* 81369710 00037B10 48 00 00 68 */ b .L_81369778 +.L_81369714: +/* 81369714 00037B14 38 7B 00 18 */ addi r3, r27, 0x18 +/* 81369718 00037B18 57 A4 04 3E */ clrlwi r4, r29, 16 +/* 8136971C 00037B1C 48 1A 8B FD */ bl fn_81512318 +/* 81369720 00037B20 83 C3 00 00 */ lwz r30, 0x0(r3) +/* 81369724 00037B24 7C 7F 1B 78 */ mr r31, r3 +/* 81369728 00037B28 81 9E 00 00 */ lwz r12, 0x0(r30) +/* 8136972C 00037B2C 7F C3 F3 78 */ mr r3, r30 +/* 81369730 00037B30 81 8C 00 0C */ lwz r12, 0xc(r12) +/* 81369734 00037B34 7D 89 03 A6 */ mtctr r12 +/* 81369738 00037B38 4E 80 04 21 */ bctrl +/* 8136973C 00037B3C 38 8D AF 88 */ li r4, lbl_81698FC8@sda21 +/* 81369740 00037B40 4B FF FF 19 */ bl IsDerivedFrom__Q44nw4r2ut6detail15RuntimeTypeInfoCFPCQ44nw4r2ut6detail15RuntimeTypeInfo +/* 81369744 00037B44 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369748 00037B48 41 82 00 08 */ beq .L_81369750 +/* 8136974C 00037B4C 48 00 00 08 */ b .L_81369754 +.L_81369750: +/* 81369750 00037B50 3B C0 00 00 */ li r30, 0x0 +.L_81369754: +/* 81369754 00037B54 2C 1E 00 00 */ cmpwi r30, 0x0 +/* 81369758 00037B58 41 82 00 1C */ beq .L_81369774 +/* 8136975C 00037B5C 80 7F 00 04 */ lwz r3, 0x4(r31) +/* 81369760 00037B60 7F 84 E3 78 */ mr r4, r28 +/* 81369764 00037B64 81 83 00 00 */ lwz r12, 0x0(r3) +/* 81369768 00037B68 81 8C 00 54 */ lwz r12, 0x54(r12) +/* 8136976C 00037B6C 7D 89 03 A6 */ mtctr r12 +/* 81369770 00037B70 4E 80 04 21 */ bctrl +.L_81369774: +/* 81369774 00037B74 3B BD 00 01 */ addi r29, r29, 0x1 +.L_81369778: +/* 81369778 00037B78 A0 1B 00 10 */ lhz r0, 0x10(r27) +/* 8136977C 00037B7C 7C 1D 00 40 */ cmplw r29, r0 +/* 81369780 00037B80 41 80 FF 94 */ blt .L_81369714 +/* 81369784 00037B84 39 61 00 20 */ addi r11, r1, 0x20 +/* 81369788 00037B88 48 28 FD 85 */ bl _restgpr_27 +/* 8136978C 00037B8C 80 01 00 24 */ lwz r0, 0x24(r1) +/* 81369790 00037B90 7C 08 03 A6 */ mtlr r0 +/* 81369794 00037B94 38 21 00 20 */ addi r1, r1, 0x20 +/* 81369798 00037B98 4E 80 00 20 */ blr +.endfn setAllBoundingBoxComponentTriggerTarget__Q23gui11PaneManagerFb + +# .text:0xE84 | 0x8136979C | size: 0x128 +# gui::PaneComponent::contain(float, float) +.fn contain__Q23gui13PaneComponentFff, global +/* 8136979C 00037B9C 94 21 FF 70 */ stwu r1, -0x90(r1) +/* 813697A0 00037BA0 7C 08 02 A6 */ mflr r0 +/* 813697A4 00037BA4 90 01 00 94 */ stw r0, 0x94(r1) +/* 813697A8 00037BA8 DB E1 00 80 */ stfd f31, 0x80(r1) +/* 813697AC 00037BAC F3 E1 00 88 */ psq_st f31, 0x88(r1), 0, qr0 +/* 813697B0 00037BB0 DB C1 00 70 */ stfd f30, 0x70(r1) +/* 813697B4 00037BB4 F3 C1 00 78 */ psq_st f30, 0x78(r1), 0, qr0 +/* 813697B8 00037BB8 FF C0 08 90 */ fmr f30, f1 +/* 813697BC 00037BBC FF E0 10 90 */ fmr f31, f2 +/* 813697C0 00037BC0 93 E1 00 6C */ stw r31, 0x6c(r1) +/* 813697C4 00037BC4 93 C1 00 68 */ stw r30, 0x68(r1) +/* 813697C8 00037BC8 7C 7E 1B 78 */ mr r30, r3 +/* 813697CC 00037BCC 80 03 00 80 */ lwz r0, 0x80(r3) +/* 813697D0 00037BD0 2C 00 00 00 */ cmpwi r0, 0x0 +/* 813697D4 00037BD4 40 82 00 0C */ bne .L_813697E0 +/* 813697D8 00037BD8 38 60 00 00 */ li r3, 0x0 +/* 813697DC 00037BDC 48 00 00 C0 */ b .L_8136989C +.L_813697E0: +/* 813697E0 00037BE0 7C 03 03 78 */ mr r3, r0 +/* 813697E4 00037BE4 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813697E8 00037BE8 81 8C 00 4C */ lwz r12, 0x4c(r12) +/* 813697EC 00037BEC 7D 89 03 A6 */ mtctr r12 +/* 813697F0 00037BF0 4E 80 04 21 */ bctrl +/* 813697F4 00037BF4 2C 03 00 00 */ cmpwi r3, 0x0 +/* 813697F8 00037BF8 7C 7F 1B 78 */ mr r31, r3 +/* 813697FC 00037BFC 40 82 00 0C */ bne .L_81369808 +/* 81369800 00037C00 38 60 00 00 */ li r3, 0x0 +/* 81369804 00037C04 48 00 00 98 */ b .L_8136989C +.L_81369808: +/* 81369808 00037C08 80 7E 00 94 */ lwz r3, 0x94(r30) +/* 8136980C 00037C0C 38 81 00 30 */ addi r4, r1, 0x30 +/* 81369810 00037C10 38 63 00 84 */ addi r3, r3, 0x84 +/* 81369814 00037C14 48 1D 77 49 */ bl fn_81540F5C +/* 81369818 00037C18 C0 02 82 78 */ lfs f0, lbl_81694678@sda21(r0) +/* 8136981C 00037C1C 38 61 00 30 */ addi r3, r1, 0x30 +/* 81369820 00037C20 D3 C1 00 08 */ stfs f30, 0x8(r1) +/* 81369824 00037C24 38 81 00 08 */ addi r4, r1, 0x8 +/* 81369828 00037C28 38 A1 00 24 */ addi r5, r1, 0x24 +/* 8136982C 00037C2C D3 E1 00 0C */ stfs f31, 0xc(r1) +/* 81369830 00037C30 D0 01 00 10 */ stfs f0, 0x10(r1) +/* 81369834 00037C34 48 1D 7C 89 */ bl fn_815414BC +/* 81369838 00037C38 80 9E 00 94 */ lwz r4, 0x94(r30) +/* 8136983C 00037C3C 7F E5 FB 78 */ mr r5, r31 +/* 81369840 00037C40 38 61 00 14 */ addi r3, r1, 0x14 +/* 81369844 00037C44 48 1B 56 21 */ bl fn_8151EE64 +/* 81369848 00037C48 C0 01 00 14 */ lfs f0, 0x14(r1) +/* 8136984C 00037C4C C0 21 00 24 */ lfs f1, 0x24(r1) +/* 81369850 00037C50 FC 00 08 40 */ fcmpo cr0, f0, f1 +/* 81369854 00037C54 4C 40 13 82 */ cror eq, lt, eq +/* 81369858 00037C58 40 82 00 40 */ bne .L_81369898 +/* 8136985C 00037C5C C0 01 00 1C */ lfs f0, 0x1c(r1) +/* 81369860 00037C60 FC 01 00 40 */ fcmpo cr0, f1, f0 +/* 81369864 00037C64 4C 40 13 82 */ cror eq, lt, eq +/* 81369868 00037C68 40 82 00 30 */ bne .L_81369898 +/* 8136986C 00037C6C C0 01 00 20 */ lfs f0, 0x20(r1) +/* 81369870 00037C70 C0 21 00 28 */ lfs f1, 0x28(r1) +/* 81369874 00037C74 FC 00 08 40 */ fcmpo cr0, f0, f1 +/* 81369878 00037C78 4C 40 13 82 */ cror eq, lt, eq +/* 8136987C 00037C7C 40 82 00 1C */ bne .L_81369898 +/* 81369880 00037C80 C0 01 00 18 */ lfs f0, 0x18(r1) +/* 81369884 00037C84 FC 01 00 40 */ fcmpo cr0, f1, f0 +/* 81369888 00037C88 4C 40 13 82 */ cror eq, lt, eq +/* 8136988C 00037C8C 40 82 00 0C */ bne .L_81369898 +/* 81369890 00037C90 38 60 00 01 */ li r3, 0x1 +/* 81369894 00037C94 48 00 00 08 */ b .L_8136989C +.L_81369898: +/* 81369898 00037C98 38 60 00 00 */ li r3, 0x0 +.L_8136989C: +/* 8136989C 00037C9C E3 E1 00 88 */ psq_l f31, 0x88(r1), 0, qr0 +/* 813698A0 00037CA0 CB E1 00 80 */ lfd f31, 0x80(r1) +/* 813698A4 00037CA4 E3 C1 00 78 */ psq_l f30, 0x78(r1), 0, qr0 +/* 813698A8 00037CA8 CB C1 00 70 */ lfd f30, 0x70(r1) +/* 813698AC 00037CAC 83 E1 00 6C */ lwz r31, 0x6c(r1) +/* 813698B0 00037CB0 80 01 00 94 */ lwz r0, 0x94(r1) +/* 813698B4 00037CB4 83 C1 00 68 */ lwz r30, 0x68(r1) +/* 813698B8 00037CB8 7C 08 03 A6 */ mtlr r0 +/* 813698BC 00037CBC 38 21 00 90 */ addi r1, r1, 0x90 +/* 813698C0 00037CC0 4E 80 00 20 */ blr +.endfn contain__Q23gui13PaneComponentFff + +# .text:0xFAC | 0x813698C4 | size: 0x18C +# gui::PaneComponent::draw() +.fn draw__Q23gui13PaneComponentFv, global +/* 813698C4 00037CC4 94 21 FF C0 */ stwu r1, -0x40(r1) +/* 813698C8 00037CC8 7C 08 02 A6 */ mflr r0 +/* 813698CC 00037CCC 90 01 00 44 */ stw r0, 0x44(r1) +/* 813698D0 00037CD0 DB E1 00 30 */ stfd f31, 0x30(r1) +/* 813698D4 00037CD4 F3 E1 00 38 */ psq_st f31, 0x38(r1), 0, qr0 +/* 813698D8 00037CD8 DB C1 00 20 */ stfd f30, 0x20(r1) +/* 813698DC 00037CDC F3 C1 00 28 */ psq_st f30, 0x28(r1), 0, qr0 +/* 813698E0 00037CE0 93 E1 00 1C */ stw r31, 0x1c(r1) +/* 813698E4 00037CE4 7C 7F 1B 78 */ mr r31, r3 +/* 813698E8 00037CE8 80 63 00 80 */ lwz r3, 0x80(r3) +/* 813698EC 00037CEC 81 83 00 00 */ lwz r12, 0x0(r3) +/* 813698F0 00037CF0 81 8C 00 4C */ lwz r12, 0x4c(r12) +/* 813698F4 00037CF4 7D 89 03 A6 */ mtctr r12 +/* 813698F8 00037CF8 4E 80 04 21 */ bctrl +/* 813698FC 00037CFC 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369900 00037D00 41 82 01 2C */ beq .L_81369A2C +/* 81369904 00037D04 80 7F 00 94 */ lwz r3, 0x94(r31) +/* 81369908 00037D08 88 A2 82 7C */ lbz r5, lbl_8169467C@sda21(r0) +/* 8136990C 00037D0C C0 23 00 4C */ lfs f1, 0x4c(r3) +/* 81369910 00037D10 C0 03 00 50 */ lfs f0, 0x50(r3) +/* 81369914 00037D14 C3 E3 00 90 */ lfs f31, 0x90(r3) +/* 81369918 00037D18 C3 C3 00 A0 */ lfs f30, 0xa0(r3) +/* 8136991C 00037D1C 88 82 82 7D */ lbz r4, lbl_8169467D@sda21(r0) +/* 81369920 00037D20 88 62 82 7E */ lbz r3, lbl_8169467E@sda21(r0) +/* 81369924 00037D24 88 02 82 7F */ lbz r0, lbl_8169467F@sda21(r0) +/* 81369928 00037D28 98 A1 00 08 */ stb r5, 0x8(r1) +/* 8136992C 00037D2C 98 81 00 09 */ stb r4, 0x9(r1) +/* 81369930 00037D30 98 61 00 0A */ stb r3, 0xa(r1) +/* 81369934 00037D34 98 01 00 0B */ stb r0, 0xb(r1) +/* 81369938 00037D38 88 1F 00 04 */ lbz r0, 0x4(r31) +/* 8136993C 00037D3C D0 21 00 0C */ stfs f1, 0xc(r1) +/* 81369940 00037D40 2C 00 00 00 */ cmpwi r0, 0x0 +/* 81369944 00037D44 D0 01 00 10 */ stfs f0, 0x10(r1) +/* 81369948 00037D48 41 82 00 14 */ beq .L_8136995C +/* 8136994C 00037D4C 38 60 00 00 */ li r3, 0x0 +/* 81369950 00037D50 38 00 00 FF */ li r0, 0xff +/* 81369954 00037D54 98 61 00 08 */ stb r3, 0x8(r1) +/* 81369958 00037D58 98 01 00 0A */ stb r0, 0xa(r1) +.L_8136995C: +/* 8136995C 00037D5C C0 22 82 80 */ lfs f1, lbl_81694680@sda21(r0) +/* 81369960 00037D60 38 81 00 08 */ addi r4, r1, 0x8 +/* 81369964 00037D64 C0 01 00 10 */ lfs f0, 0x10(r1) +/* 81369968 00037D68 38 60 00 08 */ li r3, 0x8 +/* 8136996C 00037D6C C0 41 00 0C */ lfs f2, 0xc(r1) +/* 81369970 00037D70 EC 00 00 72 */ fmuls f0, f0, f1 +/* 81369974 00037D74 C0 A2 82 78 */ lfs f5, lbl_81694678@sda21(r0) +/* 81369978 00037D78 EC 62 00 72 */ fmuls f3, f2, f1 +/* 8136997C 00037D7C EC 5E 00 28 */ fsubs f2, f30, f0 +/* 81369980 00037D80 EC 3F 18 28 */ fsubs f1, f31, f3 +/* 81369984 00037D84 EC 7F 18 2A */ fadds f3, f31, f3 +/* 81369988 00037D88 FC 80 10 90 */ fmr f4, f2 +/* 8136998C 00037D8C 4B FF ED CD */ bl iplCSFlags_81368758 +/* 81369990 00037D90 C0 21 00 0C */ lfs f1, 0xc(r1) +/* 81369994 00037D94 38 81 00 08 */ addi r4, r1, 0x8 +/* 81369998 00037D98 C0 42 82 80 */ lfs f2, lbl_81694680@sda21(r0) +/* 8136999C 00037D9C 38 60 00 08 */ li r3, 0x8 +/* 813699A0 00037DA0 C0 01 00 10 */ lfs f0, 0x10(r1) +/* 813699A4 00037DA4 EC 21 00 B2 */ fmuls f1, f1, f2 +/* 813699A8 00037DA8 C0 A2 82 78 */ lfs f5, lbl_81694678@sda21(r0) +/* 813699AC 00037DAC EC 00 00 B2 */ fmuls f0, f0, f2 +/* 813699B0 00037DB0 EC 3F 08 2A */ fadds f1, f31, f1 +/* 813699B4 00037DB4 EC 5E 00 28 */ fsubs f2, f30, f0 +/* 813699B8 00037DB8 EC 9E 00 2A */ fadds f4, f30, f0 +/* 813699BC 00037DBC FC 60 08 90 */ fmr f3, f1 +/* 813699C0 00037DC0 4B FF ED 99 */ bl iplCSFlags_81368758 +/* 813699C4 00037DC4 C0 22 82 80 */ lfs f1, lbl_81694680@sda21(r0) +/* 813699C8 00037DC8 38 81 00 08 */ addi r4, r1, 0x8 +/* 813699CC 00037DCC C0 01 00 10 */ lfs f0, 0x10(r1) +/* 813699D0 00037DD0 38 60 00 08 */ li r3, 0x8 +/* 813699D4 00037DD4 C0 41 00 0C */ lfs f2, 0xc(r1) +/* 813699D8 00037DD8 EC 00 00 72 */ fmuls f0, f0, f1 +/* 813699DC 00037DDC C0 A2 82 78 */ lfs f5, lbl_81694678@sda21(r0) +/* 813699E0 00037DE0 EC 62 00 72 */ fmuls f3, f2, f1 +/* 813699E4 00037DE4 EC 5E 00 2A */ fadds f2, f30, f0 +/* 813699E8 00037DE8 EC 3F 18 2A */ fadds f1, f31, f3 +/* 813699EC 00037DEC EC 7F 18 28 */ fsubs f3, f31, f3 +/* 813699F0 00037DF0 FC 80 10 90 */ fmr f4, f2 +/* 813699F4 00037DF4 4B FF ED 65 */ bl iplCSFlags_81368758 +/* 813699F8 00037DF8 C0 21 00 0C */ lfs f1, 0xc(r1) +/* 813699FC 00037DFC 38 81 00 08 */ addi r4, r1, 0x8 +/* 81369A00 00037E00 C0 42 82 80 */ lfs f2, lbl_81694680@sda21(r0) +/* 81369A04 00037E04 38 60 00 08 */ li r3, 0x8 +/* 81369A08 00037E08 C0 01 00 10 */ lfs f0, 0x10(r1) +/* 81369A0C 00037E0C EC 21 00 B2 */ fmuls f1, f1, f2 +/* 81369A10 00037E10 C0 A2 82 78 */ lfs f5, lbl_81694678@sda21(r0) +/* 81369A14 00037E14 EC 00 00 B2 */ fmuls f0, f0, f2 +/* 81369A18 00037E18 EC 3F 08 28 */ fsubs f1, f31, f1 +/* 81369A1C 00037E1C EC 5E 00 2A */ fadds f2, f30, f0 +/* 81369A20 00037E20 EC 9E 00 28 */ fsubs f4, f30, f0 +/* 81369A24 00037E24 FC 60 08 90 */ fmr f3, f1 +/* 81369A28 00037E28 4B FF ED 31 */ bl iplCSFlags_81368758 +.L_81369A2C: +/* 81369A2C 00037E2C E3 E1 00 38 */ psq_l f31, 0x38(r1), 0, qr0 +/* 81369A30 00037E30 CB E1 00 30 */ lfd f31, 0x30(r1) +/* 81369A34 00037E34 E3 C1 00 28 */ psq_l f30, 0x28(r1), 0, qr0 +/* 81369A38 00037E38 CB C1 00 20 */ lfd f30, 0x20(r1) +/* 81369A3C 00037E3C 80 01 00 44 */ lwz r0, 0x44(r1) +/* 81369A40 00037E40 83 E1 00 1C */ lwz r31, 0x1c(r1) +/* 81369A44 00037E44 7C 08 03 A6 */ mtlr r0 +/* 81369A48 00037E48 38 21 00 40 */ addi r1, r1, 0x40 +/* 81369A4C 00037E4C 4E 80 00 20 */ blr +.endfn draw__Q23gui13PaneComponentFv + +# .text:0x1138 | 0x81369A50 | size: 0x2C +.fn GuiMgr_81369A50, global +/* 81369A50 00037E50 88 03 00 CF */ lbz r0, 0xcf(r3) +/* 81369A54 00037E54 54 00 07 FF */ clrlwi. r0, r0, 31 +/* 81369A58 00037E58 40 82 00 0C */ bne .L_81369A64 +/* 81369A5C 00037E5C 38 60 00 00 */ li r3, 0x0 +/* 81369A60 00037E60 4E 80 00 20 */ blr +.L_81369A64: +/* 81369A64 00037E64 80 63 00 0C */ lwz r3, 0xc(r3) +/* 81369A68 00037E68 2C 03 00 00 */ cmpwi r3, 0x0 +/* 81369A6C 00037E6C 40 82 00 0C */ bne .L_81369A78 +/* 81369A70 00037E70 38 60 00 01 */ li r3, 0x1 +/* 81369A74 00037E74 4E 80 00 20 */ blr +.L_81369A78: +/* 81369A78 00037E78 4B FF FF D8 */ b GuiMgr_81369A50 +.endfn GuiMgr_81369A50 + +# .text:0x1164 | 0x81369A7C | size: 0x4 +.fn GuiMgr_81369A7C, global +/* 81369A7C 00037E7C 4E 80 00 20 */ blr +.endfn GuiMgr_81369A7C + +# .text:0x1168 | 0x81369A80 | size: 0x8 +# gui::PaneComponent::isVisible() +.fn isVisible__Q23gui13PaneComponentFv, global +/* 81369A80 00037E80 80 63 00 94 */ lwz r3, 0x94(r3) +/* 81369A84 00037E84 4B FF FF CC */ b GuiMgr_81369A50 +.endfn isVisible__Q23gui13PaneComponentFv + +# .text:0x1170 | 0x81369A88 | size: 0x10 +# gui::Component::setFlightDuration(int, unsigned short) +.fn setFlightDuration__Q23gui9ComponentFiUs, global +/* 81369A88 00037E88 54 80 08 3C */ slwi r0, r4, 1 +/* 81369A8C 00037E8C 7C 63 02 14 */ add r3, r3, r0 +/* 81369A90 00037E90 B0 A3 00 84 */ sth r5, 0x84(r3) +/* 81369A94 00037E94 4E 80 00 20 */ blr +.endfn setFlightDuration__Q23gui9ComponentFiUs + +# .text:0x1180 | 0x81369A98 | size: 0x10 +# gui::Component::getFlightDuration(int) +.fn getFlightDuration__Q23gui9ComponentFi, global +/* 81369A98 00037E98 54 80 08 3C */ slwi r0, r4, 1 +/* 81369A9C 00037E9C 7C 63 02 14 */ add r3, r3, r0 +/* 81369AA0 00037EA0 A0 63 00 84 */ lhz r3, 0x84(r3) +/* 81369AA4 00037EA4 4E 80 00 20 */ blr +.endfn getFlightDuration__Q23gui9ComponentFi + +# .text:0x1190 | 0x81369AA8 | size: 0x8 +# gui::Component::update(int, const KPADStatus*, float, float, void*) +.fn update__Q23gui9ComponentFiPC10KPADStatusffPv, global +/* 81369AA8 00037EA8 38 60 00 00 */ li r3, 0x0 +/* 81369AAC 00037EAC 4E 80 00 20 */ blr +.endfn update__Q23gui9ComponentFiPC10KPADStatusffPv + +# .text:0x1198 | 0x81369AB0 | size: 0xC +# gui::Component::isDragging(int) +.fn isDragging__Q23gui9ComponentFi, global +/* 81369AB0 00037EB0 7C 63 22 14 */ add r3, r3, r4 +/* 81369AB4 00037EB4 88 63 00 0C */ lbz r3, 0xc(r3) +/* 81369AB8 00037EB8 4E 80 00 20 */ blr +.endfn isDragging__Q23gui9ComponentFi + +# 0x81642710..0x81642890 | size: 0x180 +.data +.balign 8 + +# .data:0x0 | 0x81642710 | size: 0x74 +.obj lbl_81642710, global + .4byte 0x00000000 + .4byte 0x00000000 + .4byte create__Q23gui9InterfaceFv + .4byte init__Q23gui9ComponentFv + .4byte calc__Q23gui9InterfaceFv + .4byte draw__Q23gui9InterfaceFRA3_A4_f + .4byte draw__Q23gui13PaneComponentFv + .4byte __dt__Q23gui13PaneComponentFv + .4byte getID__Q23gui9ComponentFv + .4byte isPointed__Q23gui9ComponentFi + .4byte isDragging__Q23gui9ComponentFi + .4byte setPointed__Q23gui9ComponentFib + .4byte onPoint__Q23gui9ComponentFi + .4byte offPoint__Q23gui9ComponentFi + .4byte onDrag__Q23gui9ComponentFff + .4byte onMove__Q23gui9ComponentFiff + .4byte onTrig__Q23gui9ComponentFiUlR3Vec + .4byte setDraggingButton__Q23gui9ComponentFUl + .4byte update__Q23gui9ComponentFiPC10KPADStatusffPv + .4byte update__Q23gui9ComponentFiffUlUlUlPv + .4byte isTriggerTarger__Q23gui9ComponentFv + .4byte setTriggerTarget__Q23gui9ComponentFb + .4byte setManager__Q23gui9ComponentFPQ23gui7Manager + .4byte isVisible__Q23gui13PaneComponentFv + .4byte getFlightDuration__Q23gui9ComponentFi + .4byte setFlightDuration__Q23gui9ComponentFiUs + .4byte contain__Q23gui13PaneComponentFff + .4byte setPane__Q23gui13PaneComponentFPQ34nw4r3lyt4Pane + .4byte getPane__Q23gui13PaneComponentFv +.endobj lbl_81642710 + +# .data:0x74 | 0x81642784 | size: 0x5C +.obj lbl_81642784, global + .4byte 0x00000000 + .4byte 0x00000000 + .4byte create__Q23gui9InterfaceFv + .4byte init__Q23gui7ManagerFv + .4byte calc__Q23gui7ManagerFv + .4byte draw__Q23gui9InterfaceFRA3_A4_f + .4byte draw__Q23gui7ManagerFv + .4byte __dt__Q23gui11PaneManagerFv + .4byte addComponent__Q23gui7ManagerFPQ23gui9Component + .4byte getComponent__Q23gui7ManagerFUl + .4byte update__Q23gui7ManagerFiPC10KPADStatusffPv + .4byte update__Q23gui7ManagerFiffUlUlUlPv + .4byte onEvent__Q23gui7ManagerFUlUliPv + .4byte setAllComponentTriggerTarget__Q23gui7ManagerFb + .4byte setEventHandler__Q23gui7ManagerFPQ23gui12EventHandler + .4byte changeEventHandler__Q23gui7ManagerFPQ23gui12EventHandler + .4byte setDraggingButton__Q23gui7ManagerFUl + .4byte createLayoutScene__Q23gui11PaneManagerFRCQ34nw4r3lyt6Layout + .4byte getPaneComponentByPane__Q23gui11PaneManagerFPQ34nw4r3lyt4Pane + .4byte getDrawInfo__Q23gui11PaneManagerFv + .4byte setDrawInfo__Q23gui11PaneManagerFPCQ34nw4r3lyt8DrawInfo + .4byte setAllBoundingBoxComponentTriggerTarget__Q23gui11PaneManagerFb + .4byte "walkInChildren__Q23gui11PaneManagerFRQ34nw4r2ut28LinkList" +.endobj lbl_81642784 + +# .data:0xD0 | 0x816427E0 | size: 0x44 +.obj lbl_816427E0, global + .4byte 0x00000000 + .4byte 0x00000000 + .4byte create__Q23gui9InterfaceFv + .4byte init__Q23gui7ManagerFv + .4byte calc__Q23gui7ManagerFv + .4byte draw__Q23gui9InterfaceFRA3_A4_f + .4byte draw__Q23gui7ManagerFv + .4byte __dt__Q23gui7ManagerFv + .4byte addComponent__Q23gui7ManagerFPQ23gui9Component + .4byte getComponent__Q23gui7ManagerFUl + .4byte update__Q23gui7ManagerFiPC10KPADStatusffPv + .4byte update__Q23gui7ManagerFiffUlUlUlPv + .4byte onEvent__Q23gui7ManagerFUlUliPv + .4byte setAllComponentTriggerTarget__Q23gui7ManagerFb + .4byte setEventHandler__Q23gui7ManagerFPQ23gui12EventHandler + .4byte changeEventHandler__Q23gui7ManagerFPQ23gui12EventHandler + .4byte setDraggingButton__Q23gui7ManagerFUl +.endobj lbl_816427E0 + +# .data:0x114 | 0x81642824 | size: 0x6C +.obj lbl_81642824, global + .4byte 0x00000000 + .4byte 0x00000000 + .4byte create__Q23gui9InterfaceFv + .4byte init__Q23gui9ComponentFv + .4byte calc__Q23gui9InterfaceFv + .4byte draw__Q23gui9InterfaceFRA3_A4_f + .4byte draw__Q23gui9InterfaceFv + .4byte __dt__Q23gui9ComponentFv + .4byte getID__Q23gui9ComponentFv + .4byte isPointed__Q23gui9ComponentFi + .4byte isDragging__Q23gui9ComponentFi + .4byte setPointed__Q23gui9ComponentFib + .4byte onPoint__Q23gui9ComponentFi + .4byte offPoint__Q23gui9ComponentFi + .4byte onDrag__Q23gui9ComponentFff + .4byte onMove__Q23gui9ComponentFiff + .4byte onTrig__Q23gui9ComponentFiUlR3Vec + .4byte setDraggingButton__Q23gui9ComponentFUl + .4byte update__Q23gui9ComponentFiPC10KPADStatusffPv + .4byte update__Q23gui9ComponentFiffUlUlUlPv + .4byte isTriggerTarger__Q23gui9ComponentFv + .4byte setTriggerTarget__Q23gui9ComponentFb + .4byte setManager__Q23gui9ComponentFPQ23gui7Manager + .4byte isVisible__Q23gui9ComponentFv + .4byte getFlightDuration__Q23gui9ComponentFi + .4byte setFlightDuration__Q23gui9ComponentFiUs + .4byte 0x00000000 +.endobj lbl_81642824 + +# 0x81694678..0x81694688 | size: 0x10 +.section .sdata2, "a" +.balign 8 + +# .sdata2:0x0 | 0x81694678 | size: 0x4 +.obj lbl_81694678, global + .float 0 +.endobj lbl_81694678 + +# .sdata2:0x4 | 0x8169467C | size: 0x1 +.obj lbl_8169467C, global + .byte 0xFF +.endobj lbl_8169467C + +# .sdata2:0x5 | 0x8169467D | size: 0x1 +.obj lbl_8169467D, global + .byte 0x00 +.endobj lbl_8169467D + +# .sdata2:0x6 | 0x8169467E | size: 0x1 +.obj lbl_8169467E, global + .byte 0x00 +.endobj lbl_8169467E + +# .sdata2:0x7 | 0x8169467F | size: 0x1 +.obj lbl_8169467F, global + .byte 0xFF +.endobj lbl_8169467F + +# .sdata2:0x8 | 0x81694680 | size: 0x8 +.obj lbl_81694680, global + .float 0.5 + .float 0 +.endobj lbl_81694680 + +# 0x81698780..0x81698788 | size: 0x8 +.section .sbss, "wa", @nobits +.balign 8 + +# .sbss:0x0 | 0x81698780 | size: 0x8 +.obj lbl_81698780, global + .skip 0x8 +.endobj lbl_81698780 diff --git a/asm/43U/system/iplException.s b/asm/43U/system/iplException.s index 28d873bc..dde52e0e 100644 --- a/asm/43U/system/iplException.s +++ b/asm/43U/system/iplException.s @@ -30,7 +30,7 @@ /* 8133E348 0000C748 90 03 00 04 */ stw r0, 0x4(r3) /* 8133E34C 0000C74C 90 03 00 08 */ stw r0, 0x8(r3) /* 8133E350 0000C750 90 03 00 0C */ stw r0, 0xc(r3) -/* 8133E354 0000C754 48 1D F3 69 */ bl fn_8151D6BC +/* 8133E354 0000C754 48 1D F3 69 */ bl Exception_Init__Q24nw4r2dbFv /* 8133E358 0000C758 48 1D E1 01 */ bl fn_8151C458 /* 8133E35C 0000C75C 7F C4 F3 78 */ mr r4, r30 /* 8133E360 0000C760 38 60 08 FC */ li r3, 0x8fc diff --git a/asm/43U/utility/iplJpegDecoder.s b/asm/43U/utility/iplJpegDecoder.s index 0e0efd45..53c7977f 100644 --- a/asm/43U/utility/iplJpegDecoder.s +++ b/asm/43U/utility/iplJpegDecoder.s @@ -141,7 +141,7 @@ /* 81364FF0 000333F0 7F E4 FB 78 */ mr r4, r31 /* 81364FF4 000333F4 38 60 00 34 */ li r3, 0x34 /* 81364FF8 000333F8 38 A0 00 20 */ li r5, 0x20 -/* 81364FFC 000333FC 48 29 30 B5 */ bl fn_815F80B0 +/* 81364FFC 000333FC 48 29 30 B5 */ bl __nw__FUlPQ23EGG4Heapi /* 81365000 00033400 2C 03 00 00 */ cmpwi r3, 0x0 /* 81365004 00033404 41 82 00 20 */ beq .L_81365024 /* 81365008 00033408 A0 FE 00 1C */ lhz r7, 0x1c(r30) diff --git a/asm/BS1.s b/asm/BS1.s index 24d4030d..3f480252 100644 --- a/asm/BS1.s +++ b/asm/BS1.s @@ -5,25 +5,25 @@ *---------------------------------------------------------------------------*/ #include "BS1.inc" - .text - .globl __start - __start: -__BS1_entry: + /* Set up HID0 */ addis r4, r0, HID0_DEFAULT@ha addi r4, r4, HID0_DEFAULT@l mtspr hid0, r4 + /* Set up MSR */ addis r4, r0, MSR_ADDRESS@ha addi r4, r4, MSR_ADDRESS@l mtmsr r4 + /* Enable L1 cache */ mfspr r3, hid0 ori r4, r3, ENABLE_L1@l mtspr hid0, r4 + /* Clear BATs */ isync addi r4, r0, 0 mtspr dbat0u, r4 @@ -38,8 +38,9 @@ __BS1_entry: mtspr ibat3u, r4 mtspr ibat4u, r4 mtspr ibat5u, r4 + + /* Initialize SR registers for exceptions */ isync - addis r4, r0, SR_EXCEPTION@ha addi r4, r4, SR_EXCEPTION@l @@ -60,72 +61,100 @@ __BS1_entry: mtsr 14, r4 mtsr 15, r4 - addis r4, r0, BAT0L_ADDR@ha - addi r4, r4, BAT0L_ADDR@l - addis r3, r0, BAT0U_ADDR@ha - addi r3, r3, BAT0U_ADDR@l + /* Initialize BATs */ + + /* BAT 0 */ + addis r4, r0, BAT0_ADDR@ha + addi r4, r4, BAT0_ADDR@l + addis r3, r0, BAT0_VALUE@ha + addi r3, r3, BAT0_VALUE@l + mtspr dbat0l, r4 mtspr dbat0u, r3 + isync + mtspr ibat0l, r4 mtspr ibat0u, r3 + isync - addis r4, r0, BAT1L_ADDR@ha - addi r4, r4, BAT1L_ADDR@l - addis r3, r0, BAT1U_ADDR@ha - addi r3, r3, BAT1U_ADDR@l + /* BAT 1 */ + addis r4, r0, BAT1_ADDR@ha + addi r4, r4, BAT1_ADDR@l + addis r3, r0, BAT1_VALUE@ha + addi r3, r3, BAT1_VALUE@l + mtspr dbat1l, r4 mtspr dbat1u, r3 + isync - addis r4, r0, BAT4L_ADDR@ha - addi r4, r4, BAT4L_ADDR@l - addis r3, r0, BAT4U_ADDR@ha - addi r3, r3, BAT4U_ADDR@l + /* BAT 4 */ + addis r4, r0, BAT4_ADDR@ha + addi r4, r4, BAT4_ADDR@l + addis r3, r0, BAT4_VALUE@ha + addi r3, r3, BAT4_VALUE@l + mtspr dbat4l, r4 mtspr dbat4u, r3 + isync + mtspr ibat4l, r4 mtspr ibat4u, r3 + isync - addis r4, r0, BAT5L_ADDR@ha - addi r4, r4, BAT5L_ADDR@l - addis r3, r0, BAT5U_ADDR@ha - addi r3, r3, BAT5U_ADDR@l + /* BAT 5 */ + addis r4, r0, BAT5_ADDR@ha + addi r4, r4, BAT5_ADDR@l + addis r3, r0, BAT5_VALUE@ha + addi r3, r3, BAT5_VALUE@l + mtspr dbat5l, r4 mtspr dbat5u, r3 + isync - addis r4, r0, BAT3L_ADDR@ha - addi r4, r4, BAT3L_ADDR@l - addis r3, r0, BAT3U_ADDR@ha - addi r3, r3, BAT3U_ADDR@l + /* BAT 3 */ + addis r4, r0, BAT3_ADDR@ha + addi r4, r4, BAT3_ADDR@l + addis r3, r0, BAT3_VALUE@ha + addi r3, r3, BAT3_VALUE@l + mtspr dbat3l, r4 mtspr dbat3u, r3 + isync + mtspr ibat3l, r4 mtspr ibat3u, r3 - isync + /* Set up MMU */ + isync mfmsr r4 ori r4, r4, 0x0030 mtmsr r4 + isync - lis r3, 0x800000F4@ha - li r4, 0 - stw r4, 0x800000F4@l(r3) - lis r4, 0 + /* Load the Boot Info 2 (BI2) Data */ + lis r3, BI2_ADDRESS@ha + li r4, 0 + stw r4, BI2_ADDRESS@l(r3) + lis r4, 0 + /* The First Boot Stage (BS1) is done! Now jump the Second Boot Stage (BS2). */ ori r4, r4, BS2_ENTRY_OFFSET@l lwz r4, 0(r4) mtlr r4 blr .align BS1_ALIGN -.space BS2_ENTRY_PAD /* At the end of BS1 */ -.long BS2_ENTRY \ No newline at end of file +.space BS2_ENTRY_PAD +.long BS2_ENTRY + + diff --git a/include/BS1.inc b/include/BS1.inc index b4e767d4..2e355742 100644 --- a/include/BS1.inc +++ b/include/BS1.inc @@ -14,23 +14,27 @@ ENABLE_L2 .set 0x99000000 SR_EXCEPTION .set 0x80000000 -BAT0L_ADDR .set 0x00000002 -BAT0U_ADDR .set 0x80001FFF +BAT0_ADDR .set 0x00000002 +BAT0_VALUE .set 0x80001FFF -BAT1L_ADDR .set 0x0000002A -BAT1U_ADDR .set 0xC0001FFF +BAT1_ADDR .set 0x0000002A +BAT1_VALUE .set 0xC0001FFF -BAT3L_ADDR .set 0x00000001 -BAT3U_ADDR .set 0x0000001F +BAT3_ADDR .set 0x00000001 +BAT3_VALUE .set 0x0000001F -BAT4L_ADDR .set 0x10000002 -BAT4U_ADDR .set 0x90001FFF +BAT4_ADDR .set 0x10000002 +BAT4_VALUE .set 0x90001FFF -BAT5L_ADDR .set 0x1000002A -BAT5U_ADDR .set 0xD0001FFF +BAT5_ADDR .set 0x1000002A +BAT5_VALUE .set 0xD0001FFF BS1_ALIGN .set 0x00000100 BS2_ENTRY .set 0x81330000 BS2_ENTRY_OFFSET .set 0x000037FC -BS2_ENTRY_PAD .set (BS2_ENTRY_OFFSET - 0x00003600) \ No newline at end of file +BS2_ENTRY_PAD .set (BS2_ENTRY_OFFSET - 0x00003600) + +BI2_ADDRESS .set 0x800000F4 + + diff --git a/include/iplConfig.h b/include/config.h similarity index 100% rename from include/iplConfig.h rename to include/config.h diff --git a/include/decomp/decomp.h b/include/decomp/decomp.h index ee23fbeb..f9356f51 100644 --- a/include/decomp/decomp.h +++ b/include/decomp/decomp.h @@ -1,8 +1,9 @@ #ifndef DECOMP_H #define DECOMP_H -#include +#include #include +#include #endif // DECOMP_H diff --git a/include/decomp/decomp_ide.h b/include/decomp/decomp_ide.h new file mode 100644 index 00000000..4ff6831d --- /dev/null +++ b/include/decomp/decomp_ide.h @@ -0,0 +1,12 @@ +#ifndef DECOMP_SHUT_UP_IDE_H +#define DECOMP_SHUT_UP_IDE_H + +#ifndef __MWERKS__ +#define asm +#define __attribute__(x) +#define __declspec(x) +#endif + +#endif // DECOMP_SHUT_UP_IDE_H + + diff --git a/include/decomp/decomp_vscode.h b/include/decomp/decomp_vscode.h deleted file mode 100644 index 11008070..00000000 --- a/include/decomp/decomp_vscode.h +++ /dev/null @@ -1,12 +0,0 @@ -#ifndef DECOMP_SHUT_UP_VSCODE_H -#define DECOMP_SHUT_UP_VSCODE_H - -#ifdef __INTELLISENSE__ -#define asm -#define __attribute__(x) -#define __declspec(x) -#endif - -#endif // DECOMP_SHUT_UP_VSCODE_H - - diff --git a/include/ipl.h b/include/ipl.h deleted file mode 100644 index ed9ee8b4..00000000 --- a/include/ipl.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef IPL_H -#define IPL_H - -#include "iplConfig.h" - -#include - -#include "system.h" -#include "utility.h" - -#endif // IPL_H - - diff --git a/include/layout/iplLayout.h b/include/layout/iplLayout.h index eb037590..2853ecad 100644 --- a/include/layout/iplLayout.h +++ b/include/layout/iplLayout.h @@ -2,26 +2,31 @@ #define IPL_LAYOUT_H #include + #include + +#include + #include -#include + #include "system/iplNand.h" namespace ipl { namespace layout { class Object { public: - Object(EGG::Heap* pHeap, ipl::nand::LayoutFile* layoutArchive, const char* layoutDirectory, const char* layoutFileName); - void finishBinding(); - void calc(); - void draw(); + Object(EGG::Heap* pHeap, nand::LayoutFile* pLayoutArchive, const char* layoutDirectory, const char* layoutFileName); + + void finishBinding(); + void calc(); + void draw(); - inline nw4r::lyt::Pane* GetRootPane() { return mpRootPane; } + nw4r::lyt::Pane* GetRootPane() { return mpRootPane; } private: - undefined pad0[0x14]; // 0x00 - nw4r::lyt::Pane* mpRootPane; // 0x14 - undefined pad1[1384]; // 0x40 + undefined unk_0x00[0x14]; // 0x00 + nw4r::lyt::Pane* mpRootPane; // 0x14 + undefined unk_0x40[1384]; // 0x40 }; } } diff --git a/include/system.h b/include/system.h deleted file mode 100644 index 4e60db69..00000000 --- a/include/system.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef IPL_SYSTEM_LIB_H -#define IPL_SYSTEM_LIB_H - -#include "system/rvl_dec.h" -#include "system/RIPL_BoardRecord.h" -#include "system/iplSystem.h" -#include "system/iplNandSDWorker.h" -#include "system/iplNigaoe.h" -#include "system/odh.h" - -#endif // IPL_SYSTEM_LIB_H - - diff --git a/include/system/RIPL_BoardRecord.h b/include/system/RIPL_BoardRecord.h index 9f93695d..7d241b2e 100644 --- a/include/system/RIPL_BoardRecord.h +++ b/include/system/RIPL_BoardRecord.h @@ -7,20 +7,20 @@ extern "C" { #endif -typedef struct RBRUnkStruct { +typedef struct { u32 unk[0x4A]; s32 type; u32 dataOffset; s32 dataSize; -} RBRAttachment; +} RBRSomeData; -extern const char* RBRFileType_Txt; -extern const char* RBRFileType_Odh; -extern const char* RBRFileType_Dat; -extern const char* RBRFileType_Log; +extern const char* RBRFileType_Txt; +extern const char* RBRFileType_Odh; +extern const char* RBRFileType_Dat; +extern const char* RBRFileType_Log; -extern u8* RBRGetPicture(u32* pRbrData, s32* dataSize); -extern void RBRGetPosRect(f32* left, f32* right, f32* top, f32* bottom); +extern u8* RBRGetPicture(u32* pRbrData, s32* dataSize); +extern void RBRGetPosRect(f32* left, f32* right, f32* top, f32* bottom); #ifdef __cplusplus } diff --git a/include/system/iplController.h b/include/system/iplController.h index 92924799..9dd034f9 100644 --- a/include/system/iplController.h +++ b/include/system/iplController.h @@ -1,10 +1,13 @@ #ifndef IPL_CONTROLLER_H #define IPL_CONTROLLER_H -#include +#include + #include #include + #include + #include "utility/iplMath.h" namespace ipl { @@ -13,33 +16,33 @@ namespace ipl { public: Interface(); - virtual int unk_0x08(); - virtual int unk_0x0C(); - virtual int unk_0x10(); - virtual int unk_0x14(); - virtual int unk_0x18(); - virtual int unk_0x1C(); - virtual int unk_0x20(); - virtual int unk_0x24(); - virtual int unk_0x28(); - virtual int unk_0x2C(); - virtual int unk_0x30(); - virtual int unk_0x34(); - virtual int unk_0x38(); - virtual int unk_0x3C(); - virtual int unk_0x40(); - virtual int unk_0x44(); - virtual int unk_0x48(); - virtual int unk_0x4C(); - virtual int unk_0x50(); - virtual int unk_0x54(); - virtual math::VEC2 getIRPos() const; - virtual math::VEC2 getHorizon() const; - virtual int unk_0x60(); - virtual int unk_0x64(); - virtual int unk_0x68(); - virtual int unk_0x6C(); - virtual bool Active() const; + virtual int unk_0x08(); + virtual int unk_0x0C(); + virtual int unk_0x10(); + virtual int unk_0x14(); + virtual int unk_0x18(); + virtual int unk_0x1C(); + virtual int unk_0x20(); + virtual int unk_0x24(); + virtual int unk_0x28(); + virtual int unk_0x2C(); + virtual int unk_0x30(); + virtual int unk_0x34(); + virtual int unk_0x38(); + virtual int unk_0x3C(); + virtual int unk_0x40(); + virtual int unk_0x44(); + virtual int unk_0x48(); + virtual int unk_0x4C(); + virtual int unk_0x50(); + virtual int unk_0x54(); + virtual math::VEC2 getIRPos() const; + virtual math::VEC2 getHorizon() const; + virtual int unk_0x60(); + virtual int unk_0x64(); + virtual int unk_0x68(); + virtual int unk_0x6C(); + virtual bool Active() const; }; } } diff --git a/include/system/iplNand.h b/include/system/iplNand.h index ecdfe18f..ee37d2b8 100644 --- a/include/system/iplNand.h +++ b/include/system/iplNand.h @@ -1,8 +1,10 @@ #ifndef IPL_NAND_H #define IPL_NAND_H -#include +#include + #include + #include namespace ipl { @@ -10,14 +12,13 @@ namespace ipl { class LayoutFile { public: LayoutFile(); - // STUB }; class Manager { public: Manager(); + LayoutFile* readLayout(EGG::Heap* pHead, const char* archiveName, bool unk); - // STUB }; } } diff --git a/include/system/iplNandSDWorker.h b/include/system/iplNandSDWorker.h index a31117fb..a4d96f84 100644 --- a/include/system/iplNandSDWorker.h +++ b/include/system/iplNandSDWorker.h @@ -1,6 +1,8 @@ #ifndef IPL_NAND_SD_WORKER_H #define IPL_NAND_SD_WORKER_H +#include + #define IMET_MAX_HEADER_SIZE 0x1C #define IMET_CURRENT_VERSION 3 @@ -11,7 +13,7 @@ namespace ipl { ~NandSDWorker(); private: - BOOL check_header_base(const u8 *bnrData, u32 *hashOut); + BOOL check_header_base(const u8 *pBnrData, u32 *hashOut); }; } diff --git a/include/system/iplNigaoe.h b/include/system/iplNigaoe.h index ef0d1ce3..6fd7162f 100644 --- a/include/system/iplNigaoe.h +++ b/include/system/iplNigaoe.h @@ -1,43 +1,44 @@ #ifndef IPL_NIGAOE_H #define IPL_NIGAOE_H -#include +#include + #include + #include + #include namespace ipl { namespace nigaoe { class Object { public: - Object(EGG::Heap* pHeap, int width, int height, int faceId, void (*someFunc)(ipl::nigaoe::Object*, void*), void* pArg3); - Object(EGG::Heap* pHeap, int width, int height, RFLiCharData* charData, void (*someFunc)(ipl::nigaoe::Object*, void*), void* pArg3); + Object(EGG::Heap* pHeap, int width, int height, int faceId, void (*someFunc)(Object*, void*), void* pArg3); + Object(EGG::Heap* pHeap, int width, int height, RFLiCharData* pCharData, void (*someFunc)(Object*, void*), void* pArg3); ~Object(); - inline void SomeFunc(void* unk) { - return (*mSomeFunc)(this, unk); - } + void SomeFunc(void* pArg1) { return (*mSomeFunc)(this, pArg1); } private: - void init(EGG::Heap* pHeap, int width, int height); - void make_icon(); + void init(EGG::Heap* pHeap, int width, int height); + void make_icon(); - u8* mpIconTex; // 0x00 - size_t mIconSize; // 0x04 + u8* mpIconTex; // 0x00 + size_t mIconSize; // 0x04 - RFLIconSetting mIconSettings; // 0x08 + RFLIconSetting mIconSettings; // 0x08 - GXTexObj mFaceTexObj; // 0x18 + GXTexObj mFaceTexObj; // 0x18 - RFLiCharData* mpCharData; // 0x38 - u32 mFaceId; // 0x3c + RFLiCharData* mpCharData; // 0x38 + u32 mFaceId; // 0x3c - void (*mSomeFunc)(ipl::nigaoe::Object*, void*); // 0x40 + void (*mSomeFunc)(Object*, void*); // 0x40 - void* unk_0x44; - u32 unused_0x48; - u32 unused_0x4c; - u8 unk_0x50; + void* unk_0x44; + undefined4 unused_0x48; + undefined4 unused_0x4c; + u8 unk_0x50; }; } } diff --git a/include/system/iplPointer.h b/include/system/iplPointer.h index 0ba30cf0..6edfdd55 100644 --- a/include/system/iplPointer.h +++ b/include/system/iplPointer.h @@ -2,14 +2,18 @@ #define IPL_POINTER_H #include + #include + #include -#include "system/iplSystem.h" -#include "system/iplPointerCore.h" + #include "system/iplNand.h" -#include "layout/iplLayout.h" +#include "system/iplPointerCore.h" + #include "utility/iplMath.h" +#include "layout/iplLayout.h" + #define MAX_LAYOUT_FILES 9 namespace ipl { @@ -22,31 +26,31 @@ namespace ipl { public: Pointer(EGG::Heap* pHeap); - void calc(); - void draw(); + void calc(); + void draw(); - void setState(int chan, int state); - void changeType(int chan, int type); + void setState(int chan, int state); + void changeType(int chan, int type); - layout::Object* get_layout(int chan, int type = POINTER_LYT_TYPE_POINT); + layout::Object* get_layout(int chan, int type); public: - nand::LayoutFile* mLayoutArchive; // 0x00 - layout::Object* mLayoutObject[MAX_LAYOUT_FILES]; // 0x04 + nand::LayoutFile* mLayoutArchive; // 0x00 + layout::Object* mLayoutObject[MAX_LAYOUT_FILES]; // 0x04 - int unk_0x28; - math::VEC2 mOriginPos; // 0x2C + int unk_0x28; + math::VEC2 mOriginPos; // 0x2C - f32 mArrowLength; // 0x34 - PointerDirection mPointDirection; + f32 mArrowLength; // 0x34 + PointerDirection mPointDirection; - bool mScrolling; // 0x3C - bool unk_0x3D; + bool mScrolling; // 0x3C + bool unk_0x3D; - u8 unk_0x3E; - u8 unk_0x3F; + u8 unk_0x3E; + u8 unk_0x3F; - PointerCore mCore; // 0x40 + PointerCore mCore; // 0x40 }; } diff --git a/include/system/iplPointerCore.h b/include/system/iplPointerCore.h index 22849964..259ac0c2 100644 --- a/include/system/iplPointerCore.h +++ b/include/system/iplPointerCore.h @@ -1,55 +1,65 @@ #ifndef IPL_POINTER_CORE_H #define IPL_POINTER_CORE_H -#include +#include + #include #include + #include + #include "system/iplController.h" + #include "layout/iplLayout.h" -#define POINTER_LYT_TYPE_POINT 0 -#define POINTER_LYT_TYPE_GRABBING 1 -#define POINTER_LYT_TYPE_UNK3 3 namespace ipl { + enum { + POINTER_LYT_TYPE_POINT = 0, + POINTER_LYT_TYPE_GRABBING, + POINTER_LYT_TYPE_UNK2, + POINTER_LYT_TYPE_UNK3 + }; + class Pointer; class PointerCoreObject { public: PointerCoreObject(); - void calc(Pointer* pPointer, const controller::Interface* pController); - void draw(); + void calc(Pointer* pPointer, const controller::Interface* pController); + void draw(); - void setState(int newState) { mState = newState; } - int getState() { return mState; } + void setState(int newState) { mState = newState; } + int getState() { return mState; } - void setLayoutType(int newLayoutType) { mLayoutType = newLayoutType; } - int getLayoutType() { return mLayoutType; } + void setLayoutType(int newLayoutType) { mLayoutType = newLayoutType; } + int getLayoutType() { return mLayoutType; } - void setChan(int newChan) { mChan = newChan; } - int getChan() { return mChan; } + void setChan(int newChan) { mChan = newChan; } + int getChan() { return mChan; } private: layout::Object* mLayoutObject; // 0x00 - int mState; // 0x04 - int mLayoutType; // 0x08 - int mChan; // 0x0C - f32 unk_0x10; + + int mState; // 0x04 + int mLayoutType; // 0x08 + int mChan; // 0x0C + + f32 unk_0x10; }; class PointerCore { public: PointerCore(); - void calc(Pointer* pPointer); - void draw(); + void calc(Pointer* pPointer); + void draw(); - void setState(int chan, int state); - void changeType(int chan, int type); + void setState(int chan, int state); + void changeType(int chan, int type); private: - PointerCoreObject mCursors[WPAD_MAX_CONTROLLERS]; + PointerCoreObject mCursors[WPAD_MAX_CONTROLLERS]; // 0x00 }; } diff --git a/include/system/iplSystem.h b/include/system/iplSystem.h index 1e8fac3b..5f5ba7e3 100644 --- a/include/system/iplSystem.h +++ b/include/system/iplSystem.h @@ -2,76 +2,45 @@ #define IPL_SYSTEM_H #include + +#include + #include "system/iplNand.h" + #include "system/iplController.h" -#include namespace ipl { - namespace System { - typedef struct { - u8 pad0[0x6C]; // 0x00 - ipl::nand::Manager* nandManager; // 0x6C - u8 pad1[0x0268]; // 0x70 - } ArgData; - - extern ArgData smArg; - - class Arg { - public: - Arg(); - - private: - u8 unkData[0x01E0]; // 0x0000 + class System { + public: + class Arg { + public: + Arg(); - OSAlarm unkAlarm; // 0x01E0 - }; + private: + u8 unk_0x00[0x1E0]; + OSAlarm mUnkAlarm; // 0x1E0 + }; - void init(int argc, char** argv); - void run(); + static void init(int argc, char** argv); + static void run(); + + static GXRenderModeObj* getRenderModeObj(); + static nand::Manager* getNandManager() { return smArg.mpNandManager; } + static controller::Interface* getController(int chan); + + static bool isResetAcceptable(); - // stubs for now - GXRenderModeObj* getRenderModeObj(); - controller::Interface* getController(int chan); - void getProjectionRect(nw4r::ut::Rect* prjRect); - void getProjectionRect4x3(nw4r::ut::Rect* prjRect); + private: + typedef struct { + u8 unk_0x00[0x6C]; + ipl::nand::Manager* mpNandManager; // 0x6C + u8 unk_0x70[0x249]; + bool mCanReset; // 0x2B9 + u8 unk_0x2BA[0x1C]; + } ArgData; - // Inlines - - inline nand::Manager* GetNANDManager() { return smArg.nandManager; } - } -} - -#endif // IPL_SYSTEM_H - - -#ifndef IPL_SYSTEM_H -#define IPL_SYSTEM_H - -#include - -typedef struct { - u8 pad0[0x02D8]; -} IplSystemArg; - -namespace ipl { - namespace System { - extern IplSystemArg smArg; - - class Arg { - public: - Arg(); - - private: - u8 unkData[0x01E0]; // 0x0000 - - OSAlarm unkAlarm; // 0x01E0 - }; - - void init(int argc, char** argv); - void run(); - - GXRenderModeObj* getRenderModeObj(); // STUB - } + static ArgData smArg; + }; } #endif // IPL_SYSTEM_H diff --git a/include/system/rvl_dec.h b/include/system/rvl_dec.h index 510d8117..261df17c 100644 --- a/include/system/rvl_dec.h +++ b/include/system/rvl_dec.h @@ -1,10 +1,10 @@ -#ifndef IPL_SYSTEM_RVL_DECODE_H -#define IPL_SYSTEM_RVL_DECODE_H +#ifndef IPL_DECOMPRESS_H +#define IPL_DECOMPRESS_H #include -//extern void Rvl_decode(int unk0, u8* data); +//extern void Rvl_decode(int unk0, u8* data); -#endif // IPL_SYSTEM_RVL_DECODE_H +#endif // IPL_DECOMPRESS_H diff --git a/include/utility.h b/include/utility.h deleted file mode 100644 index c8b1a70c..00000000 --- a/include/utility.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef IPL_UTILITY_LIB_H -#define IPL_UTILITY_LIB_H - -#include "utility/iplMessageBase.h" - -#endif // IPL_UTILITY_LIB_H - - diff --git a/include/utility/iplCapture.h b/include/utility/iplCapture.h index a599e160..61ded351 100644 --- a/include/utility/iplCapture.h +++ b/include/utility/iplCapture.h @@ -1,8 +1,10 @@ #ifndef IPL_CAPTURE_H #define IPL_CAPTURE_H -#include +#include + #include + #include namespace ipl { @@ -11,21 +13,22 @@ namespace ipl { public: Capture(EGG::Heap* pHeap, int x, int y, int width, int height, _GXTexFmt texFmt); ~Capture(); - void capture(BOOL copyFilter); + + void capture(BOOL copyFilter); private: - u16 mXPos; // 0x00 - u16 mYPos; // 0x02 + u16 mXPos; // 0x00 + u16 mYPos; // 0x02 - u16 mTextureWidth; // 0x04 - u16 mTextureHeight; // 0x08 + u16 mTextureWidth; // 0x04 + u16 mTextureHeight; // 0x08 - GXTexFmt mTextureFormat; // 0x08 + GXTexFmt mTextureFormat; // 0x08 - u32 mTextureSize; // 0x0C - u8* mTextureBuffer; // 0x10 + u32 mTextureSize; // 0x0C + u8* mTextureBuffer; // 0x10 - GXTexObj mTexObj; // 0x14 + GXTexObj mTexObj; // 0x14 }; } } diff --git a/include/utility/iplGraphics.h b/include/utility/iplGraphics.h index 68ad2511..0faac14e 100644 --- a/include/utility/iplGraphics.h +++ b/include/utility/iplGraphics.h @@ -2,13 +2,13 @@ #define IPL_GRAPHICS_H #include -#include namespace ipl { namespace utility { - namespace Graphics { - void setDefaultOrtho(u32 ortho); - } + class Graphics { + public: + static void setDefaultOrtho(u32 ortho); + }; } } diff --git a/include/utility/iplMath.h b/include/utility/iplMath.h index 0024471a..f5950d38 100644 --- a/include/utility/iplMath.h +++ b/include/utility/iplMath.h @@ -2,21 +2,22 @@ #define IPL_MATH_H #include -#include + +#include namespace ipl { namespace math { typedef struct VEC2 : nw4r::math::VEC2 { - VEC2() {} + VEC2() {} - VEC2(const f32* pF) { x = pF[0]; y = pF[1]; } - VEC2(f32 fx, f32 fy) { x = fx; y = fy; } + VEC2(const f32* pF) { x = pF[0]; y = pF[1]; } + VEC2(f32 fx, f32 fy) { x = fx; y = fy; } }; typedef struct VEC3 : nw4r::math::VEC3 { - VEC3() {} + VEC3() {} - VEC3(const f32* pF) { x = pF[0]; y = pF[1]; z = pF[2]; } - VEC3(f32 fx, f32 fy, f32 fz) { x = fx; y = fy; z = fz; } + VEC3(const f32* pF) { x = pF[0]; y = pF[1]; z = pF[2]; } + VEC3(f32 fx, f32 fy, f32 fz) { x = fx; y = fy; z = fz; } }; } } diff --git a/include/utility/iplMessageBase.h b/include/utility/iplMessageBase.h index 198f3500..0d8e11c1 100644 --- a/include/utility/iplMessageBase.h +++ b/include/utility/iplMessageBase.h @@ -1,22 +1,23 @@ #ifndef IPL_MESSAGE_BASE_H #define IPL_MESSAGE_BASE_H -#include +#include + #include namespace ipl { namespace utility { class ut_message_base { public: - BOOL SendMessage(OSMessage msg, s32 flags); - BOOL JamMessage(OSMessage msg, s32 flags); - BOOL ReceiveMessage(OSMessage* pMsg, s32 flags); + BOOL SendMessage(OSMessage msg, s32 flags); + BOOL JamMessage(OSMessage msg, s32 flags); + BOOL ReceiveMessage(OSMessage* pMsg, s32 flags); - void InitMessageQueue(OSMessage* pMsg, s32 msgCount); + void InitMessageQueue(OSMessage* pMsg, s32 msgCount); private: - undefined4 unk_0x00; - OSMessageQueue pMsgQueue; // 0x04 + undefined4 unk_0x00; + OSMessageQueue mpMsgQueue; // 0x04 }; } } diff --git a/include/utility/iplUtility.h b/include/utility/iplUtility.h index 733bf788..78d16814 100644 --- a/include/utility/iplUtility.h +++ b/include/utility/iplUtility.h @@ -1,16 +1,18 @@ #ifndef IPL_UTILITY_H #define IPL_UTILITY_H -#include +#include + #include #include + #include "utility/iplMath.h" -#define UTILITY_CLAMP(x, min, max) x < min ? min : (x > max ? max : x) +#define UTILITY_CLAMP(x, min, max) x < min ? min : (x > max ? max : x) namespace ipl { namespace utility { - math::VEC2 get_cursor_pos(const math::VEC2& basePos); + math::VEC2 get_cursor_pos(const math::VEC2& basePos); } } diff --git a/libs/EGG/include/egg/core/eggDisposer.h b/libs/EGG/include/egg/core/eggDisposer.h index 0e542ec1..618e379a 100644 --- a/libs/EGG/include/egg/core/eggDisposer.h +++ b/libs/EGG/include/egg/core/eggDisposer.h @@ -12,8 +12,8 @@ namespace EGG { virtual ~Disposer(); private: - Heap* mpHeap; - nw4r::ut::Link mLink; + Heap* mpHeap; // 0x00 + nw4r::ut::Link mLink; // 0x04 }; } diff --git a/libs/EGG/include/egg/core/eggHeap.h b/libs/EGG/include/egg/core/eggHeap.h index 4db1a855..293e45ba 100644 --- a/libs/EGG/include/egg/core/eggHeap.h +++ b/libs/EGG/include/egg/core/eggHeap.h @@ -10,16 +10,16 @@ namespace EGG { }; } -void *operator new(size_t size); -void *operator new(size_t size, int align); -void *operator new(size_t size, EGG::Heap *pHeap, int align); +void *operator new(size_t size); +void *operator new(size_t size, int align); +void *operator new(size_t size, EGG::Heap *pHeap, int align); -void *operator new[](size_t size); -void *operator new[](size_t size, int align); -void *operator new[](size_t size, EGG::Heap *pHeap, int align); +void *operator new[](size_t size); +void *operator new[](size_t size, int align); +void *operator new[](size_t size, EGG::Heap *pHeap, int align); -void operator delete(void *ptr); -void operator delete[](void *ptr); +void operator delete(void *ptr); +void operator delete[](void *ptr); #endif // EGG_CORE_HEAP_H diff --git a/libs/MSL/include/cstring b/libs/MSL/include/cstring index e56dbe27..bfc620a9 100644 --- a/libs/MSL/include/cstring +++ b/libs/MSL/include/cstring @@ -7,10 +7,10 @@ namespace std { // MSL/memory.h - using ::memcpy; - using ::memset; + using ::memcpy; + using ::memset; - using ::strlen; + using ::strlen; } // namespace std #endif diff --git a/libs/MSL/include/size_t.h b/libs/MSL/include/size_t.h index 820e7199..2d7d1076 100644 --- a/libs/MSL/include/size_t.h +++ b/libs/MSL/include/size_t.h @@ -1,7 +1,7 @@ #ifndef MSL_SIZE_T_H #define MSL_SIZE_T_H -typedef unsigned long size_t; +typedef unsigned long size_t; #endif // MSL_SIZE_T_H diff --git a/libs/MSL/include/stdarg.h b/libs/MSL/include/stdarg.h index 24b75f46..0aaff436 100644 --- a/libs/MSL/include/stdarg.h +++ b/libs/MSL/include/stdarg.h @@ -9,11 +9,11 @@ typedef enum { } _va_arg_type; typedef struct { - char gpr; - char fpr; - char reserved[2]; - char* input_arg_area; - char* reg_save_area; + char gpr; + char fpr; + char reserved[2]; + char* input_arg_area; + char* reg_save_area; } va_list[1]; char* __va_arg(va_list args, _va_arg_type type); diff --git a/libs/MSL/include/stddef.h b/libs/MSL/include/stddef.h index c6a6059d..92e46ca8 100644 --- a/libs/MSL/include/stddef.h +++ b/libs/MSL/include/stddef.h @@ -3,7 +3,7 @@ #include -#define offsetof(st, m) ((size_t)&(((st *)0)->m)) +#define offsetof(st, m) ((size_t)&(((st*)0)->m)) #endif // MSL_STDDEF_H diff --git a/libs/MSL/include/string.h b/libs/MSL/include/string.h index e9dbbab5..15cd5e11 100644 --- a/libs/MSL/include/string.h +++ b/libs/MSL/include/string.h @@ -8,7 +8,7 @@ extern "C" { #endif -size_t strlen(const char* str); +size_t strlen(const char* str); #ifdef __cplusplus } diff --git a/libs/NW4R/include/nw4r/lyt.h b/libs/NW4R/include/nw4r/lyt.h new file mode 100644 index 00000000..cccb2ac4 --- /dev/null +++ b/libs/NW4R/include/nw4r/lyt.h @@ -0,0 +1,12 @@ +#ifndef NW4R_LAYOUT_H +#define NW4R_LAYOUT_H + +#include + +#include +#include + +#endif // NW4R_LAYOUT_H + + + diff --git a/libs/NW4R/include/nw4r/lyt/pane.h b/libs/NW4R/include/nw4r/lyt/pane.h index 8068afe9..dbd39376 100644 --- a/libs/NW4R/include/nw4r/lyt/pane.h +++ b/libs/NW4R/include/nw4r/lyt/pane.h @@ -2,10 +2,12 @@ #define NW4R_LAYOUT_PANE_H #include + #include #include #include #include + #include namespace nw4r { @@ -25,45 +27,46 @@ namespace nw4r { class Pane : detail::PaneBase { public: Pane(); - virtual ~Pane(); // 0x08 + virtual ~Pane(); // 0x08 - virtual undefined4* GetRuntimeTypeInfo() const; // 0x0C + virtual undefined4* GetRuntimeTypeInfo() const; // 0x0C - virtual void CalculateMtx(const undefined4& drawInfo); // 0x10 + virtual void CalculateMtx(const undefined4& drawInfo); // 0x10 - virtual void Draw(const undefined4& drawInfo); // 0x14 - virtual void DrawSelf(const undefined4& drawInfo); // 0x18 + virtual void Draw(const undefined4& drawInfo); // 0x14 + virtual void DrawSelf(const undefined4& drawInfo); // 0x18 - virtual void Animate(u32 unk); // 0x1C - virtual void AnimateSelf(u32 unk); // 0x20 + virtual void Animate(u32 unk); // 0x1C + virtual void AnimateSelf(u32 unk); // 0x20 - virtual ut::Color GetVtxColor(u32 index) const; // 0x24 - virtual void SetVtxColor(u32 index, ut::Color newColor); // 0x28 - virtual u8 GetVtxColorElement(u32 index) const; // 0x2C - virtual void SetVtxColorElement(u32 index, u8 element); // 0x30 + virtual ut::Color GetVtxColor(u32 index) const; // 0x24 + virtual void SetVtxColor(u32 index, ut::Color newColor); // 0x28 + virtual u8 GetVtxColorElement(u32 index) const; // 0x2C + virtual void SetVtxColorElement(u32 index, u8 element); // 0x30 - virtual undefined GetColorElement(u32 index) const; // 0x34 - virtual void SetColorElement(u32 index, u8 color); // 0x38 - - virtual Pane* FindPaneByName(const char* findName, bool bRecursive = true); // 0x3C + virtual undefined GetColorElement(u32 index) const; // 0x34 + virtual void SetColorElement(u32 index, u8 color); // 0x38 + virtual Pane* FindPaneByName(const char* findName, bool bRecursive = true); // 0x3C + - const math::VEC3& GetTranslate() { return mTranslate; } - void SetTranslate(const math::VEC3& translate) { mTranslate = translate; } - void SetTranslate(const math::VEC2& translate) { SetTranslate(math::VEC3(translate.x, translate.y, 0)); } + const math::VEC3& GetTranslate() { return mTranslate; } + void SetTranslate(const math::VEC3& translate) { mTranslate = translate; } + void SetTranslate(const math::VEC2& translate) { SetTranslate(math::VEC3(translate.x, translate.y, 0)); } - const math::VEC3& GetRotate() const { return mRotate; } - void SetRotate(const math::VEC3& rotate) { mRotate = rotate; } + const math::VEC3& GetRotate() const { return mRotate; } + void SetRotate(const math::VEC3& rotate) { mRotate = rotate; } - const math::VEC2& GetScale() const { return mScale; } - void SetScale(const math::VEC2& scale) { mScale = scale; } + const math::VEC2& GetScale() const { return mScale; } + void SetScale(const math::VEC2& scale) { mScale = scale; } - const Size& GetSize() const { return mSize; } - void SetSize(const Size& size) { mSize = size; } + const Size& GetSize() const { return mSize; } + void SetSize(const Size& size) { mSize = size; } - void SetVisible(bool visible) { detail::SetBit(&mFlags, 0, visible); }; - public: + void SetVisible(bool visible) { detail::SetBit(&mFlags, 0, visible); }; + + private: Pane* mpParent; // 0x0C ut::LinkList mChildList; // 0x10 ut::LinkList mAnimList; // 0x1C diff --git a/libs/NW4R/include/nw4r/math.h b/libs/NW4R/include/nw4r/math.h new file mode 100644 index 00000000..b2390164 --- /dev/null +++ b/libs/NW4R/include/nw4r/math.h @@ -0,0 +1,11 @@ +#ifndef NW4R_MATH_H +#define NW4R_MATH_H + +#include + +#include + +#endif // NW4R_MATH_H + + + diff --git a/libs/NW4R/include/nw4r/math/types.h b/libs/NW4R/include/nw4r/math/types.h index eabd305c..d803500e 100644 --- a/libs/NW4R/include/nw4r/math/types.h +++ b/libs/NW4R/include/nw4r/math/types.h @@ -2,10 +2,7 @@ #define NW4R_MATH_TYPES_H #include - -// in here for now -typedef f32 Mtx[3][4]; -typedef f32 Mtx44[4][4]; +#include namespace nw4r { namespace math { @@ -15,10 +12,10 @@ namespace nw4r { }; typedef struct VEC2 : public _VEC2 { - VEC2() {} + VEC2() {} - VEC2(const f32* pF) { x = pF[0]; y = pF[1]; } - VEC2(f32 fx, f32 fy) { x = fx; y = fy; } + VEC2(const f32* pF) { x = pF[0]; y = pF[1]; } + VEC2(f32 fx, f32 fy) { x = fx; y = fy; } }; typedef struct _VEC3 { @@ -28,10 +25,10 @@ namespace nw4r { }; typedef struct VEC3 : public _VEC3 { - VEC3() {} + VEC3() {} - VEC3(const f32* pF) { x = pF[0]; y = pF[1]; z = pF[2]; } - VEC3(f32 fx, f32 fy, f32 fz) { x = fx; y = fy; z = fz; } + VEC3(const f32* pF) { x = pF[0]; y = pF[1]; z = pF[2]; } + VEC3(f32 fx, f32 fy, f32 fz) { x = fx; y = fy; z = fz; } }; typedef struct _MTX33 { diff --git a/libs/NW4R/include/nw4r/ut.h b/libs/NW4R/include/nw4r/ut.h new file mode 100644 index 00000000..df364edf --- /dev/null +++ b/libs/NW4R/include/nw4r/ut.h @@ -0,0 +1,15 @@ +#ifndef NW4R_UTILITY_H +#define NW4R_UTILITY_H + +#include + +#include +#include + +#include +#include + +#endif // NW4R_UTILITY_H + + + diff --git a/libs/NW4R/include/nw4r/ut/LinkList.h b/libs/NW4R/include/nw4r/ut/LinkList.h index cdb46924..f5f60221 100644 --- a/libs/NW4R/include/nw4r/ut/LinkList.h +++ b/libs/NW4R/include/nw4r/ut/LinkList.h @@ -1,7 +1,10 @@ #ifndef NW4R_UTILITY_LINK_LIST_H #define NW4R_UTILITY_LINK_LIST_H +#include + #include + #include #include #include @@ -16,24 +19,24 @@ namespace nw4r { public: LinkListNode() : mNext(NULL), mPrev(NULL) {} - LinkListNode* GetNext() const { return mNext; } - LinkListNode* GetPrev() const { return mPrev; } + LinkListNode* GetNext() const { return mNext; } + LinkListNode* GetPrev() const { return mPrev; } private: - LinkListNode* mNext; // 0x00 - LinkListNode* mPrev; // 0x04 + LinkListNode* mNext; // 0x00 + LinkListNode* mPrev; // 0x04 }; class LinkListImpl : NonCopyable { public: - undefined4 unk; // 0x00 + undefined4 unk_0x00; // 0x00 }; template class LinkList : LinkListImpl { public: LinkList(); - undefined4 unk_0x00[2]; // 0x00 + undefined4 unk_0x00[2]; // 0x00 }; } } diff --git a/libs/RVLFaceLib/include/RVLFaceLib/RFL_Icon.h b/libs/RVLFaceLib/include/RVLFaceLib/RFL_Icon.h index fd4a7385..a1e40a10 100644 --- a/libs/RVLFaceLib/include/RVLFaceLib/RFL_Icon.h +++ b/libs/RVLFaceLib/include/RVLFaceLib/RFL_Icon.h @@ -26,7 +26,7 @@ typedef struct { #define RFL_ICON_TEX_FORMAT (GX_TF_RGB5A3) -RFLErrcode RFLMakeIcon(void* pBuffer, RFLDataSource source, RFLMiddleDB* middleDB, u16 index, RFLExpression expression, const RFLIconSetting* setting); +RFLErrcode RFLMakeIcon(void* pBuffer, RFLDataSource source, RFLMiddleDB* middleDB, u16 index, RFLExpression expression, const RFLIconSetting* setting); #ifdef __cplusplus } diff --git a/libs/RVLFaceLib/include/RVLFaceLib/RFL_Types.h b/libs/RVLFaceLib/include/RVLFaceLib/RFL_Types.h index 1adc184d..afa9573c 100644 --- a/libs/RVLFaceLib/include/RVLFaceLib/RFL_Types.h +++ b/libs/RVLFaceLib/include/RVLFaceLib/RFL_Types.h @@ -48,7 +48,7 @@ typedef enum { } RFLDataSource; typedef struct { - u8 data[24]; // 0x00 + u8 data[24]; // 0x00 } RFLMiddleDB; typedef enum { @@ -63,7 +63,7 @@ typedef enum { } RFLExpression; typedef struct { - u8 data[RFL_CREATEID_LENGTH]; // 0x00 + u8 data[RFL_CREATEID_LENGTH]; // 0x00 } RFLCreateID; #ifdef __cplusplus diff --git a/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Icon.h b/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Icon.h index 680f51a9..6d95162b 100644 --- a/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Icon.h +++ b/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Icon.h @@ -10,8 +10,8 @@ extern "C" { #endif -RFLErrcode RFLiMakeIcon(void* pBuffer, RFLiCharInfo* pCharInfo, RFLExpression expression, const RFLIconSetting* setting); -void RFLiMakeIconFromData(void* pBuffer, RFLiCharData* pCharData, RFLExpression expression, const RFLIconSetting* setting); +RFLErrcode RFLiMakeIcon(void* pBuffer, RFLiCharInfo* pCharInfo, RFLExpression expression, const RFLIconSetting* setting); +void RFLiMakeIconFromData(void* pBuffer, RFLiCharData* pCharData, RFLExpression expression, const RFLIconSetting* setting); #ifdef __cplusplus } diff --git a/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Types.h b/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Types.h index 4ef4930e..12ec7b8c 100644 --- a/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Types.h +++ b/libs/RVLFaceLib/include/RVLFaceLib/private/RFLi_Types.h @@ -137,10 +137,10 @@ typedef struct RFLiCharData { u16 favoriteColor : 4; u16 favorite : 1; - wchar_t name[RFL_NAME_LENGTH]; // 0x02 - u8 height; // 0x16 - u8 build; // 0x17 - RFLCreateID createID; // 0x18 + wchar_t name[RFL_NAME_LENGTH]; // 0x02 + u8 height; // 0x16 + u8 build; // 0x17 + RFLCreateID createID; // 0x18 // 0x20 u16 faceType : 3; diff --git a/libs/RVL_SDK/include/revolution/base/PPCArch.h b/libs/RVL_SDK/include/revolution/base/PPCArch.h index 359609e9..78c8cc5f 100644 --- a/libs/RVL_SDK/include/revolution/base/PPCArch.h +++ b/libs/RVL_SDK/include/revolution/base/PPCArch.h @@ -5,7 +5,7 @@ extern "C" { #endif -void PPCHalt(); +void PPCHalt(); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/gx/GXFrameBuffer.h b/libs/RVL_SDK/include/revolution/gx/GXFrameBuffer.h index 83863e71..b9eb2b60 100644 --- a/libs/RVL_SDK/include/revolution/gx/GXFrameBuffer.h +++ b/libs/RVL_SDK/include/revolution/gx/GXFrameBuffer.h @@ -8,10 +8,10 @@ extern "C" { #endif -void GXSetCopyFilter(GXBool aa, const u8 sample_pattern[12][2], GXBool vf, const u8 vfilter[7]); -void GXSetTexCopySrc(u16 x, u16 y, u16 width, u16 height); -void GXSetTexCopyDst(u16 width, u16 height, GXTexFmt fmt, GXBool mipmap); -void GXCopyTex(void *pDest, GXBool clear); +void GXSetCopyFilter(GXBool aa, const u8 sample_pattern[12][2], GXBool vf, const u8 vfilter[7]); +void GXSetTexCopySrc(u16 x, u16 y, u16 width, u16 height); +void GXSetTexCopyDst(u16 width, u16 height, GXTexFmt fmt, GXBool mipmap); +void GXCopyTex(void *pDest, GXBool clear); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/gx/GXManage.h b/libs/RVL_SDK/include/revolution/gx/GXManage.h index a2d2e7fd..9123b1fb 100644 --- a/libs/RVL_SDK/include/revolution/gx/GXManage.h +++ b/libs/RVL_SDK/include/revolution/gx/GXManage.h @@ -7,7 +7,7 @@ extern "C" { #endif -void GXPixModeSync(); +void GXPixModeSync(); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/gx/GXPixel.h b/libs/RVL_SDK/include/revolution/gx/GXPixel.h index c562b531..6fa6a6ae 100644 --- a/libs/RVL_SDK/include/revolution/gx/GXPixel.h +++ b/libs/RVL_SDK/include/revolution/gx/GXPixel.h @@ -8,7 +8,7 @@ extern "C" { #endif -void GXSetDither(GXBool enable); +void GXSetDither(GXBool enable); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/gx/GXStruct.h b/libs/RVL_SDK/include/revolution/gx/GXStruct.h index 4d18ba11..e32f2f36 100644 --- a/libs/RVL_SDK/include/revolution/gx/GXStruct.h +++ b/libs/RVL_SDK/include/revolution/gx/GXStruct.h @@ -10,7 +10,7 @@ extern "C" { #endif typedef struct { - u8 r, g, b, a; // 0x00 + u8 r, g, b, a; // 0x00 } GXColor; typedef struct { diff --git a/libs/RVL_SDK/include/revolution/gx/GXTexture.h b/libs/RVL_SDK/include/revolution/gx/GXTexture.h index 1d2cffff..5b720a40 100644 --- a/libs/RVL_SDK/include/revolution/gx/GXTexture.h +++ b/libs/RVL_SDK/include/revolution/gx/GXTexture.h @@ -8,8 +8,8 @@ extern "C" { #endif -void GXInitTexObj(GXTexObj* obj, void* pImage, u16 width, u16 height, GXTexFmt format, GXTexWrapMode wrapS, GXTexWrapMode wrapT, GXBool mipmap); -u32 GXGetTexBufferSize(u16 width, u16 height, u32 format, GXBool mipmap, u8 max_lod); +void GXInitTexObj(GXTexObj* obj, void* pImage, u16 width, u16 height, GXTexFmt format, GXTexWrapMode wrapS, GXTexWrapMode wrapT, GXBool mipmap); +u32 GXGetTexBufferSize(u16 width, u16 height, u32 format, GXBool mipmap, u8 max_lod); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/mtx.h b/libs/RVL_SDK/include/revolution/mtx.h new file mode 100644 index 00000000..a72c86d0 --- /dev/null +++ b/libs/RVL_SDK/include/revolution/mtx.h @@ -0,0 +1,16 @@ +#ifndef REVOLUTION_MTX_H +#define REVOLUTION_MTX_H + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +#ifdef __cplusplus +} +#endif + +#endif // REVOLUTION_MTX_H + + diff --git a/libs/RVL_SDK/include/revolution/mtx/GeoTypes.h b/libs/RVL_SDK/include/revolution/mtx/GeoTypes.h new file mode 100644 index 00000000..54b35d06 --- /dev/null +++ b/libs/RVL_SDK/include/revolution/mtx/GeoTypes.h @@ -0,0 +1,19 @@ +#ifndef REVOLUTION_MTX_GEO_TYPES_H +#define REVOLUTION_MTX_GEO_TYPES_H + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +typedef f32 Mtx[3][4]; +typedef f32 Mtx44[4][4]; + +#ifdef __cplusplus +} +#endif + +#endif // REVOLUTION_MTX_GEO_TYPES_H + + diff --git a/libs/RVL_SDK/include/revolution/os/OSAlarm.h b/libs/RVL_SDK/include/revolution/os/OSAlarm.h index a0fe4777..86738c94 100644 --- a/libs/RVL_SDK/include/revolution/os/OSAlarm.h +++ b/libs/RVL_SDK/include/revolution/os/OSAlarm.h @@ -25,7 +25,7 @@ struct OSAlarm { void* userData; // 0x1C }; -void OSCreateAlarm(OSAlarm* alarm); +void OSCreateAlarm(OSAlarm* pAlarm); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/os/OSCache.h b/libs/RVL_SDK/include/revolution/os/OSCache.h index d86ff4fb..db00b905 100644 --- a/libs/RVL_SDK/include/revolution/os/OSCache.h +++ b/libs/RVL_SDK/include/revolution/os/OSCache.h @@ -7,8 +7,8 @@ extern "C" { #endif -void DCStoreRange(void* pAddr, u32 size); -void DCInvalidateRange(void* pAddr, u32 size); +void DCStoreRange(void* pAddr, u32 size); +void DCInvalidateRange(void* pAddr, u32 size); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/include/revolution/os/OSMessage.h b/libs/RVL_SDK/include/revolution/os/OSMessage.h index 30741e15..b8891c8f 100644 --- a/libs/RVL_SDK/include/revolution/os/OSMessage.h +++ b/libs/RVL_SDK/include/revolution/os/OSMessage.h @@ -19,10 +19,10 @@ typedef struct { s32 usedCount; // 0x1C } OSMessageQueue; -void OSInitMessageQueue(OSMessageQueue* pMsgQueue, OSMessage* pMsg, s32 msgCount); -BOOL OSSendMessage(OSMessageQueue* pMsgQueue, OSMessage pMsg, s32 flags); -BOOL OSJamMessage(OSMessageQueue* pMsgQueue, OSMessage pMsg, s32 flags); -BOOL OSReceiveMessage(OSMessageQueue* pMsgQueue, OSMessage* pMsg, s32 flags); +void OSInitMessageQueue(OSMessageQueue* pMsgQueue, OSMessage* pMsg, s32 msgCount); +BOOL OSSendMessage(OSMessageQueue* pMsgQueue, OSMessage pMsg, s32 flags); +BOOL OSJamMessage(OSMessageQueue* pMsgQueue, OSMessage pMsg, s32 flags); +BOOL OSReceiveMessage(OSMessageQueue* pMsgQueue, OSMessage* pMsg, s32 flags); #ifdef __cplusplus } diff --git a/libs/RVL_SDK/src/os/OSAlarm.c b/libs/RVL_SDK/src/os/OSAlarm.c index f3b59091..4a0fa934 100644 --- a/libs/RVL_SDK/src/os/OSAlarm.c +++ b/libs/RVL_SDK/src/os/OSAlarm.c @@ -1,12 +1,12 @@ #include /* - @Address 0x8152C8E4 - @Size 0x10 -*/ -void OSCreateAlarm(OSAlarm* alarm) { - alarm->handler = NULL; - alarm->tag = 0; + * @note Address 0x8152C8E4 (4.3U) + * @note Size 0x10 + */ +void OSCreateAlarm(OSAlarm* pAlarm) { + pAlarm->handler = NULL; + pAlarm->tag = 0; } diff --git a/libs/RVL_SDK/src/os/__ppc_eabi_init.cpp b/libs/RVL_SDK/src/os/__ppc_eabi_init.cpp index 6812322e..1c07e6d1 100644 --- a/libs/RVL_SDK/src/os/__ppc_eabi_init.cpp +++ b/libs/RVL_SDK/src/os/__ppc_eabi_init.cpp @@ -1,4 +1,4 @@ -#include +#include #include #include <__ppc_eabi_init.h> @@ -21,15 +21,15 @@ extern void exit(); #endif typedef void (*VoidPTR)(); -__declspec(section ".init") extern VoidPTR _ctors[]; -__declspec(section ".init") extern VoidPTR _dtors[]; +__declspec(section ".init") extern VoidPTR _ctors[]; +__declspec(section ".init") extern VoidPTR _dtors[]; #pragma section code_type ".init" /* - @Address 0x813301D8 - @Size 0x24 -*/ + * @note Address 0x813301D8 (4.3U) + * @note Size 0x24 + */ asm void __init_hardware() { mfmsr r0 ori r0, r0, 0x2000 @@ -45,10 +45,10 @@ asm void __init_hardware() { } /* - @Address 0x813301FC - @Size 0x34 -*/ -asm void __flush_cache(void* address, unsigned int size) { + * @note Address 0x813301FC (4.3U) + * @note Size 0x34 + */ +asm void __flush_cache(void* pAddress, unsigned int size) { lis r5, 0xFFFF ori r5, r5, 0xFFF1 @@ -75,9 +75,9 @@ loop: #pragma section code_type ".text" /* - @Address 0x81538608 - @Size 0x20 -*/ + * @note Address 0x81538608 (4.3U) + * @note Size 0x20 + */ asm void __init_user() { fralloc @@ -89,9 +89,9 @@ asm void __init_user() { /* - @Address 0x81538628 - @Size 0x48 -*/ + * @note Address 0x81538628 (4.3U) + * @note Size 0x48 + */ static void __init_cpp() { VoidPTR *ctor; @@ -113,9 +113,9 @@ static void _ExitProcess() { } /* - @Address 0x81538670 - @Size 0x4C -*/ + * @note Address 0x81538670 (4.3U) + * @note Size 0x4C + */ void exit() { __fini_cpp(); _ExitProcess(); diff --git a/libs/RevoEX/include/revolution/net/NETDigest.h b/libs/RevoEX/include/revolution/net/NETDigest.h index 50c2bf50..bfc66f1f 100644 --- a/libs/RevoEX/include/revolution/net/NETDigest.h +++ b/libs/RevoEX/include/revolution/net/NETDigest.h @@ -7,7 +7,7 @@ extern "C" { #endif -u32 NETCalcCRC32(const void* data, s32 size); +u32 NETCalcCRC32(const void* pData, s32 size); #ifdef __cplusplus } diff --git a/libs/Runtime/include/NMWException.h b/libs/Runtime/include/NMWException.h index 1ac92668..29cdc3bd 100644 --- a/libs/Runtime/include/NMWException.h +++ b/libs/Runtime/include/NMWException.h @@ -1,31 +1,32 @@ -#ifndef RUNTIME_NMWEXCEPTION_H -#define RUNTIME_NMWEXCEPTION_H +#ifndef RUNTIME_NMW_EXCEPTION_H +#define RUNTIME_NMW_EXCEPTION_H #include <__ppc_eabi_linker.h> typedef void (*DtorFunction)(void* obj, short method); typedef struct DtorChain { - struct DtorChain* next; - void* dtor; - void* object; + struct DtorChain* next; + void* dtor; + void* object; } DtorChain; #ifdef __cplusplus extern "C" { #endif -extern DtorChain* __global_destructor_chain; -void __register_global_object(void* object, void* dtor, DtorChain* chain); -void __destroy_global_chain(); +extern DtorChain* __global_destructor_chain; -int __register_fragment(__eti_init_info* info, char* reg); -void __unregister_fragment(int id); +void __register_global_object(void* object, void* dtor, DtorChain* chain); +void __destroy_global_chain(); + +int __register_fragment(__eti_init_info* info, char* reg); +void __unregister_fragment(int id); #ifdef __cplusplus } #endif -#endif // RUNTIME_NMWEXCEPTION_H +#endif // RUNTIME_NMW_EXCEPTION_H diff --git a/libs/Runtime/include/__ppc_eabi_init.h b/libs/Runtime/include/__ppc_eabi_init.h index 2ca28440..283e6cce 100644 --- a/libs/Runtime/include/__ppc_eabi_init.h +++ b/libs/Runtime/include/__ppc_eabi_init.h @@ -9,7 +9,7 @@ __declspec(section ".init") extern void __init_registers(); __declspec(section ".init") extern void __init_data(); __declspec(section ".init") extern void __init_hardware(); -__declspec(section ".init") extern void __flush_cache(void* address, unsigned int size); +__declspec(section ".init") extern void __flush_cache(void* pAddress, unsigned int size); extern void __init_user(); diff --git a/libs/Runtime/include/__ppc_eabi_linker.h b/libs/Runtime/include/__ppc_eabi_linker.h index a541330f..87716476 100644 --- a/libs/Runtime/include/__ppc_eabi_linker.h +++ b/libs/Runtime/include/__ppc_eabi_linker.h @@ -6,39 +6,39 @@ extern "C" { #endif typedef struct __rom_copy_info { - char* rom; - char* address; - unsigned int size; + char* rom; + char* address; + unsigned int size; } __rom_copy_info; typedef struct __bss_init_info { - char* address; - unsigned int size; + char* address; + unsigned int size; } __bss_init_info; typedef struct __eti_init_info { - void* eti_start; - void* eti_end; - void* code_start; - unsigned long code_size; + void* eti_start; + void* eti_end; + void* code_start; + unsigned long code_size; } __eti_init_info; // This is all generated by the linker. // Da Stack -__declspec(section ".init") extern char _stack_addr[]; -__declspec(section ".init") extern char _stack_end[]; +__declspec(section ".init") extern char _stack_addr[]; +__declspec(section ".init") extern char _stack_end[]; // Small data area -__declspec(section ".init") extern char _SDA_BASE_[]; -__declspec(section ".init") extern char _SDA2_BASE_[]; +__declspec(section ".init") extern char _SDA_BASE_[]; +__declspec(section ".init") extern char _SDA2_BASE_[]; // Information for preparing the executable's sections -__declspec(section ".init") extern __rom_copy_info _rom_copy_info[]; -__declspec(section ".init") extern __bss_init_info _bss_init_info[]; +__declspec(section ".init") extern __rom_copy_info _rom_copy_info[]; +__declspec(section ".init") extern __bss_init_info _bss_init_info[]; // Extab init info -__declspec(section ".init") extern __eti_init_info _eti_init_info[]; +__declspec(section ".init") extern __eti_init_info _eti_init_info[]; #ifdef __cplusplus } diff --git a/libs/Runtime/src/__init_cpp_exceptions.cpp b/libs/Runtime/src/__init_cpp_exceptions.cpp index d4723639..b94fcaf7 100644 --- a/libs/Runtime/src/__init_cpp_exceptions.cpp +++ b/libs/Runtime/src/__init_cpp_exceptions.cpp @@ -1,4 +1,4 @@ -#include +#include #include <__ppc_eabi_linker.h> #include <__ppc_eabi_init.h> #include @@ -17,29 +17,32 @@ extern void __fini_cpp_exceptions(); #endif static inline void __exception_info_constants(__eti_init_info* info, char** R2) { - register char* temp; + register char* temp; + asm { mr temp, r2; } *R2 = temp; + info = _eti_init_info; } /* - @note Address: 0x815F9D08 - @note Size: 0x3C -*/ + * @note Address: 0x815F9D08 (4.3U) + * @note Size: 0x3C + */ extern void __init_cpp_exceptions() { if (fragmentID == -2) { - char* R2; - __eti_init_info* info; + char* R2; + __eti_init_info* info; + __exception_info_constants(_eti_init_info, &R2); fragmentID = __register_fragment(_eti_init_info, R2); } } /* - @note Address: 0x815F9D44 - @note Size: 0x34 -*/ + * @note Address: 0x815F9D44 (4.3U) + * @note Size: 0x34 + */ extern void __fini_cpp_exceptions() { if (fragmentID != -2) { __unregister_fragment(fragmentID); @@ -49,10 +52,10 @@ extern void __fini_cpp_exceptions() { #pragma force_active on #pragma section ".ctors$10" -__declspec(section ".ctors$10") extern void* const __init_cpp_exceptions_reference = __init_cpp_exceptions; +__declspec(section ".ctors$10") extern void* const __init_cpp_exceptions_reference = __init_cpp_exceptions; #pragma section ".dtors$10" -__declspec(section ".dtors$10") extern void* const __destroy_global_chain_reference = __destroy_global_chain; +__declspec(section ".dtors$10") extern void* const __destroy_global_chain_reference = __destroy_global_chain; #pragma section ".dtors$15" -__declspec(section ".dtors$15") extern void* const __fini_cpp_exceptions_reference = __fini_cpp_exceptions; +__declspec(section ".dtors$15") extern void* const __fini_cpp_exceptions_reference = __fini_cpp_exceptions; diff --git a/libs/Runtime/src/__mem.c b/libs/Runtime/src/__mem.c index ac416949..93ed0479 100644 --- a/libs/Runtime/src/__mem.c +++ b/libs/Runtime/src/__mem.c @@ -1,53 +1,53 @@ -#include +#include #include #pragma section code_type ".init" /* - @Address 0x81330230 - @Size 0x50 -*/ -void* memcpy(void* dest, const void* src, size_t count) { - char* p; - char* q; - int i; + * @note Address 0x81330230 (4.3U) + * @note Size 0x50 + */ +void* memcpy(void* pDest, const void* pSrc, size_t count) { + char* p; + char* q; + int i; - if (src >= dest) { - p = (char*)src - 1; - q = (char*)dest - 1; + if (pSrc >= pDest) { + p = (char*)pSrc - 1; + q = (char*)pDest - 1; for (i = count + 1; --i;) { *++q = *++p; } } else { - p = (char*)src + count; - q = (char*)dest + count; + p = (char*)pSrc + count; + q = (char*)pDest + count; for (i = count + 1; --i;) { *--q = *--p; } } - return dest; + return pDest; } /* - @Address 0x81330280 - @Size 0xB4 -*/ -void __fill_mem(void* dest, int value, unsigned long length) { -#define cDest ((unsigned char*)dest) -#define lDest ((unsigned long*)dest) + * @note Address 0x81330280 (4.3U) + * @note Size 0xB4 + */ +void __fill_mem(void* pDest, int value, unsigned long length) { +#define cDest ((unsigned char*)pDest) +#define lDest ((unsigned long*)pDest) unsigned long val = (unsigned char)value; unsigned long i; - lDest = (unsigned long*)dest; - cDest = (unsigned char*)dest; + lDest = (unsigned long*)pDest; + cDest = (unsigned char*)pDest; cDest--; if (length >= 32) { - i = ~(unsigned long)dest & 3; + i = ~(unsigned long)pDest & 3; if (i) { length -= i; @@ -100,23 +100,23 @@ void __fill_mem(void* dest, int value, unsigned long length) { } /* - @Address 0x81330334 - @Size 0x30 -*/ -void* memset(void* dest, int ch, size_t count) { - __fill_mem(dest, ch, count); - return dest; + * @note Address 0x81330334 (4.3U) + * @note Size 0x30 + */ +void* memset(void* pDest, int ch, size_t count) { + __fill_mem(pDest, ch, count); + return pDest; } #pragma section code_type ".text" /* - @Address 0x815F8EFC - @Size 0x1C -*/ + * @note Address 0x815F8EFC (4.3U) + * @note Size 0x1C + */ __declspec(weak) size_t strlen(const char* str) { - size_t size = -1; - unsigned char* p = (unsigned char*)str - 1; + size_t size = -1; + unsigned char* p = (unsigned char*)str - 1; do { size++; diff --git a/libs/Runtime/src/global_destructor_chain.c b/libs/Runtime/src/global_destructor_chain.c index 630a4dda..2f09c3de 100644 --- a/libs/Runtime/src/global_destructor_chain.c +++ b/libs/Runtime/src/global_destructor_chain.c @@ -1,28 +1,30 @@ -#include +#include #include DtorChain* __global_destructor_chain; /* - @note Address: 0x815F8FE0 - @Size 0x18 -*/ + * @note Address: 0x815F8FE0 (4.3U) + * @note Size 0x18 + */ void __register_global_object(void* object, void* dtor, DtorChain* chain) { chain->next = __global_destructor_chain; chain->dtor = dtor; chain->object = object; + __global_destructor_chain = chain; } /* - @note Address: 0x815F8FF8 - @Size 0x48 -*/ + * @note Address: 0x815F8FF8 (4.3U) + * @note Size 0x48 + */ void __destroy_global_chain() { - DtorChain* chain; + DtorChain* chain; + while ((chain = __global_destructor_chain) != 0) { __global_destructor_chain = chain->next; - (((void(*)(void*, short))chain->dtor)(chain->object,-1)); + (((void(*)(void*, short))chain->dtor)(chain->object, -1)); } } diff --git a/libs/Runtime/src/runtime.c b/libs/Runtime/src/runtime.c index 86439f87..927d6c49 100644 --- a/libs/Runtime/src/runtime.c +++ b/libs/Runtime/src/runtime.c @@ -1,4 +1,4 @@ -#include +#include #define save_restore_reg r11 @@ -130,9 +130,9 @@ L_815F93EC: } /* - @Address 0x815F948C - @Size 0x4C -*/ + * @note Address 0x815F948C + * @note Size 0x4C + */ static asm void __save_fpr() { nofralloc @@ -176,9 +176,9 @@ static asm void __save_fpr() { } /* - @Address 0x815F9440 - @Size 0x4C -*/ + * @note Address 0x815F9440 + * @note Size 0x4C + */ static asm void __restore_fpr() { nofralloc ENTRY_RESTORE_FPR(14) @@ -221,9 +221,9 @@ static asm void __restore_fpr() { } /* - @Address 0x815F948C - @Size 0x4C -*/ + * @note Address 0x815F948C + * @note Size 0x4C + */ static asm void __save_gpr() { nofralloc ENTRY_SAVE_GPR(14) @@ -266,9 +266,9 @@ static asm void __save_gpr() { } /* - @Address 0x815F94D8 - @Size 0x4C -*/ + * @note Address 0x815F94D8 + * @note Size 0x4C + */ static asm void __restore_gpr() { nofralloc ENTRY_RESTORE_GPR(14) @@ -311,9 +311,9 @@ static asm void __restore_gpr() { } /* - @note Address: 0x815F9524 - @note Size: 0xEC -*/ + * @note Address: 0x815F9524 (4.3U) + * @note Size: 0xEC + */ asm void __div2u() { /* 815F9524 002C7924 2C 03 00 00 */ cmpwi r3, 0x0 /* 815F9528 002C7928 7C 60 00 34 */ cntlzw r0, r3 @@ -386,9 +386,9 @@ L_815F9604: } /* - @note Address: 0x815F9610 - @note Size: 0x138 -*/ + * @note Address: 0x815F9610 (4.3U) + * @note Size: 0x138 + */ asm void __div2i() { /* 815F9610 002C7A10 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F9614 002C7A14 54 69 00 01 */ clrrwi. r9, r3, 31 @@ -484,9 +484,9 @@ L_815F9740: } /* - @note Address: 0x815F9748 - @note Size: 0xE4 -*/ + * @note Address: 0x815F9748 (4.3U) + * @note Size: 0xE4 + */ asm void __mod2u() { /* 815F9748 002C7B48 2C 03 00 00 */ cmpwi r3, 0x0 /* 815F974C 002C7B4C 7C 60 00 34 */ cntlzw r0, r3 @@ -557,9 +557,9 @@ L_815F9828: } /* - @note Address: 0x815F982C - @note Size: 0x10C -*/ + * @note Address: 0x815F982C (4.3U) + * @note Size: 0x10C + */ asm void __mod2i() { /* 815F982C 002C7C2C 2F 83 00 00 */ cmpwi cr7, r3, 0x0 /* 815F9830 002C7C30 40 9C 00 0C */ bge cr7, L_815F983C @@ -643,9 +643,9 @@ L_815F9934: } /* - @note Address: 0x815F9938 - @note Size: 0x24 -*/ + * @note Address: 0x815F9938 (4.3U) + * @note Size: 0x24 + */ asm void __shl2i() { /* 815F9938 002C7D38 21 05 00 20 */ subfic r8, r5, 0x20 /* 815F993C 002C7D3C 31 25 FF E0 */ subic r9, r5, 0x20 @@ -659,9 +659,9 @@ asm void __shl2i() { } /* - @note Address: 0x815F995C - @note Size: 0x24 -*/ + * @note Address: 0x815F995C (4.3U) + * @note Size: 0x24 + */ asm void __shr2u() { /* 815F995C 002C7D5C 21 05 00 20 */ subfic r8, r5, 0x20 /* 815F9960 002C7D60 31 25 FF E0 */ subic r9, r5, 0x20 @@ -675,9 +675,9 @@ asm void __shr2u() { } /* - @note Address: 0x815F9980 - @note Size: 0x28 -*/ + * @note Address: 0x815F9980 (4.3U) + * @note Size: 0x28 + */ asm void __shr2i() { /* 815F9980 002C7D80 21 05 00 20 */ subfic r8, r5, 0x20 /* 815F9984 002C7D84 35 25 FF E0 */ subic. r9, r5, 0x20 @@ -693,9 +693,9 @@ L_815F99A0: } /* - @note Address: 0x815F99A8 - @note Size: 0xB0 -*/ + * @note Address: 0x815F99A8 (4.3U) + * @note Size: 0xB0 + */ asm void __cvt_sll_dbl() { /* 815F99A8 002C7DA8 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F99AC 002C7DAC 54 65 00 01 */ clrrwi. r5, r3, 31 @@ -748,9 +748,9 @@ L_815F9A44: } /* - @note Address: 0x815F9A58 - @note Size: 0x9C -*/ + * @note Address: 0x815F9A58 (4.3U) + * @note Size: 0x9C + */ asm void __cvt_ull_dbl() { /* 815F9A58 002C7E58 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F9A5C 002C7E5C 7C 67 23 79 */ or. r7, r3, r4 @@ -797,9 +797,9 @@ L_815F9AE0: } /* - @note Address: 0x815F9AF4 - @note Size: 0xA0 -*/ + * @note Address: 0x815F9AF4 (4.3U) + * @note Size: 0xA0 + */ asm void __cvt_ull_flt() { /* 815F9AF4 002C7EF4 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F9AF8 002C7EF8 7C 67 23 79 */ or. r7, r3, r4 @@ -847,9 +847,9 @@ L_815F9B7C: } /* - @note Address: 0x815F9B94 - @note Size: 0xCC -*/ + * @note Address: 0x815F9B94 (4.3U) + * @note Size: 0xCC + */ asm void __cvt_dbl_usll() { /* 815F9B94 002C7F94 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F9B98 002C7F98 D8 21 00 08 */ stfd f1, 0x8(r1) @@ -911,9 +911,9 @@ L_815F9C58: } /* - @note Address: 0x815F9C60 - @note Size: 0xAB -*/ + * @note Address: 0x815F9C60 (4.3U) + * @note Size: 0xAB + */ asm void __cvt_dbl_ull() { /* 815F9C60 002C8060 94 21 FF F0 */ stwu r1, -0x10(r1) /* 815F9C64 002C8064 D8 21 00 08 */ stfd f1, 0x8(r1) diff --git a/src/BS2/BootStart.c b/src/BS2/BootStart.c index 25171f29..6ff86bd7 100644 --- a/src/BS2/BootStart.c +++ b/src/BS2/BootStart.c @@ -1,4 +1,4 @@ -#include +#include #include <__ppc_eabi_linker.h> #include <__ppc_eabi_init.h> #include @@ -12,7 +12,7 @@ extern "C" { #endif -extern int main(int argc, char** argv); +extern int main(int argc, char** argv); extern void DBInit(); extern void exit(); @@ -25,108 +25,109 @@ extern void exit(); extern void __start(); /* - @note Address: 0x81330000 - @note Size: 0xA8 -*/ + * @note Address: 0x81330000 (4.3J/4.3U/4.3E) + * @note Size: 0xA8 + */ __declspec(weak) asm void __start() { nofralloc bl __init_registers bl __init_hardware - li r0, 0xFFFF - stwu r1, -0x08(r1) - stw r0, 4(r1) - stw r0, 0(r1) + li r0, 0xFFFF + stwu r1, -8(r1) + stw r0, 4(r1) + stw r0, 0(r1) - bl __init_data + bl __init_data - li r0, 0 - lis r6, EXCEPTION_MASK_ADDR@ha - addi r6, r6, EXCEPTION_MASK_ADDR@l - stw r0, 0(r6) + li r0, 0 + lis r6, EXCEPTION_MASK_ADDR@ha + addi r6, r6, EXCEPTION_MASK_ADDR@l + stw r0, 0(r6) - lis r6, BI2_ADDR@ha - addi r6, r6, BI2_ADDR@l - lwz r5, 0(r6) - cmplwi r5, 0 - beq+ bi2_no_args + lis r6, BI2_ADDR@ha + addi r6, r6, BI2_ADDR@l + lwz r5, 0(r6) + cmplwi r5, 0 + beq+ bi2_no_args - addi r6, r5, BI2_ARGOFFSET - lwz r6, 0(r6) - cmplwi r6, 0 - beq+ bi2_no_args - add r6, r5, r6 + addi r6, r5, BI2_ARGOFFSET + lwz r6, 0(r6) + cmplwi r6, 0 + beq+ bi2_no_args + add r6, r5, r6 - lwz r3, 0(r6) - cmplwi r3, 0 - beq bi2_no_args + lwz r3, 0(r6) + cmplwi r3, 0 + beq bi2_no_args - addi r4, r6, 4 + addi r4, r6, 4 - mtctr r3 + mtctr r3 loop: - addi r6, r6, 4 - lwz r7, 0(r6) - add r7, r7, r5 - stw r7, 0(r6) - bdnz loop + addi r6, r6, 4 + lwz r7, 0(r6) + add r7, r7, r5 + stw r7, 0(r6) + bdnz loop - lis r5, ARENAHI_ADDR@ha - addi r5, r5, ARENAHI_ADDR@l - clrrwi r7, r4, 5 - stw r7, 0(r5) - b bi2_end_arg_parse + lis r5, ARENAHI_ADDR@ha + addi r5, r5, ARENAHI_ADDR@l + clrrwi r7, r4, 5 + stw r7, 0(r5) + b bi2_end_arg_parse bi2_no_args: - li r3, 0 - li r4, 0 + li r3, 0 + li r4, 0 bi2_end_arg_parse: - bl DBInit - bl __init_user + bl DBInit + bl __init_user - bl main + bl main - b exit + b exit } /* - @note Address: 0x813300A8 - @note Size: 0x90 -*/ + * @note Address: 0x813300A8 (4.3J/4.3U/4.3E) + * @note Size: 0x90 + */ static asm void __init_registers() { nofralloc - li r0, 0 - li r3, 0 - li r4, 0 - li r5, 0 - li r6, 0 - li r7, 0 - li r8, 0 - li r9, 0 - li r10, 0 - li r11, 0 - li r12, 0 - li r14, 0 - li r15, 0 - li r16, 0 - li r17, 0 - li r18, 0 - li r19, 0 - li r20, 0 - li r21, 0 - li r22, 0 - li r23, 0 - li r24, 0 - li r25, 0 - li r26, 0 - li r27, 0 - li r28, 0 - li r29, 0 - li r30, 0 - li r31, 0 + + li r0, 0 + li r3, 0 + li r4, 0 + li r5, 0 + li r6, 0 + li r7, 0 + li r8, 0 + li r9, 0 + li r10, 0 + li r11, 0 + li r12, 0 + li r14, 0 + li r15, 0 + li r16, 0 + li r17, 0 + li r18, 0 + li r19, 0 + li r20, 0 + li r21, 0 + li r22, 0 + li r23, 0 + li r24, 0 + li r25, 0 + li r26, 0 + li r27, 0 + li r28, 0 + li r29, 0 + li r30, 0 + li r31, 0 // da stack lis r1, _stack_addr@h @@ -155,9 +156,9 @@ static void init_bss_section(void* dest, unsigned int size) { } /* - @note Address: 0x81330138 - @note Size: 0xA0 -*/ + * @note Address: 0x81330138 (4.3J/4.3U/4.3E) + * @note Size: 0xA0 + */ static void __init_data() { __rom_copy_info* rci; __bss_init_info* bii; diff --git a/src/system/RIPL_BoardRecord.c b/src/system/RIPL_BoardRecord.c index 0b56e4e2..40ffc9da 100644 --- a/src/system/RIPL_BoardRecord.c +++ b/src/system/RIPL_BoardRecord.c @@ -1,4 +1,5 @@ #include "system/RIPL_BoardRecord.h" + #include #define RBR_SIGNATURE 'RI_5' @@ -11,9 +12,9 @@ const char* RBRFileType_Dat = "dat"; const char* RBRFileType_Log = "log"; /* - @Address 0x81332B48 - @Size 0x98 -*/ + * @note Address 0x81332B48 (4.3U/4.3E) + * @note Size 0x98 + */ u8* RBRGetPicture(u32* pRbrData, s32* dataSize) { u8* pRetData = NULL; @@ -22,7 +23,7 @@ u8* RBRGetPicture(u32* pRbrData, s32* dataSize) { u32 count = 2; while(count--) { - RBRAttachment* pData = (RBRAttachment*)&pRbrData[index]; + RBRSomeData* pData = (RBRSomeData*)&pRbrData[index]; if (pData->type == RBR_IMAGE_TYPE) { pRetData = (u8*)pRbrData + pData->dataOffset; @@ -39,9 +40,9 @@ u8* RBRGetPicture(u32* pRbrData, s32* dataSize) { } /* - @Address 0x81332BE0 - @Size 0x44 -*/ + * @note Address 0x81332BE0 (4.3U/4.3E) + * @note Size 0x44 + */ void RBRGetPosRect(f32* left, f32* right, f32* top, f32* bottom) { if (left != NULL) { *left = -230; diff --git a/src/system/iplNandSDWorker.cpp b/src/system/iplNandSDWorker.cpp index e409ebe1..58012c3f 100644 --- a/src/system/iplNandSDWorker.cpp +++ b/src/system/iplNandSDWorker.cpp @@ -1,10 +1,12 @@ -#include "ipl.h" +#include "system/iplNandSDWorker.h" + +#include namespace ipl { /* - @Address 0x81350EB4 - @Size 0xAC - */ + * @note Address 0x81350EB4 + * @note Size 0xAC + */ BOOL NandSDWorker::check_header_base(const u8 *bnrData, u32 *hashOut) { #define IMET_HDR_HASH *(u32 *)(bnrData + 4) #define IMET_HDR_VERSION *(u32 *)(bnrData + 8) diff --git a/src/system/iplNigaoe.cpp b/src/system/iplNigaoe.cpp index ab0a0e01..fd20fd9c 100644 --- a/src/system/iplNigaoe.cpp +++ b/src/system/iplNigaoe.cpp @@ -1,34 +1,37 @@ -#include "system/iplSystem.h" #include "system/iplNigaoe.h" -#include -#include + +#include + +#include + +#include "system/iplSystem.h" #define GX_RGB5A3_SIZE 2 namespace ipl { namespace nigaoe { /* - @Address: 0x8133EE00 - @Size: 0x48 - */ - Object::Object(EGG::Heap* pHeap, int width, int height, int faceId, void (*someFunc)(ipl::nigaoe::Object*, void*), void* pArg3) + * @note Address: 0x8133EE00 (4.3U) + * @note Size: 0x48 + */ + Object::Object(EGG::Heap* pHeap, int width, int height, int faceId, void (*someFunc)(Object*, void*), void* pArg3) : mFaceId(faceId), mpCharData(NULL), mSomeFunc(someFunc), unk_0x44(pArg3), unk_0x50(0) { init(pHeap, width, height); } /* - @Address: 0x8133EE48 - @Size: 0x4C - */ - Object::Object(EGG::Heap* pHeap, int width, int height, RFLiCharData* charData, void (*someFunc)(ipl::nigaoe::Object*, void*), void* pArg3) + * @note Address: 0x8133EE48 (4.3U) + * @note Size: 0x4C + */ + Object::Object(EGG::Heap* pHeap, int width, int height, RFLiCharData* charData, void (*someFunc)(Object*, void*), void* pArg3) : mFaceId(-1), mpCharData(charData), mSomeFunc(someFunc), unk_0x44(pArg3), unk_0x50(0) { init(pHeap, width, height); } /* - @Address: 0x8133EE94 - @Size: 0x7C - */ + * @note Address: 0x8133EE94 (4.3U) + * @note Size: 0x7C + */ void Object::init(EGG::Heap* pHeap, int width, int height) { mIconSettings.width = width; mIconSettings.height = height; @@ -47,17 +50,17 @@ namespace ipl { } /* - @Address: 0x8133EF10 - @Size: 0x58 - */ + * @note Address: 0x8133EF10 (4.3U) + * @note Size: 0x58 + */ Object::~Object() { delete[] mpIconTex; } /* - @Address: 0x8133EF68 - @Size: 0x100 - */ + * @note Address: 0x8133EF68 (4.3U) + * @note Size: 0x100 + */ void Object::make_icon() { GXRenderModeObj *rMode; RFLErrcode err = RFLErrcode_Success; diff --git a/src/system/iplPointer.cpp b/src/system/iplPointer.cpp index 78c8e560..06435c70 100644 --- a/src/system/iplPointer.cpp +++ b/src/system/iplPointer.cpp @@ -1,17 +1,22 @@ -#define OVERRIDE_PANE_SETTRANSLATE - #include "system/iplPointer.h" -#include -#include -#include -#include + +#include +#include +#include + +#include "system/iplSystem.h" + #include "utility/iplUtility.h" +#include "utility/iplMath.h" namespace ipl { #define MINIMUM_LENGTH 32 #define MAXIMUM_LENGTH 128 - - // 0x816354D4 + + /* + * @note Address: 0x816354D4 (4.3U) + * @note Size: 0x24 + */ static const char* scLayoutName[MAX_LAYOUT_FILES] = { #define LYT_INVALID_ID -1 @@ -22,25 +27,25 @@ namespace ipl { "P3_Def.brlyt", "P4_Def.brlyt", - #define LYT_GRAB_ID 4 // Grab + #define LYT_GRAB_ID 4 "P1_Cat.brlyt", "P2_Cat.brlyt", "P3_Cat.brlyt", "P4_Cat.brlyt", - #define LYT_SCROLLER_ID 8 // Scroller + #define LYT_SCROLLER_ID 8 "my_BScroll_a.brlyt" }; /* - @Address: 0x81344188 - @Size: 0xE8 - */ + * @note Address: 0x81344188 (4.3U) + * @note Size: 0xE8 + */ Pointer::Pointer(EGG::Heap* pHeap) : unk_0x28(-1), mOriginPos(0, 0), mArrowLength(MINIMUM_LENGTH), mPointDirection(PNT_DOWN), mScrolling(false), unk_0x3D(true), mCore() { - mLayoutArchive = System::GetNANDManager()->readLayout(pHeap, "cursor.ash", false); + mLayoutArchive = System::getNandManager()->readLayout(pHeap, "cursor.ash", false); for (int i = 0; i < MAX_LAYOUT_FILES; i++) { mLayoutObject[i] = new(pHeap, 4) layout::Object(pHeap, mLayoutArchive, "arc", scLayoutName[i]); @@ -49,9 +54,9 @@ namespace ipl { } /* - @Address: 0x81344270 - @Size: 0x174 - */ + * @note Address: 0x81344270 (4.3U) + * @note Size: 0x174 + */ void Pointer::calc() { mCore.calc(this); @@ -97,9 +102,9 @@ namespace ipl { } /* - @Address: 0x81344428 - @Size: 0x50 - */ + * @note Address: 0x81344428 (4.3U) + * @note Size: 0x50 + */ void Pointer::draw() { if (unk_0x3D) { mCore.draw(); @@ -110,25 +115,25 @@ namespace ipl { } /* - @Address: 0x81344478 - @Size: 0x8 - */ + * @note Address: 0x81344478 (4.3U) + * @note Size: 0x8 + */ void Pointer::setState(int chan, int state) { mCore.setState(chan, state); } /* - @Address: 0x81344480 - @Size: 0x8 - */ + * @note Address: 0x81344480 (4.3U) + * @note Size: 0x8 + */ void Pointer::changeType(int chan, int type) { mCore.changeType(chan, type); } /* - @Address: 0x81344488 - @Size: 0x3C - */ + * @note Address: 0x81344488 (4.3U) + * @note Size: 0x3C + */ layout::Object* Pointer::get_layout(int chan, int type) { int grabId = LYT_INVALID_ID; diff --git a/src/system/iplPointerCore.cpp b/src/system/iplPointerCore.cpp index 56079bf3..d27ae7a5 100644 --- a/src/system/iplPointerCore.cpp +++ b/src/system/iplPointerCore.cpp @@ -1,16 +1,27 @@ - #include "system/iplPointerCore.h" + +#include +#include + +#include "system/iplSystem.h" +#include "system/iplPointer.h" + +#include "utility/iplMath.h" #include "utility/iplUtility.h" #include "utility/iplGraphics.h" -#include -#include -#include -#include namespace ipl { + /* + * @note Address: 0x813444C4 (4.3U) + * @note Size: 0x24 + */ PointerCoreObject::PointerCoreObject() : mLayoutObject(NULL), mState(0), mLayoutType(POINTER_LYT_TYPE_UNK3), mChan(0), unk_0x10(0) {} + /* + * @note Address: 0x813444E8 (4.3U) + * @note Size: 0x19C + */ void PointerCoreObject::calc(Pointer* pPointer, const controller::Interface* pController) { mLayoutObject = NULL; if (pController && pController->Active()) { @@ -37,7 +48,11 @@ namespace ipl { mLayoutObject->calc(); } } - + + /* + * @note Address: 0x813446A0 (4.3U) + * @note Size: 0x24 + */ void PointerCoreObject::draw() { if (!mLayoutObject) return; if (mState != 0) return; @@ -45,8 +60,10 @@ namespace ipl { mLayoutObject->draw(); } - - + /* + * @note Address: 0x813446C4 (4.3U) + * @note Size: 0x7C + */ PointerCore::PointerCore() : mCursors() { int chan = 0; for (int i = WPAD_MAX_CONTROLLERS - 1; i >= 0; i--) { @@ -56,6 +73,10 @@ namespace ipl { } } + /* + * @note Address: 0x81344740 (4.3U) + * @note Size: 0x10 + */ void PointerCore::setState(int chan, int state) { mCursors[chan].setState(state); } @@ -66,6 +87,10 @@ namespace ipl { } } + /* + * @note Address: 0x813447B4 (4.3U) + * @note Size: 0x54 + */ void PointerCore::draw() { utility::Graphics::setDefaultOrtho(0); @@ -74,6 +99,10 @@ namespace ipl { } } + /* + * @note Address: 0x81344808 (4.3U) + * @note Size: 0x10 + */ void PointerCore::changeType(int chan, int type) { mCursors[chan].setLayoutType(type); } diff --git a/src/system/iplSystem.cpp b/src/system/iplSystem.cpp index 95aa4e57..92e8f282 100644 --- a/src/system/iplSystem.cpp +++ b/src/system/iplSystem.cpp @@ -1,26 +1,29 @@ -#include "ipl.h" +#include "system/iplSystem.h" + #include namespace ipl { - namespace System { - ArgData smArg; + /* + * @note Address 0x81089008 + * @note Size 0x2D8 + */ + System::ArgData System::smArg; - /* - @Address 0x81332C24 - @Size 0x48 - */ - Arg::Arg() { - memset(&smArg, 0, 0x02D8); - OSCreateAlarm(&unkAlarm); - } - - /* - @Address 0x81334B10 - @Size 0x18 - */ - bool isResetAcceptable() { - return smArg.pad1[0x249] == 0; - } + /* + * @note Address 0x81332C24 + * @note Size 0x48 + */ + System::Arg::Arg() { + memset(&smArg, 0, sizeof(ArgData)); + OSCreateAlarm(&mUnkAlarm); + } + + /* + * @note Address 0x81334B10 + * @note Size 0x18 + */ + bool System::isResetAcceptable() { + return !smArg.mCanReset; } } diff --git a/src/system/main.cpp b/src/system/main.cpp index 60760fc6..a00fa857 100644 --- a/src/system/main.cpp +++ b/src/system/main.cpp @@ -1,32 +1,33 @@ -#include "ipl.h" +#include + +#include "system/iplSystem.h" #ifdef __cplusplus extern "C" { #endif // __cplusplus extern void mainmenu(); -extern s32 NANDCheck(u32 fsBlock, u32 inode, u32 *answer); +extern s32 NANDCheck(u32 fsBlock, u32 inode, u32 *pAnswer); #ifdef __cplusplus } #endif // __cplusplus /* - @note Address: 0x81360764 - @note Size: 0x2C - @description The entry point -*/ + * @note Address: 0x81360764 (4.3U) + * @note Size: 0x2C + */ void mainmenu() { ipl::System::init(NULL, NULL); ipl::System::run(); } /* - @note Address: 0x81360764 - @note Size: 0x2C -*/ -s32 NANDCheck(u32 fsBlock, u32 inode, u32 *answer) { - *answer = 0; + * @note Address: 0x81360790 (4.3U) + * @note Size: 0x10 + */ +s32 NANDCheck(u32 fsBlock, u32 inode, u32 *pAnswer) { + *pAnswer = NULL; return 0; } diff --git a/src/system/odh.cpp b/src/system/odh.cpp index dfa8ee78..b6502f57 100644 --- a/src/system/odh.cpp +++ b/src/system/odh.cpp @@ -1,9 +1,9 @@ #include "system/odh.h" /* - @Address: 0x8135DDB0 - @Size: 0x24 -*/ + * @note Address: 0x8135DDB0 (4.3U) + * @note Size: 0x24 + */ s32 CArGBAOdh::ScaleLimit(s32 scale) { s32 newScale = scale; diff --git a/src/utility/iplCapture.cpp b/src/utility/iplCapture.cpp index 3879d71e..c6c9114d 100644 --- a/src/utility/iplCapture.cpp +++ b/src/utility/iplCapture.cpp @@ -1,12 +1,13 @@ -#include "system/iplSystem.h" #include "utility/iplCapture.h" +#include "system/iplSystem.h" + namespace ipl { namespace utility { /* - @Address: 0x813632A8 - @Size: 0x9C - */ + * @note Address: 0x813632A8 (4.3U) + * @note Size: 0x9C + */ Capture::Capture(EGG::Heap* pHeap, int x, int y, int width, int height, _GXTexFmt texFmt) : mXPos(x), mYPos(y), mTextureWidth(width), mTextureHeight(height), mTextureFormat(texFmt) { mTextureSize = GXGetTexBufferSize(width, height, texFmt, GX_FALSE, 1); @@ -16,17 +17,17 @@ namespace ipl { } /* - @Address: 0x81363344 - @Size: 0x58 - */ + * @note Address: 0x81363344 (4.3U) + * @note Size: 0x58 + */ Capture::~Capture() { delete[] mTextureBuffer; } /* - @Address: 0x8136339C - @Size: 0xC0 - */ + * @note Address: 0x8136339C (4.3U) + * @note Size: 0xC0 + */ void Capture::capture(BOOL copyFilter) { DCInvalidateRange(mTextureBuffer, mTextureSize); diff --git a/src/utility/iplMessageBase.cpp b/src/utility/iplMessageBase.cpp index 6a810bb8..00bc5c53 100644 --- a/src/utility/iplMessageBase.cpp +++ b/src/utility/iplMessageBase.cpp @@ -3,35 +3,35 @@ namespace ipl { namespace utility { /* - @Address: 0x81364D78 - @Size: 0x2C - */ + * @note Address: 0x81364D78 (4.3U) + * @note Size: 0x2C + */ BOOL ut_message_base::SendMessage(OSMessage msg, s32 flags) { - return OSSendMessage(&pMsgQueue, msg, flags) != FALSE; + return OSSendMessage(&mpMsgQueue, msg, flags) != FALSE; } /* - @Address: 0x81364DA4 - @Size: 0x2C - */ + * @note Address: 0x81364DA4 (4.3U) + * @note Size: 0x2C + */ BOOL ut_message_base::JamMessage(OSMessage msg, s32 flags) { - return OSJamMessage(&pMsgQueue, msg, flags) != FALSE; + return OSJamMessage(&mpMsgQueue, msg, flags) != FALSE; } /* - @Address: 0x81364DD0 - @Size: 0x2C - */ + * @note Address: 0x81364DD0 (4.3U) + * @note Size: 0x2C + */ BOOL ut_message_base::ReceiveMessage(OSMessage* pMsg, s32 flags) { - return OSReceiveMessage(&pMsgQueue, pMsg, flags) != FALSE; + return OSReceiveMessage(&mpMsgQueue, pMsg, flags) != FALSE; } /* - @Address: 0x81364DFC - @Size: 0x8 - */ + * @note Address: 0x81364DFC (4.3U) + * @note Size: 0x8 + */ void ut_message_base::InitMessageQueue(OSMessage* pMsg, s32 msgCount) { - OSInitMessageQueue(&pMsgQueue, pMsg, msgCount); + OSInitMessageQueue(&mpMsgQueue, pMsg, msgCount); } } }