diff --git a/asm/MetroidPrime/CArchMsgParmControllerStatus.s b/asm/MetroidPrime/CArchMsgParmControllerStatus.s index 60833fb2..a7495606 100644 --- a/asm/MetroidPrime/CArchMsgParmControllerStatus.s +++ b/asm/MetroidPrime/CArchMsgParmControllerStatus.s @@ -25,8 +25,8 @@ __dt__28CArchMsgParmControllerStatusFv: /* 8005A0AC 0005700C 38 03 A0 98 */ addi r0, r3, lbl_803DA098@l /* 8005A0B0 00057010 90 1F 00 00 */ stw r0, 0(r31) /* 8005A0B4 00057014 41 82 00 10 */ beq lbl_8005A0C4 -/* 8005A0B8 00057018 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 8005A0BC 0005701C 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l +/* 8005A0B8 00057018 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 8005A0BC 0005701C 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l /* 8005A0C0 00057020 90 1F 00 00 */ stw r0, 0(r31) lbl_8005A0C4: /* 8005A0C4 00057024 7C 80 07 35 */ extsh. r0, r4 @@ -43,13 +43,12 @@ lbl_8005A0D4: .global __ct__28CArchMsgParmControllerStatusFsb __ct__28CArchMsgParmControllerStatusFsb: -/* 8005A0EC 0005704C 3C E0 80 3E */ lis r7, lbl_803D8E9C@ha +/* 8005A0EC 0005704C 3C E0 80 3E */ lis r7, __vt__24IArchitectureMessageParm@ha /* 8005A0F0 00057050 3C C0 80 3E */ lis r6, lbl_803DA098@ha -/* 8005A0F4 00057054 38 E7 8E 9C */ addi r7, r7, lbl_803D8E9C@l +/* 8005A0F4 00057054 38 E7 8E 9C */ addi r7, r7, __vt__24IArchitectureMessageParm@l /* 8005A0F8 00057058 90 E3 00 00 */ stw r7, 0(r3) /* 8005A0FC 0005705C 38 06 A0 98 */ addi r0, r6, lbl_803DA098@l /* 8005A100 00057060 90 03 00 00 */ stw r0, 0(r3) /* 8005A104 00057064 B0 83 00 04 */ sth r4, 4(r3) /* 8005A108 00057068 98 A3 00 06 */ stb r5, 6(r3) /* 8005A10C 0005706C 4E 80 00 20 */ blr - diff --git a/asm/MetroidPrime/CArchMsgParmInt32.s b/asm/MetroidPrime/CArchMsgParmInt32.s index 94c7545c..bd1f7b4d 100644 --- a/asm/MetroidPrime/CArchMsgParmInt32.s +++ b/asm/MetroidPrime/CArchMsgParmInt32.s @@ -3,8 +3,8 @@ .section .data .balign 8 -.global lbl_803D9E50 -lbl_803D9E50: +.global __vt__17CArchMsgParmInt32 +__vt__17CArchMsgParmInt32: # ROM: 0x3D6E50 .4byte 0 .4byte 0 @@ -21,12 +21,12 @@ __dt__17CArchMsgParmInt32Fv: /* 800515D4 0004E534 93 E1 00 0C */ stw r31, 0xc(r1) /* 800515D8 0004E538 7C 7F 1B 79 */ or. r31, r3, r3 /* 800515DC 0004E53C 41 82 00 30 */ beq lbl_8005160C -/* 800515E0 0004E540 3C 60 80 3E */ lis r3, lbl_803D9E50@ha -/* 800515E4 0004E544 38 03 9E 50 */ addi r0, r3, lbl_803D9E50@l +/* 800515E0 0004E540 3C 60 80 3E */ lis r3, __vt__17CArchMsgParmInt32@ha +/* 800515E4 0004E544 38 03 9E 50 */ addi r0, r3, __vt__17CArchMsgParmInt32@l /* 800515E8 0004E548 90 1F 00 00 */ stw r0, 0(r31) /* 800515EC 0004E54C 41 82 00 10 */ beq lbl_800515FC -/* 800515F0 0004E550 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 800515F4 0004E554 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l +/* 800515F0 0004E550 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 800515F4 0004E554 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l /* 800515F8 0004E558 90 1F 00 00 */ stw r0, 0(r31) lbl_800515FC: /* 800515FC 0004E55C 7C 80 07 35 */ extsh. r0, r4 @@ -43,11 +43,11 @@ lbl_8005160C: .global __ct__17CArchMsgParmInt32Fi __ct__17CArchMsgParmInt32Fi: -/* 80051624 0004E584 3C C0 80 3E */ lis r6, lbl_803D8E9C@ha -/* 80051628 0004E588 3C A0 80 3E */ lis r5, lbl_803D9E50@ha -/* 8005162C 0004E58C 38 C6 8E 9C */ addi r6, r6, lbl_803D8E9C@l +/* 80051624 0004E584 3C C0 80 3E */ lis r6, __vt__24IArchitectureMessageParm@ha +/* 80051628 0004E588 3C A0 80 3E */ lis r5, __vt__17CArchMsgParmInt32@ha +/* 8005162C 0004E58C 38 C6 8E 9C */ addi r6, r6, __vt__24IArchitectureMessageParm@l /* 80051630 0004E590 90 C3 00 00 */ stw r6, 0(r3) -/* 80051634 0004E594 38 05 9E 50 */ addi r0, r5, lbl_803D9E50@l +/* 80051634 0004E594 38 05 9E 50 */ addi r0, r5, __vt__17CArchMsgParmInt32@l /* 80051638 0004E598 90 03 00 00 */ stw r0, 0(r3) /* 8005163C 0004E59C 90 83 00 04 */ stw r4, 4(r3) /* 80051640 0004E5A0 4E 80 00 20 */ blr diff --git a/asm/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.s b/asm/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.s index 622822a2..b560786b 100644 --- a/asm/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.s +++ b/asm/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.s @@ -3,8 +3,8 @@ .section .data .balign 8 -.global lbl_803D9E60 -lbl_803D9E60: +.global __vt__29CArchMsgParmInt32Int32VoidPtr +__vt__29CArchMsgParmInt32Int32VoidPtr: # ROM: 0x3D6E60 .4byte 0 .4byte 0 @@ -21,12 +21,12 @@ __dt__29CArchMsgParmInt32Int32VoidPtrFv: /* 80051650 0004E5B0 93 E1 00 0C */ stw r31, 0xc(r1) /* 80051654 0004E5B4 7C 7F 1B 79 */ or. r31, r3, r3 /* 80051658 0004E5B8 41 82 00 30 */ beq lbl_80051688 -/* 8005165C 0004E5BC 3C 60 80 3E */ lis r3, lbl_803D9E60@ha -/* 80051660 0004E5C0 38 03 9E 60 */ addi r0, r3, lbl_803D9E60@l +/* 8005165C 0004E5BC 3C 60 80 3E */ lis r3, __vt__29CArchMsgParmInt32Int32VoidPtr@ha +/* 80051660 0004E5C0 38 03 9E 60 */ addi r0, r3, __vt__29CArchMsgParmInt32Int32VoidPtr@l /* 80051664 0004E5C4 90 1F 00 00 */ stw r0, 0(r31) /* 80051668 0004E5C8 41 82 00 10 */ beq lbl_80051678 -/* 8005166C 0004E5CC 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 80051670 0004E5D0 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l +/* 8005166C 0004E5CC 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 80051670 0004E5D0 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l /* 80051674 0004E5D4 90 1F 00 00 */ stw r0, 0(r31) lbl_80051678: /* 80051678 0004E5D8 7C 80 07 35 */ extsh. r0, r4 @@ -43,11 +43,11 @@ lbl_80051688: .global __ct__29CArchMsgParmInt32Int32VoidPtrFiiPCv __ct__29CArchMsgParmInt32Int32VoidPtrFiiPCv: -/* 800516A0 0004E600 3D 00 80 3E */ lis r8, lbl_803D8E9C@ha -/* 800516A4 0004E604 3C E0 80 3E */ lis r7, lbl_803D9E60@ha -/* 800516A8 0004E608 39 08 8E 9C */ addi r8, r8, lbl_803D8E9C@l +/* 800516A0 0004E600 3D 00 80 3E */ lis r8, __vt__24IArchitectureMessageParm@ha +/* 800516A4 0004E604 3C E0 80 3E */ lis r7, __vt__29CArchMsgParmInt32Int32VoidPtr@ha +/* 800516A8 0004E608 39 08 8E 9C */ addi r8, r8, __vt__24IArchitectureMessageParm@l /* 800516AC 0004E60C 91 03 00 00 */ stw r8, 0(r3) -/* 800516B0 0004E610 38 07 9E 60 */ addi r0, r7, lbl_803D9E60@l +/* 800516B0 0004E610 38 07 9E 60 */ addi r0, r7, __vt__29CArchMsgParmInt32Int32VoidPtr@l /* 800516B4 0004E614 90 03 00 00 */ stw r0, 0(r3) /* 800516B8 0004E618 90 83 00 04 */ stw r4, 4(r3) /* 800516BC 0004E61C 90 A3 00 08 */ stw r5, 8(r3) diff --git a/asm/MetroidPrime/CArchMsgParmNull.s b/asm/MetroidPrime/CArchMsgParmNull.s index 3ef244e3..bf6bd284 100644 --- a/asm/MetroidPrime/CArchMsgParmNull.s +++ b/asm/MetroidPrime/CArchMsgParmNull.s @@ -3,8 +3,8 @@ .section .data .balign 8 -.global lbl_803D9E70 -lbl_803D9E70: +.global __vt__16CArchMsgParmNull +__vt__16CArchMsgParmNull: # ROM: 0x3D6E70 .4byte 0 .4byte 0 @@ -21,12 +21,12 @@ __dt__16CArchMsgParmNullFv: /* 800516D4 0004E634 93 E1 00 0C */ stw r31, 0xc(r1) /* 800516D8 0004E638 7C 7F 1B 79 */ or. r31, r3, r3 /* 800516DC 0004E63C 41 82 00 30 */ beq lbl_8005170C -/* 800516E0 0004E640 3C 60 80 3E */ lis r3, lbl_803D9E70@ha -/* 800516E4 0004E644 38 03 9E 70 */ addi r0, r3, lbl_803D9E70@l +/* 800516E0 0004E640 3C 60 80 3E */ lis r3, __vt__16CArchMsgParmNull@ha +/* 800516E4 0004E644 38 03 9E 70 */ addi r0, r3, __vt__16CArchMsgParmNull@l /* 800516E8 0004E648 90 1F 00 00 */ stw r0, 0(r31) /* 800516EC 0004E64C 41 82 00 10 */ beq lbl_800516FC -/* 800516F0 0004E650 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 800516F4 0004E654 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l +/* 800516F0 0004E650 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 800516F4 0004E654 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l /* 800516F8 0004E658 90 1F 00 00 */ stw r0, 0(r31) lbl_800516FC: /* 800516FC 0004E65C 7C 80 07 35 */ extsh. r0, r4 @@ -43,10 +43,10 @@ lbl_8005170C: .global __ct__16CArchMsgParmNullFv __ct__16CArchMsgParmNullFv: -/* 80051724 0004E684 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 80051728 0004E688 3C 80 80 3E */ lis r4, lbl_803D9E70@ha -/* 8005172C 0004E68C 38 A5 8E 9C */ addi r5, r5, lbl_803D8E9C@l +/* 80051724 0004E684 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 80051728 0004E688 3C 80 80 3E */ lis r4, __vt__16CArchMsgParmNull@ha +/* 8005172C 0004E68C 38 A5 8E 9C */ addi r5, r5, __vt__24IArchitectureMessageParm@l /* 80051730 0004E690 90 A3 00 00 */ stw r5, 0(r3) -/* 80051734 0004E694 38 04 9E 70 */ addi r0, r4, lbl_803D9E70@l +/* 80051734 0004E694 38 04 9E 70 */ addi r0, r4, __vt__16CArchMsgParmNull@l /* 80051738 0004E698 90 03 00 00 */ stw r0, 0(r3) /* 8005173C 0004E69C 4E 80 00 20 */ blr diff --git a/asm/MetroidPrime/CArchMsgParmReal32.s b/asm/MetroidPrime/CArchMsgParmReal32.s index 613c32d2..6c124f03 100644 --- a/asm/MetroidPrime/CArchMsgParmReal32.s +++ b/asm/MetroidPrime/CArchMsgParmReal32.s @@ -3,8 +3,8 @@ .section .data .balign 8 -.global lbl_803D9E80 -lbl_803D9E80: +.global __vt__18CArchMsgParmReal32 +__vt__18CArchMsgParmReal32: # ROM: 0x3D6E80 .4byte 0 .4byte 0 @@ -21,12 +21,12 @@ __dt__18CArchMsgParmReal32Fv: /* 8005174C 0004E6AC 93 E1 00 0C */ stw r31, 0xc(r1) /* 80051750 0004E6B0 7C 7F 1B 79 */ or. r31, r3, r3 /* 80051754 0004E6B4 41 82 00 30 */ beq lbl_80051784 -/* 80051758 0004E6B8 3C 60 80 3E */ lis r3, lbl_803D9E80@ha -/* 8005175C 0004E6BC 38 03 9E 80 */ addi r0, r3, lbl_803D9E80@l +/* 80051758 0004E6B8 3C 60 80 3E */ lis r3, __vt__18CArchMsgParmReal32@ha +/* 8005175C 0004E6BC 38 03 9E 80 */ addi r0, r3, __vt__18CArchMsgParmReal32@l /* 80051760 0004E6C0 90 1F 00 00 */ stw r0, 0(r31) /* 80051764 0004E6C4 41 82 00 10 */ beq lbl_80051774 -/* 80051768 0004E6C8 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 8005176C 0004E6CC 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l +/* 80051768 0004E6C8 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 8005176C 0004E6CC 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l /* 80051770 0004E6D0 90 1F 00 00 */ stw r0, 0(r31) lbl_80051774: /* 80051774 0004E6D4 7C 80 07 35 */ extsh. r0, r4 @@ -43,11 +43,11 @@ lbl_80051784: .global __ct__18CArchMsgParmReal32Ff __ct__18CArchMsgParmReal32Ff: -/* 8005179C 0004E6FC 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 800517A0 0004E700 3C 80 80 3E */ lis r4, lbl_803D9E80@ha -/* 800517A4 0004E704 38 A5 8E 9C */ addi r5, r5, lbl_803D8E9C@l +/* 8005179C 0004E6FC 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 800517A0 0004E700 3C 80 80 3E */ lis r4, __vt__18CArchMsgParmReal32@ha +/* 800517A4 0004E704 38 A5 8E 9C */ addi r5, r5, __vt__24IArchitectureMessageParm@l /* 800517A8 0004E708 90 A3 00 00 */ stw r5, 0(r3) -/* 800517AC 0004E70C 38 04 9E 80 */ addi r0, r4, lbl_803D9E80@l +/* 800517AC 0004E70C 38 04 9E 80 */ addi r0, r4, __vt__18CArchMsgParmReal32@l /* 800517B0 0004E710 90 03 00 00 */ stw r0, 0(r3) /* 800517B4 0004E714 D0 23 00 04 */ stfs f1, 4(r3) /* 800517B8 0004E718 4E 80 00 20 */ blr diff --git a/asm/MetroidPrime/CArchMsgParmUserInput.s b/asm/MetroidPrime/CArchMsgParmUserInput.s new file mode 100644 index 00000000..f7a160cb --- /dev/null +++ b/asm/MetroidPrime/CArchMsgParmUserInput.s @@ -0,0 +1,91 @@ +.include "macros.inc" + +.section .data +.balign 8 + +.global __vt__21CArchMsgParmUserInput +__vt__21CArchMsgParmUserInput: + # ROM: 0x3D6810 + .4byte 0 + .4byte 0 + .4byte __dt__21CArchMsgParmUserInputFv + .4byte 0 + +.section .text, "ax" + +.global GetUserInput__21CArchMsgParmUserInputCFv +GetUserInput__21CArchMsgParmUserInputCFv: +/* 8001B9E4 00018944 38 63 00 04 */ addi r3, r3, 4 +/* 8001B9E8 00018948 4E 80 00 20 */ blr + +.global __dt__21CArchMsgParmUserInputFv +__dt__21CArchMsgParmUserInputFv: +/* 8001B9EC 0001894C 94 21 FF F0 */ stwu r1, -0x10(r1) +/* 8001B9F0 00018950 7C 08 02 A6 */ mflr r0 +/* 8001B9F4 00018954 90 01 00 14 */ stw r0, 0x14(r1) +/* 8001B9F8 00018958 93 E1 00 0C */ stw r31, 0xc(r1) +/* 8001B9FC 0001895C 7C 7F 1B 79 */ or. r31, r3, r3 +/* 8001BA00 00018960 41 82 00 30 */ beq lbl_8001BA30 +/* 8001BA04 00018964 3C 60 80 3E */ lis r3, __vt__21CArchMsgParmUserInput@ha +/* 8001BA08 00018968 38 03 98 10 */ addi r0, r3, __vt__21CArchMsgParmUserInput@l +/* 8001BA0C 0001896C 90 1F 00 00 */ stw r0, 0(r31) +/* 8001BA10 00018970 41 82 00 10 */ beq lbl_8001BA20 +/* 8001BA14 00018974 3C 60 80 3E */ lis r3, __vt__24IArchitectureMessageParm@ha +/* 8001BA18 00018978 38 03 8E 9C */ addi r0, r3, __vt__24IArchitectureMessageParm@l +/* 8001BA1C 0001897C 90 1F 00 00 */ stw r0, 0(r31) +lbl_8001BA20: +/* 8001BA20 00018980 7C 80 07 35 */ extsh. r0, r4 +/* 8001BA24 00018984 40 81 00 0C */ ble lbl_8001BA30 +/* 8001BA28 00018988 7F E3 FB 78 */ mr r3, r31 +/* 8001BA2C 0001898C 48 2F 9F 05 */ bl Free__7CMemoryFPCv +lbl_8001BA30: +/* 8001BA30 00018990 80 01 00 14 */ lwz r0, 0x14(r1) +/* 8001BA34 00018994 7F E3 FB 78 */ mr r3, r31 +/* 8001BA38 00018998 83 E1 00 0C */ lwz r31, 0xc(r1) +/* 8001BA3C 0001899C 7C 08 03 A6 */ mtlr r0 +/* 8001BA40 000189A0 38 21 00 10 */ addi r1, r1, 0x10 +/* 8001BA44 000189A4 4E 80 00 20 */ blr + +.global __ct__21CArchMsgParmUserInputFRC11CFinalInput +__ct__21CArchMsgParmUserInputFRC11CFinalInput: +/* 8001BA48 000189A8 3C C0 80 3E */ lis r6, __vt__24IArchitectureMessageParm@ha +/* 8001BA4C 000189AC 3C A0 80 3E */ lis r5, __vt__21CArchMsgParmUserInput@ha +/* 8001BA50 000189B0 38 C6 8E 9C */ addi r6, r6, __vt__24IArchitectureMessageParm@l +/* 8001BA54 000189B4 90 C3 00 00 */ stw r6, 0(r3) +/* 8001BA58 000189B8 38 05 98 10 */ addi r0, r5, __vt__21CArchMsgParmUserInput@l +/* 8001BA5C 000189BC 90 03 00 00 */ stw r0, 0(r3) +/* 8001BA60 000189C0 C0 04 00 00 */ lfs f0, 0(r4) +/* 8001BA64 000189C4 D0 03 00 04 */ stfs f0, 4(r3) +/* 8001BA68 000189C8 80 04 00 04 */ lwz r0, 4(r4) +/* 8001BA6C 000189CC 90 03 00 08 */ stw r0, 8(r3) +/* 8001BA70 000189D0 C0 04 00 08 */ lfs f0, 8(r4) +/* 8001BA74 000189D4 D0 03 00 0C */ stfs f0, 0xc(r3) +/* 8001BA78 000189D8 C0 04 00 0C */ lfs f0, 0xc(r4) +/* 8001BA7C 000189DC D0 03 00 10 */ stfs f0, 0x10(r3) +/* 8001BA80 000189E0 C0 04 00 10 */ lfs f0, 0x10(r4) +/* 8001BA84 000189E4 D0 03 00 14 */ stfs f0, 0x14(r3) +/* 8001BA88 000189E8 C0 04 00 14 */ lfs f0, 0x14(r4) +/* 8001BA8C 000189EC D0 03 00 18 */ stfs f0, 0x18(r3) +/* 8001BA90 000189F0 C0 04 00 18 */ lfs f0, 0x18(r4) +/* 8001BA94 000189F4 D0 03 00 1C */ stfs f0, 0x1c(r3) +/* 8001BA98 000189F8 C0 04 00 1C */ lfs f0, 0x1c(r4) +/* 8001BA9C 000189FC D0 03 00 20 */ stfs f0, 0x20(r3) +/* 8001BAA0 00018A00 88 04 00 20 */ lbz r0, 0x20(r4) +/* 8001BAA4 00018A04 98 03 00 24 */ stb r0, 0x24(r3) +/* 8001BAA8 00018A08 88 04 00 21 */ lbz r0, 0x21(r4) +/* 8001BAAC 00018A0C 98 03 00 25 */ stb r0, 0x25(r3) +/* 8001BAB0 00018A10 88 04 00 22 */ lbz r0, 0x22(r4) +/* 8001BAB4 00018A14 98 03 00 26 */ stb r0, 0x26(r3) +/* 8001BAB8 00018A18 88 04 00 23 */ lbz r0, 0x23(r4) +/* 8001BABC 00018A1C 98 03 00 27 */ stb r0, 0x27(r3) +/* 8001BAC0 00018A20 C0 04 00 24 */ lfs f0, 0x24(r4) +/* 8001BAC4 00018A24 D0 03 00 28 */ stfs f0, 0x28(r3) +/* 8001BAC8 00018A28 C0 04 00 28 */ lfs f0, 0x28(r4) +/* 8001BACC 00018A2C D0 03 00 2C */ stfs f0, 0x2c(r3) +/* 8001BAD0 00018A30 88 04 00 2C */ lbz r0, 0x2c(r4) +/* 8001BAD4 00018A34 98 03 00 30 */ stb r0, 0x30(r3) +/* 8001BAD8 00018A38 88 04 00 2D */ lbz r0, 0x2d(r4) +/* 8001BADC 00018A3C 98 03 00 31 */ stb r0, 0x31(r3) +/* 8001BAE0 00018A40 88 04 00 2E */ lbz r0, 0x2e(r4) +/* 8001BAE4 00018A44 98 03 00 32 */ stb r0, 0x32(r3) +/* 8001BAE8 00018A48 4E 80 00 20 */ blr diff --git a/asm/MetroidPrime/CCredits.s b/asm/MetroidPrime/CCredits.s index 8cd7778e..2a70ec02 100644 --- a/asm/MetroidPrime/CCredits.s +++ b/asm/MetroidPrime/CCredits.s @@ -304,11 +304,11 @@ lbl_800251E0: lbl_80025208: /* 80025208 00022168 7C 83 23 78 */ mr r3, r4 /* 8002520C 0002216C 48 02 C8 D9 */ bl GetParmUserInput__7MakeMsgFRC20CArchitectureMessage -/* 80025210 00022170 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 80025214 00022174 3C 80 80 3E */ lis r4, lbl_803D9810@ha -/* 80025218 00022178 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 80025210 00022170 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 80025214 00022174 3C 80 80 3E */ lis r4, __vt__21CArchMsgParmUserInput@ha +/* 80025218 00022178 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 8002521C 0002217C 90 01 00 38 */ stw r0, 0x38(r1) -/* 80025220 00022180 38 04 98 10 */ addi r0, r4, lbl_803D9810@l +/* 80025220 00022180 38 04 98 10 */ addi r0, r4, __vt__21CArchMsgParmUserInput@l /* 80025224 00022184 90 01 00 38 */ stw r0, 0x38(r1) /* 80025228 00022188 C0 03 00 04 */ lfs f0, 4(r3) /* 8002522C 0002218C D0 01 00 3C */ stfs f0, 0x3c(r1) @@ -1318,11 +1318,11 @@ lbl_80026050: lbl_80026070: /* 80026070 00022FD0 7C 83 23 78 */ mr r3, r4 /* 80026074 00022FD4 48 02 BA 71 */ bl GetParmUserInput__7MakeMsgFRC20CArchitectureMessage -/* 80026078 00022FD8 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 8002607C 00022FDC 3C 80 80 3E */ lis r4, lbl_803D9810@ha -/* 80026080 00022FE0 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 80026078 00022FD8 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 8002607C 00022FDC 3C 80 80 3E */ lis r4, __vt__21CArchMsgParmUserInput@ha +/* 80026080 00022FE0 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 80026084 00022FE4 90 01 00 38 */ stw r0, 0x38(r1) -/* 80026088 00022FE8 38 04 98 10 */ addi r0, r4, lbl_803D9810@l +/* 80026088 00022FE8 38 04 98 10 */ addi r0, r4, __vt__21CArchMsgParmUserInput@l /* 8002608C 00022FEC 90 01 00 38 */ stw r0, 0x38(r1) /* 80026090 00022FF0 C0 03 00 04 */ lfs f0, 4(r3) /* 80026094 00022FF4 D0 01 00 3C */ stfs f0, 0x3c(r1) @@ -2675,11 +2675,11 @@ lbl_80027404: lbl_8002740C: /* 8002740C 0002436C 7C 83 23 78 */ mr r3, r4 /* 80027410 00024370 48 02 A6 D5 */ bl GetParmUserInput__7MakeMsgFRC20CArchitectureMessage -/* 80027414 00024374 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 80027418 00024378 3C 80 80 3E */ lis r4, lbl_803D9810@ha -/* 8002741C 0002437C 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 80027414 00024374 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 80027418 00024378 3C 80 80 3E */ lis r4, __vt__21CArchMsgParmUserInput@ha +/* 8002741C 0002437C 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 80027420 00024380 90 01 01 5C */ stw r0, 0x15c(r1) -/* 80027424 00024384 38 04 98 10 */ addi r0, r4, lbl_803D9810@l +/* 80027424 00024384 38 04 98 10 */ addi r0, r4, __vt__21CArchMsgParmUserInput@l /* 80027428 00024388 90 01 01 5C */ stw r0, 0x15c(r1) /* 8002742C 0002438C C0 03 00 04 */ lfs f0, 4(r3) /* 80027430 00024390 D0 01 01 60 */ stfs f0, 0x160(r1) diff --git a/asm/MetroidPrime/CFrontEndUI.s b/asm/MetroidPrime/CFrontEndUI.s index 820da885..13214b6b 100644 --- a/asm/MetroidPrime/CFrontEndUI.s +++ b/asm/MetroidPrime/CFrontEndUI.s @@ -7,14 +7,6 @@ lbl_ctor: .section .data .balign 8 -.global lbl_803D9810 -lbl_803D9810: - # ROM: 0x3D6810 - .4byte 0 - .4byte 0 - .4byte __dt__21CArchMsgParmUserInputFv - .4byte 0 - .global lbl_803D9820 lbl_803D9820: # ROM: 0x3D6820 @@ -578,83 +570,6 @@ lbl_805AA01C: .section .text, "ax" -.global GetUserInput__21CArchMsgParmUserInputCFv -GetUserInput__21CArchMsgParmUserInputCFv: -/* 8001B9E4 00018944 38 63 00 04 */ addi r3, r3, 4 -/* 8001B9E8 00018948 4E 80 00 20 */ blr - -.global __dt__21CArchMsgParmUserInputFv -__dt__21CArchMsgParmUserInputFv: -/* 8001B9EC 0001894C 94 21 FF F0 */ stwu r1, -0x10(r1) -/* 8001B9F0 00018950 7C 08 02 A6 */ mflr r0 -/* 8001B9F4 00018954 90 01 00 14 */ stw r0, 0x14(r1) -/* 8001B9F8 00018958 93 E1 00 0C */ stw r31, 0xc(r1) -/* 8001B9FC 0001895C 7C 7F 1B 79 */ or. r31, r3, r3 -/* 8001BA00 00018960 41 82 00 30 */ beq lbl_8001BA30 -/* 8001BA04 00018964 3C 60 80 3E */ lis r3, lbl_803D9810@ha -/* 8001BA08 00018968 38 03 98 10 */ addi r0, r3, lbl_803D9810@l -/* 8001BA0C 0001896C 90 1F 00 00 */ stw r0, 0(r31) -/* 8001BA10 00018970 41 82 00 10 */ beq lbl_8001BA20 -/* 8001BA14 00018974 3C 60 80 3E */ lis r3, lbl_803D8E9C@ha -/* 8001BA18 00018978 38 03 8E 9C */ addi r0, r3, lbl_803D8E9C@l -/* 8001BA1C 0001897C 90 1F 00 00 */ stw r0, 0(r31) -lbl_8001BA20: -/* 8001BA20 00018980 7C 80 07 35 */ extsh. r0, r4 -/* 8001BA24 00018984 40 81 00 0C */ ble lbl_8001BA30 -/* 8001BA28 00018988 7F E3 FB 78 */ mr r3, r31 -/* 8001BA2C 0001898C 48 2F 9F 05 */ bl Free__7CMemoryFPCv -lbl_8001BA30: -/* 8001BA30 00018990 80 01 00 14 */ lwz r0, 0x14(r1) -/* 8001BA34 00018994 7F E3 FB 78 */ mr r3, r31 -/* 8001BA38 00018998 83 E1 00 0C */ lwz r31, 0xc(r1) -/* 8001BA3C 0001899C 7C 08 03 A6 */ mtlr r0 -/* 8001BA40 000189A0 38 21 00 10 */ addi r1, r1, 0x10 -/* 8001BA44 000189A4 4E 80 00 20 */ blr - -.global __ct__21CArchMsgParmUserInputFRC11CFinalInput -__ct__21CArchMsgParmUserInputFRC11CFinalInput: -/* 8001BA48 000189A8 3C C0 80 3E */ lis r6, lbl_803D8E9C@ha -/* 8001BA4C 000189AC 3C A0 80 3E */ lis r5, lbl_803D9810@ha -/* 8001BA50 000189B0 38 C6 8E 9C */ addi r6, r6, lbl_803D8E9C@l -/* 8001BA54 000189B4 90 C3 00 00 */ stw r6, 0(r3) -/* 8001BA58 000189B8 38 05 98 10 */ addi r0, r5, lbl_803D9810@l -/* 8001BA5C 000189BC 90 03 00 00 */ stw r0, 0(r3) -/* 8001BA60 000189C0 C0 04 00 00 */ lfs f0, 0(r4) -/* 8001BA64 000189C4 D0 03 00 04 */ stfs f0, 4(r3) -/* 8001BA68 000189C8 80 04 00 04 */ lwz r0, 4(r4) -/* 8001BA6C 000189CC 90 03 00 08 */ stw r0, 8(r3) -/* 8001BA70 000189D0 C0 04 00 08 */ lfs f0, 8(r4) -/* 8001BA74 000189D4 D0 03 00 0C */ stfs f0, 0xc(r3) -/* 8001BA78 000189D8 C0 04 00 0C */ lfs f0, 0xc(r4) -/* 8001BA7C 000189DC D0 03 00 10 */ stfs f0, 0x10(r3) -/* 8001BA80 000189E0 C0 04 00 10 */ lfs f0, 0x10(r4) -/* 8001BA84 000189E4 D0 03 00 14 */ stfs f0, 0x14(r3) -/* 8001BA88 000189E8 C0 04 00 14 */ lfs f0, 0x14(r4) -/* 8001BA8C 000189EC D0 03 00 18 */ stfs f0, 0x18(r3) -/* 8001BA90 000189F0 C0 04 00 18 */ lfs f0, 0x18(r4) -/* 8001BA94 000189F4 D0 03 00 1C */ stfs f0, 0x1c(r3) -/* 8001BA98 000189F8 C0 04 00 1C */ lfs f0, 0x1c(r4) -/* 8001BA9C 000189FC D0 03 00 20 */ stfs f0, 0x20(r3) -/* 8001BAA0 00018A00 88 04 00 20 */ lbz r0, 0x20(r4) -/* 8001BAA4 00018A04 98 03 00 24 */ stb r0, 0x24(r3) -/* 8001BAA8 00018A08 88 04 00 21 */ lbz r0, 0x21(r4) -/* 8001BAAC 00018A0C 98 03 00 25 */ stb r0, 0x25(r3) -/* 8001BAB0 00018A10 88 04 00 22 */ lbz r0, 0x22(r4) -/* 8001BAB4 00018A14 98 03 00 26 */ stb r0, 0x26(r3) -/* 8001BAB8 00018A18 88 04 00 23 */ lbz r0, 0x23(r4) -/* 8001BABC 00018A1C 98 03 00 27 */ stb r0, 0x27(r3) -/* 8001BAC0 00018A20 C0 04 00 24 */ lfs f0, 0x24(r4) -/* 8001BAC4 00018A24 D0 03 00 28 */ stfs f0, 0x28(r3) -/* 8001BAC8 00018A28 C0 04 00 28 */ lfs f0, 0x28(r4) -/* 8001BACC 00018A2C D0 03 00 2C */ stfs f0, 0x2c(r3) -/* 8001BAD0 00018A30 88 04 00 2C */ lbz r0, 0x2c(r4) -/* 8001BAD4 00018A34 98 03 00 30 */ stb r0, 0x30(r3) -/* 8001BAD8 00018A38 88 04 00 2D */ lbz r0, 0x2d(r4) -/* 8001BADC 00018A3C 98 03 00 31 */ stb r0, 0x31(r3) -/* 8001BAE0 00018A40 88 04 00 2E */ lbz r0, 0x2e(r4) -/* 8001BAE4 00018A44 98 03 00 32 */ stb r0, 0x32(r3) -/* 8001BAE8 00018A48 4E 80 00 20 */ blr - .global StartSlideShow__11CFrontEndUIFR18CArchitectureQueue StartSlideShow__11CFrontEndUIFR18CArchitectureQueue: /* 8001BAEC 00018A4C 94 21 FF E0 */ stwu r1, -0x20(r1) diff --git a/asm/MetroidPrime/CMFGame.s b/asm/MetroidPrime/CMFGame.s index ef08861f..cd156012 100644 --- a/asm/MetroidPrime/CMFGame.s +++ b/asm/MetroidPrime/CMFGame.s @@ -1301,11 +1301,11 @@ lbl_80024A74: /* 80024A7C 000219DC 41 82 02 CC */ beq lbl_80024D48 /* 80024A80 000219E0 7C 83 23 78 */ mr r3, r4 /* 80024A84 000219E4 48 02 D0 61 */ bl GetParmUserInput__7MakeMsgFRC20CArchitectureMessage -/* 80024A88 000219E8 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 80024A8C 000219EC 3C 80 80 3E */ lis r4, lbl_803D9810@ha -/* 80024A90 000219F0 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 80024A88 000219E8 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 80024A8C 000219EC 3C 80 80 3E */ lis r4, __vt__21CArchMsgParmUserInput@ha +/* 80024A90 000219F0 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 80024A94 000219F4 90 01 00 60 */ stw r0, 0x60(r1) -/* 80024A98 000219F8 38 04 98 10 */ addi r0, r4, lbl_803D9810@l +/* 80024A98 000219F8 38 04 98 10 */ addi r0, r4, __vt__21CArchMsgParmUserInput@l /* 80024A9C 000219FC 90 01 00 60 */ stw r0, 0x60(r1) /* 80024AA0 00021A00 C0 03 00 04 */ lfs f0, 4(r3) /* 80024AA4 00021A04 D0 01 00 64 */ stfs f0, 0x64(r1) diff --git a/asm/MetroidPrime/CMainFlow.s b/asm/MetroidPrime/CMainFlow.s index ab88fbc0..9b0c6aad 100644 --- a/asm/MetroidPrime/CMainFlow.s +++ b/asm/MetroidPrime/CMainFlow.s @@ -418,11 +418,11 @@ lbl_8002394C: lbl_80023958: /* 80023958 000208B8 7C 83 23 78 */ mr r3, r4 /* 8002395C 000208BC 48 02 E1 7D */ bl GetParmNewGameflowState__7MakeMsgFRC20CArchitectureMessage -/* 80023960 000208C0 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 80023964 000208C4 3C 80 80 3E */ lis r4, lbl_803D9E50@ha -/* 80023968 000208C8 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 80023960 000208C0 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 80023964 000208C4 3C 80 80 3E */ lis r4, __vt__17CArchMsgParmInt32@ha +/* 80023968 000208C8 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 8002396C 000208CC 90 01 00 08 */ stw r0, 8(r1) -/* 80023970 000208D0 38 04 9E 50 */ addi r0, r4, lbl_803D9E50@l +/* 80023970 000208D0 38 04 9E 50 */ addi r0, r4, __vt__17CArchMsgParmInt32@l /* 80023974 000208D4 7F E5 FB 78 */ mr r5, r31 /* 80023978 000208D8 90 01 00 08 */ stw r0, 8(r1) /* 8002397C 000208DC 80 83 00 04 */ lwz r4, 4(r3) diff --git a/asm/MetroidPrime/CSlideShow.s b/asm/MetroidPrime/CSlideShow.s index 566034f8..463f4c09 100644 --- a/asm/MetroidPrime/CSlideShow.s +++ b/asm/MetroidPrime/CSlideShow.s @@ -3473,11 +3473,11 @@ lbl_8029A9C4: lbl_8029AA14: /* 8029AA14 00297974 7C 83 23 78 */ mr r3, r4 /* 8029AA18 00297978 4B DB 70 CD */ bl GetParmUserInput__7MakeMsgFRC20CArchitectureMessage -/* 8029AA1C 0029797C 3C A0 80 3E */ lis r5, lbl_803D8E9C@ha -/* 8029AA20 00297980 3C 80 80 3E */ lis r4, lbl_803D9810@ha -/* 8029AA24 00297984 38 05 8E 9C */ addi r0, r5, lbl_803D8E9C@l +/* 8029AA1C 0029797C 3C A0 80 3E */ lis r5, __vt__24IArchitectureMessageParm@ha +/* 8029AA20 00297980 3C 80 80 3E */ lis r4, __vt__21CArchMsgParmUserInput@ha +/* 8029AA24 00297984 38 05 8E 9C */ addi r0, r5, __vt__24IArchitectureMessageParm@l /* 8029AA28 00297988 90 01 00 90 */ stw r0, 0x90(r1) -/* 8029AA2C 0029798C 38 04 98 10 */ addi r0, r4, lbl_803D9810@l +/* 8029AA2C 0029798C 38 04 98 10 */ addi r0, r4, __vt__21CArchMsgParmUserInput@l /* 8029AA30 00297990 90 01 00 90 */ stw r0, 0x90(r1) /* 8029AA34 00297994 C0 03 00 04 */ lfs f0, 4(r3) /* 8029AA38 00297998 D0 01 00 94 */ stfs f0, 0x94(r1) diff --git a/asm/MetroidPrime/IRenderer.s b/asm/MetroidPrime/IRenderer.s index fd81a154..a1b4085d 100644 --- a/asm/MetroidPrime/IRenderer.s +++ b/asm/MetroidPrime/IRenderer.s @@ -73,8 +73,8 @@ lbl_803D8D90: .4byte 0 # CArchitectureMessage -.global lbl_803D8E9C -lbl_803D8E9C: +.global __vt__24IArchitectureMessageParm +__vt__24IArchitectureMessageParm: # ROM: 0x3D5E9C .4byte 0 .4byte 0 diff --git a/configure.py b/configure.py index 23651108..9ef6f9b7 100755 --- a/configure.py +++ b/configure.py @@ -26,6 +26,12 @@ COMPLETE_OBJECTS = [ "MetroTRK/mslsupp", "MetroidPrime/CAxisAngle", "MetroidPrime/CEntity", + "MetroidPrime/CArchMsgParmUserInput", + "MetroidPrime/CArchMsgParmInt32", + "MetroidPrime/CArchMsgParmInt32Int32VoidPtr", + "MetroidPrime/CArchMsgParmNull", + "MetroidPrime/CArchMsgParmReal32", + "MetroidPrime/CArchMsgParmControllerStatus", "MetroidPrime/TCastTo", "MetroidPrime/UserNames", "MetroidPrime/CPhysicsState", @@ -169,6 +175,7 @@ LIBS = [ "MetroidPrime/Player/CPlayer", "MetroidPrime/CAxisAngle", "MetroidPrime/CEulerAngles", + "MetroidPrime/CArchMsgParmUserInput", "MetroidPrime/CFrontEndUI", "MetroidPrime/CInputGenerator", "MetroidPrime/CMainFlow", diff --git a/include/Kyoto/Input/CFinalInput.hpp b/include/Kyoto/Input/CFinalInput.hpp new file mode 100644 index 00000000..1cffda45 --- /dev/null +++ b/include/Kyoto/Input/CFinalInput.hpp @@ -0,0 +1,94 @@ +#ifndef __CFINALINPUT_HPP__ +#define __CFINALINPUT_HPP__ + +#include +#ifdef __MWERKS__ +#pragma cpp_extensions on +#endif + +class CFinalInput { +public: + CFinalInput(const CFinalInput& other) + : x0_dt(other.x0_dt) + , x4_controllerIdx(other.x4_controllerIdx) + , x8_anaLeftX(other.x8_anaLeftX) + , xc_anaLeftY(other.xc_anaLeftY) + , x10_anaRightX(other.x10_anaRightX) + , x14_anaRightY(other.x14_anaRightY) + , x18_anaLeftTrigger(other.x18_anaLeftTrigger) + , x1c_anaRightTrigger(other.x1c_anaRightTrigger) + , x20_enableAnaLeftXP(other.x20_enableAnaLeftXP) + , x21_enableAnaLeftYP(other.x21_enableAnaLeftYP) + , x22_enableAnaRightXP(other.x22_enableAnaRightXP) + , x23_enableAnaRightYP(other.x23_enableAnaRightYP) + , x24_anaLeftTriggerP(other.x24_anaLeftTriggerP) + , x28_anaRightTriggerP(other.x28_anaRightTriggerP) + , btns1(other.btns1) + , btns2(other.btns2) + , btns3(other.btns3) {} + +private: + float x0_dt; + uint x4_controllerIdx; + float x8_anaLeftX; + float xc_anaLeftY; + float x10_anaRightX; + float x14_anaRightY; + float x18_anaLeftTrigger; + float x1c_anaRightTrigger; + + bool x20_enableAnaLeftXP; + bool x21_enableAnaLeftYP; + bool x22_enableAnaRightXP; + bool x23_enableAnaRightYP; + + float x24_anaLeftTriggerP; + float x28_anaRightTriggerP; + + union { + struct { + bool x2c_b24_A : 1; + bool x2c_b25_B : 1; + bool x2c_b26_X : 1; + bool x2c_b27_Y : 1; + bool x2c_b28_Z : 1; + bool x2c_b29_L : 1; + bool x2c_b30_R : 1; + bool x2c_b31_DPUp : 1; + }; + u8 btns1; + }; + union { + struct { + bool x2d_b24_DPRight : 1; + bool x2d_b25_DPDown : 1; + bool x2d_b26_DPLeft : 1; + bool x2d_b27_Start : 1; + bool x2d_b28_PA : 1; + bool x2d_b29_PB : 1; + bool x2d_b30_PX : 1; + bool x2d_b31_PY : 1; + }; + u8 btns2; + }; + union { + struct { + bool x2e_b24_PZ : 1; + bool x2e_b25_PL : 1; + bool x2e_b26_PR : 1; + bool x2e_b27_PDPUp : 1; + bool x2e_b28_PDPRight : 1; + bool x2e_b29_PDPDown : 1; + bool x2e_b30_PDPLeft : 1; + bool x2e_b31_PStart : 1; + }; + u8 btns3; + }; + +}; + +#ifdef __MWERKS__ +#pragma cpp_extensions reset +#endif + +#endif // __CFINALINPUT_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmControllerStatus.hpp b/include/MetroidPrime/CArchMsgParmControllerStatus.hpp new file mode 100644 index 00000000..9ce674dc --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmControllerStatus.hpp @@ -0,0 +1,16 @@ + +#ifndef __CARCMSGPARMCONTROLLERSTATUS_HPP__ +#define __CARCMSGPARMCONTROLLERSTATUS_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +class CArchMsgParmControllerStatus : public IArchitectureMessageParm { + short mChannel; + bool mConnected; + +public: + CArchMsgParmControllerStatus(short channel, bool connected); + ~CArchMsgParmControllerStatus(); +}; + +#endif // __CARCMSGPARMCONTROLLERSTATUS_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmInt32.hpp b/include/MetroidPrime/CArchMsgParmInt32.hpp new file mode 100644 index 00000000..6fb9b100 --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmInt32.hpp @@ -0,0 +1,13 @@ +#ifndef __CARCMSGPARMINT32_HPP__ +#define __CARCMSGPARMINT32_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +class CArchMsgParmInt32 : public IArchitectureMessageParm { + int mVal; +public: + CArchMsgParmInt32(int); + ~CArchMsgParmInt32(); +}; + +#endif // __CARCMSGPARMINT32_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.hpp b/include/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.hpp new file mode 100644 index 00000000..710d26f6 --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.hpp @@ -0,0 +1,17 @@ + +#ifndef __CARCMSGPARMINT32INT32VOIDPTR_HPP__ +#define __CARCMSGPARMINT32INT32VOIDPTR_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +class CArchMsgParmInt32Int32VoidPtr : public IArchitectureMessageParm { + int mInt1; + int mInt2; + const void* mPtr; + +public: + CArchMsgParmInt32Int32VoidPtr(int val1, int val2, const void* ptr); + ~CArchMsgParmInt32Int32VoidPtr(); +}; + +#endif // __CARCMSGPARMINT32INT32VOIDPTR_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmNull.hpp b/include/MetroidPrime/CArchMsgParmNull.hpp new file mode 100644 index 00000000..9a05cb2f --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmNull.hpp @@ -0,0 +1,12 @@ +#ifndef __CARCMSGPARMNULL_HPP__ +#define __CARCMSGPARMNULL_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +class CArchMsgParmNull : public IArchitectureMessageParm { +public: + CArchMsgParmNull(); + ~CArchMsgParmNull(); +}; + +#endif // __CARCMSGPARMNULL_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmReal32.hpp b/include/MetroidPrime/CArchMsgParmReal32.hpp new file mode 100644 index 00000000..a6509f02 --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmReal32.hpp @@ -0,0 +1,13 @@ +#ifndef __CARCMSGPARMREAL32_HPP__ +#define __CARCMSGPARMREAL32_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +class CArchMsgParmReal32 : public IArchitectureMessageParm { + float mVal; +public: + CArchMsgParmReal32(float); + ~CArchMsgParmReal32(); +}; + +#endif // __CARCMSGPARMREAL32_HPP__ diff --git a/include/MetroidPrime/CArchMsgParmUserInput.hpp b/include/MetroidPrime/CArchMsgParmUserInput.hpp new file mode 100644 index 00000000..eac00c64 --- /dev/null +++ b/include/MetroidPrime/CArchMsgParmUserInput.hpp @@ -0,0 +1,18 @@ +#ifndef __CARCMSGPARMUSERINPUT_HPP__ +#define __CARCMSGPARMUSERINPUT_HPP__ + +#include "MetroidPrime/CArchitectureMessage.hpp" + +#include "Kyoto/Input/CFinalInput.hpp" + +class CArchMsgParmUserInput : public IArchitectureMessageParm { +public: + CArchMsgParmUserInput(const CFinalInput& in); + ~CArchMsgParmUserInput(); + + const CFinalInput& GetUserInput() const; +private: + CFinalInput mInput; +}; + +#endif // __CARCMSGPARMUSERINPUT_HPP__ diff --git a/include/MetroidPrime/CArchitectureMessage.hpp b/include/MetroidPrime/CArchitectureMessage.hpp index f540ddf1..c80f4532 100644 --- a/include/MetroidPrime/CArchitectureMessage.hpp +++ b/include/MetroidPrime/CArchitectureMessage.hpp @@ -25,9 +25,11 @@ enum EArchMsgType { }; struct IArchitectureMessageParm { - virtual ~IArchitectureMessageParm() = 0; + inline virtual ~IArchitectureMessageParm() = 0; }; +IArchitectureMessageParm::~IArchitectureMessageParm() {} + class CArchitectureMessage { private: EArchMsgTarget x0_target; diff --git a/obj_files.mk b/obj_files.mk index a1a0582c..ccd5b621 100644 --- a/obj_files.mk +++ b/obj_files.mk @@ -11,6 +11,7 @@ METROIDPRIME :=\ $(BUILD_DIR)/asm/MetroidPrime/Player/CPlayer.o\ $(BUILD_DIR)/src/MetroidPrime/CAxisAngle.o\ $(BUILD_DIR)/asm/MetroidPrime/CEulerAngles.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmUserInput.o\ $(BUILD_DIR)/asm/MetroidPrime/CFrontEndUI.o\ $(BUILD_DIR)/asm/MetroidPrime/CInputGenerator.o\ $(BUILD_DIR)/asm/MetroidPrime/CMainFlow.o\ @@ -28,10 +29,10 @@ METROIDPRIME :=\ $(BUILD_DIR)/asm/MetroidPrime/Player/CPlayerGun.o\ $(BUILD_DIR)/asm/MetroidPrime/CStateManager.o\ $(BUILD_DIR)/src/MetroidPrime/CEntity.o\ - $(BUILD_DIR)/asm/MetroidPrime/CArchMsgParmInt32.o\ - $(BUILD_DIR)/asm/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.o\ - $(BUILD_DIR)/asm/MetroidPrime/CArchMsgParmNull.o\ - $(BUILD_DIR)/asm/MetroidPrime/CArchMsgParmReal32.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmInt32.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmNull.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmReal32.o\ $(BUILD_DIR)/asm/MetroidPrime/Decode.o\ $(BUILD_DIR)/asm/MetroidPrime/CIOWinManager.o\ $(BUILD_DIR)/src/MetroidPrime/CIOWin.o\ @@ -39,7 +40,7 @@ METROIDPRIME :=\ $(BUILD_DIR)/asm/MetroidPrime/CWorld.o\ $(BUILD_DIR)/asm/MetroidPrime/Tweaks/CTweakParticle.o\ $(BUILD_DIR)/asm/MetroidPrime/Clamp_int.o\ - $(BUILD_DIR)/asm/MetroidPrime/CArchMsgParmControllerStatus.o\ + $(BUILD_DIR)/src/MetroidPrime/CArchMsgParmControllerStatus.o\ $(BUILD_DIR)/asm/MetroidPrime/CExplosion.o\ $(BUILD_DIR)/asm/MetroidPrime/CEffect.o\ $(BUILD_DIR)/asm/MetroidPrime/Cameras/CGameCamera.o\ diff --git a/src/MetroidPrime/CArchMsgParmControllerStatus.cpp b/src/MetroidPrime/CArchMsgParmControllerStatus.cpp new file mode 100644 index 00000000..97fb1c5a --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmControllerStatus.cpp @@ -0,0 +1,11 @@ +#include "MetroidPrime/CArchMsgParmControllerStatus.hpp" +#include "Kyoto/Alloc/CMemory.hpp" + + +CArchMsgParmControllerStatus::CArchMsgParmControllerStatus(short channel, bool connected) +: mChannel(channel) +, mConnected(connected) { +} + + +CArchMsgParmControllerStatus::~CArchMsgParmControllerStatus() {} diff --git a/src/MetroidPrime/CArchMsgParmInt32.cpp b/src/MetroidPrime/CArchMsgParmInt32.cpp new file mode 100644 index 00000000..e3ac6303 --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmInt32.cpp @@ -0,0 +1,8 @@ +#include "MetroidPrime/CArchMsgParmInt32.hpp" +#include "Kyoto/Alloc/CMemory.hpp" + +CArchMsgParmInt32::CArchMsgParmInt32(int val) +: mVal(val) {} + + +CArchMsgParmInt32::~CArchMsgParmInt32() {} diff --git a/src/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.cpp b/src/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.cpp new file mode 100644 index 00000000..f26c5e64 --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmInt32Int32VoidPtr.cpp @@ -0,0 +1,10 @@ +#include "MetroidPrime/CArchMsgParmInt32Int32VoidPtr.hpp" + +#include "Kyoto/Alloc/CMemory.hpp" + +CArchMsgParmInt32Int32VoidPtr::CArchMsgParmInt32Int32VoidPtr(int val1, int val2, const void* ptr) +: mInt1(val1) +, mInt2(val2) +, mPtr(ptr) {} + +CArchMsgParmInt32Int32VoidPtr::~CArchMsgParmInt32Int32VoidPtr() {} diff --git a/src/MetroidPrime/CArchMsgParmNull.cpp b/src/MetroidPrime/CArchMsgParmNull.cpp new file mode 100644 index 00000000..887cd898 --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmNull.cpp @@ -0,0 +1,5 @@ +#include "MetroidPrime/CArchMsgParmNull.hpp" +#include "Kyoto/Alloc/CMemory.hpp" + +CArchMsgParmNull::CArchMsgParmNull() {} +CArchMsgParmNull::~CArchMsgParmNull() {} diff --git a/src/MetroidPrime/CArchMsgParmReal32.cpp b/src/MetroidPrime/CArchMsgParmReal32.cpp new file mode 100644 index 00000000..ea8dace5 --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmReal32.cpp @@ -0,0 +1,8 @@ +#include "MetroidPrime/CArchMsgParmReal32.hpp" +#include "Kyoto/Alloc/CMemory.hpp" + +CArchMsgParmReal32::CArchMsgParmReal32(float val) +: mVal(val) {} + + +CArchMsgParmReal32::~CArchMsgParmReal32() {} diff --git a/src/MetroidPrime/CArchMsgParmUserInput.cpp b/src/MetroidPrime/CArchMsgParmUserInput.cpp new file mode 100644 index 00000000..09a82c9c --- /dev/null +++ b/src/MetroidPrime/CArchMsgParmUserInput.cpp @@ -0,0 +1,12 @@ +#include "MetroidPrime/CArchMsgParmUserInput.hpp" + +#include "Kyoto/Alloc/CMemory.hpp" + +CArchMsgParmUserInput::CArchMsgParmUserInput(const CFinalInput& input) +: mInput(input) {} + +CArchMsgParmUserInput::~CArchMsgParmUserInput() {} + +const CFinalInput& CArchMsgParmUserInput::GetUserInput() const { + return mInput; +}