mirror of https://github.com/PrimeDecomp/prime.git
Match and link CFinalInput
This commit is contained in:
parent
41070ecd75
commit
bacfa6a458
|
@ -452,7 +452,7 @@ lbl_802C6060:
|
|||
ProcessUserInput__15CGuiSliderGroupFRC11CFinalInput:
|
||||
/* 802C611C 002C307C 94 21 FF F0 */ stwu r1, -0x10(r1)
|
||||
/* 802C6120 002C3080 7C 08 02 A6 */ mflr r0
|
||||
/* 802C6124 002C3084 C0 42 CC 28 */ lfs f2, lbl_805AE948@sda21(r2)
|
||||
/* 802C6124 002C3084 C0 42 CC 28 */ lfs f2, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802C6128 002C3088 90 01 00 14 */ stw r0, 0x14(r1)
|
||||
/* 802C612C 002C308C FC 00 10 50 */ fneg f0, f2
|
||||
/* 802C6130 002C3090 C0 24 00 08 */ lfs f1, 8(r4)
|
||||
|
@ -681,4 +681,3 @@ lbl_803D68C0:
|
|||
# ROM: 0x3D38C0
|
||||
.asciz "??(??)"
|
||||
.balign 4
|
||||
|
||||
|
|
|
@ -1152,7 +1152,7 @@ lbl_802C7498:
|
|||
/* 802C7498 002C43F8 88 7E 00 D1 */ lbz r3, 0xd1(r30)
|
||||
/* 802C749C 002C43FC 28 03 00 00 */ cmplwi r3, 0
|
||||
/* 802C74A0 002C4400 41 82 00 2C */ beq lbl_802C74CC
|
||||
/* 802C74A4 002C4404 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 802C74A4 002C4404 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802C74A8 002C4408 3B A0 00 01 */ li r29, 1
|
||||
/* 802C74AC 002C440C C0 1F 00 0C */ lfs f0, 0xc(r31)
|
||||
/* 802C74B0 002C4410 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1163,7 +1163,7 @@ lbl_802C7498:
|
|||
/* 802C74C4 002C4424 3B A0 00 00 */ li r29, 0
|
||||
/* 802C74C8 002C4428 48 00 00 28 */ b lbl_802C74F0
|
||||
lbl_802C74CC:
|
||||
/* 802C74CC 002C442C C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 802C74CC 002C442C C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802C74D0 002C4430 3B A0 00 01 */ li r29, 1
|
||||
/* 802C74D4 002C4434 C0 1F 00 08 */ lfs f0, 8(r31)
|
||||
/* 802C74D8 002C4438 FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1175,7 +1175,7 @@ lbl_802C74CC:
|
|||
lbl_802C74F0:
|
||||
/* 802C74F0 002C4450 28 03 00 00 */ cmplwi r3, 0
|
||||
/* 802C74F4 002C4454 41 82 00 30 */ beq lbl_802C7524
|
||||
/* 802C74F8 002C4458 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 802C74F8 002C4458 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802C74FC 002C445C 3B 80 00 01 */ li r28, 1
|
||||
/* 802C7500 002C4460 C0 1F 00 0C */ lfs f0, 0xc(r31)
|
||||
/* 802C7504 002C4464 FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1187,7 +1187,7 @@ lbl_802C74F0:
|
|||
/* 802C751C 002C447C 3B 80 00 00 */ li r28, 0
|
||||
/* 802C7520 002C4480 48 00 00 28 */ b lbl_802C7548
|
||||
lbl_802C7524:
|
||||
/* 802C7524 002C4484 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 802C7524 002C4484 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802C7528 002C4488 3B 80 00 01 */ li r28, 1
|
||||
/* 802C752C 002C448C C0 1F 00 08 */ lfs f0, 8(r31)
|
||||
/* 802C7530 002C4490 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1238,4 +1238,3 @@ lbl_803D68D0:
|
|||
# ROM: 0x3D38D0
|
||||
.asciz "??(??)"
|
||||
.balign 4
|
||||
|
||||
|
|
|
@ -1225,15 +1225,15 @@ __ct__11CFinalInputFv:
|
|||
|
||||
.section .sdata2, "a"
|
||||
.balign 8
|
||||
.global lbl_805AE948
|
||||
lbl_805AE948:
|
||||
.global kInput_AnalogOnThreshhold__11CFinalInput
|
||||
kInput_AnalogOnThreshhold__11CFinalInput:
|
||||
# ROM: 0x3FB1E8
|
||||
.float 0.7
|
||||
|
||||
.global lbl_805AE94C
|
||||
lbl_805AE94C:
|
||||
.global kInput_AnalogTriggerOnThreshhold__11CFinalInput
|
||||
kInput_AnalogTriggerOnThreshhold__11CFinalInput:
|
||||
# ROM: 0x3FB1EC
|
||||
.4byte 0x3D4CCCCD
|
||||
.float 0.05
|
||||
|
||||
.global lbl_805AE950
|
||||
lbl_805AE950:
|
||||
|
@ -1250,4 +1250,3 @@ lbl_805AE958:
|
|||
# ROM: 0x3FB1F8
|
||||
.4byte 0xBF333333
|
||||
.4byte 0
|
||||
|
||||
|
|
|
@ -1439,7 +1439,7 @@ PDPUp__11CFinalInputCFv:
|
|||
|
||||
.global PRTrigger__11CFinalInputCFv
|
||||
PRTrigger__11CFinalInputCFv:
|
||||
/* 8000D058 00009FB8 C0 22 CC 2C */ lfs f1, lbl_805AE94C@sda21(r2)
|
||||
/* 8000D058 00009FB8 C0 22 CC 2C */ lfs f1, kInput_AnalogTriggerOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D05C 00009FBC C0 03 00 28 */ lfs f0, 0x28(r3)
|
||||
/* 8000D060 00009FC0 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D064 00009FC4 40 80 00 0C */ bge lbl_8000D070
|
||||
|
@ -1451,7 +1451,7 @@ lbl_8000D070:
|
|||
|
||||
.global PLTrigger__11CFinalInputCFv
|
||||
PLTrigger__11CFinalInputCFv:
|
||||
/* 8000D078 00009FD8 C0 22 CC 2C */ lfs f1, lbl_805AE94C@sda21(r2)
|
||||
/* 8000D078 00009FD8 C0 22 CC 2C */ lfs f1, kInput_AnalogTriggerOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D07C 00009FDC C0 03 00 24 */ lfs f0, 0x24(r3)
|
||||
/* 8000D080 00009FE0 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D084 00009FE4 40 80 00 0C */ bge lbl_8000D090
|
||||
|
@ -1463,7 +1463,7 @@ lbl_8000D090:
|
|||
|
||||
.global PRARight__11CFinalInputCFv
|
||||
PRARight__11CFinalInputCFv:
|
||||
/* 8000D098 00009FF8 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D098 00009FF8 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D09C 00009FFC 38 80 00 00 */ li r4, 0
|
||||
/* 8000D0A0 0000A000 C0 03 00 10 */ lfs f0, 0x10(r3)
|
||||
/* 8000D0A4 0000A004 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1481,7 +1481,7 @@ lbl_8000D0BC:
|
|||
|
||||
.global PRALeft__11CFinalInputCFv
|
||||
PRALeft__11CFinalInputCFv:
|
||||
/* 8000D0D0 0000A030 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D0D0 0000A030 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D0D4 0000A034 38 80 00 00 */ li r4, 0
|
||||
/* 8000D0D8 0000A038 C0 03 00 10 */ lfs f0, 0x10(r3)
|
||||
/* 8000D0DC 0000A03C FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1500,7 +1500,7 @@ lbl_8000D0F8:
|
|||
|
||||
.global PRADown__11CFinalInputCFv
|
||||
PRADown__11CFinalInputCFv:
|
||||
/* 8000D10C 0000A06C C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D10C 0000A06C C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D110 0000A070 38 80 00 00 */ li r4, 0
|
||||
/* 8000D114 0000A074 C0 03 00 14 */ lfs f0, 0x14(r3)
|
||||
/* 8000D118 0000A078 FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1519,7 +1519,7 @@ lbl_8000D134:
|
|||
|
||||
.global PRAUp__11CFinalInputCFv
|
||||
PRAUp__11CFinalInputCFv:
|
||||
/* 8000D148 0000A0A8 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D148 0000A0A8 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D14C 0000A0AC 38 80 00 00 */ li r4, 0
|
||||
/* 8000D150 0000A0B0 C0 03 00 14 */ lfs f0, 0x14(r3)
|
||||
/* 8000D154 0000A0B4 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1537,7 +1537,7 @@ lbl_8000D16C:
|
|||
|
||||
.global PLARight__11CFinalInputCFv
|
||||
PLARight__11CFinalInputCFv:
|
||||
/* 8000D180 0000A0E0 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D180 0000A0E0 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D184 0000A0E4 38 80 00 00 */ li r4, 0
|
||||
/* 8000D188 0000A0E8 C0 03 00 08 */ lfs f0, 8(r3)
|
||||
/* 8000D18C 0000A0EC FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1555,7 +1555,7 @@ lbl_8000D1A4:
|
|||
|
||||
.global PLALeft__11CFinalInputCFv
|
||||
PLALeft__11CFinalInputCFv:
|
||||
/* 8000D1B8 0000A118 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D1B8 0000A118 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D1BC 0000A11C 38 80 00 00 */ li r4, 0
|
||||
/* 8000D1C0 0000A120 C0 03 00 08 */ lfs f0, 8(r3)
|
||||
/* 8000D1C4 0000A124 FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1574,7 +1574,7 @@ lbl_8000D1E0:
|
|||
|
||||
.global PLADown__11CFinalInputCFv
|
||||
PLADown__11CFinalInputCFv:
|
||||
/* 8000D1F4 0000A154 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D1F4 0000A154 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D1F8 0000A158 38 80 00 00 */ li r4, 0
|
||||
/* 8000D1FC 0000A15C C0 03 00 0C */ lfs f0, 0xc(r3)
|
||||
/* 8000D200 0000A160 FC 20 08 50 */ fneg f1, f1
|
||||
|
@ -1593,7 +1593,7 @@ lbl_8000D21C:
|
|||
|
||||
.global PLAUp__11CFinalInputCFv
|
||||
PLAUp__11CFinalInputCFv:
|
||||
/* 8000D230 0000A190 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D230 0000A190 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D234 0000A194 38 80 00 00 */ li r4, 0
|
||||
/* 8000D238 0000A198 C0 03 00 0C */ lfs f0, 0xc(r3)
|
||||
/* 8000D23C 0000A19C FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1719,7 +1719,7 @@ DDPUp__11CFinalInputCFv:
|
|||
|
||||
.global DRTrigger__11CFinalInputCFv
|
||||
DRTrigger__11CFinalInputCFv:
|
||||
/* 8000D388 0000A2E8 C0 22 CC 2C */ lfs f1, lbl_805AE94C@sda21(r2)
|
||||
/* 8000D388 0000A2E8 C0 22 CC 2C */ lfs f1, kInput_AnalogTriggerOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D38C 0000A2EC C0 03 00 1C */ lfs f0, 0x1c(r3)
|
||||
/* 8000D390 0000A2F0 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D394 0000A2F4 40 80 00 0C */ bge lbl_8000D3A0
|
||||
|
@ -1731,7 +1731,7 @@ lbl_8000D3A0:
|
|||
|
||||
.global DLTrigger__11CFinalInputCFv
|
||||
DLTrigger__11CFinalInputCFv:
|
||||
/* 8000D3A8 0000A308 C0 22 CC 2C */ lfs f1, lbl_805AE94C@sda21(r2)
|
||||
/* 8000D3A8 0000A308 C0 22 CC 2C */ lfs f1, kInput_AnalogTriggerOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D3AC 0000A30C C0 03 00 18 */ lfs f0, 0x18(r3)
|
||||
/* 8000D3B0 0000A310 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D3B4 0000A314 40 80 00 0C */ bge lbl_8000D3C0
|
||||
|
@ -1743,7 +1743,7 @@ lbl_8000D3C0:
|
|||
|
||||
.global DRARight__11CFinalInputCFv
|
||||
DRARight__11CFinalInputCFv:
|
||||
/* 8000D3C8 0000A328 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D3C8 0000A328 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D3CC 0000A32C C0 03 00 10 */ lfs f0, 0x10(r3)
|
||||
/* 8000D3D0 0000A330 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D3D4 0000A334 40 80 00 0C */ bge lbl_8000D3E0
|
||||
|
@ -1755,7 +1755,7 @@ lbl_8000D3E0:
|
|||
|
||||
.global DRALeft__11CFinalInputCFv
|
||||
DRALeft__11CFinalInputCFv:
|
||||
/* 8000D3E8 0000A348 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D3E8 0000A348 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D3EC 0000A34C C0 03 00 10 */ lfs f0, 0x10(r3)
|
||||
/* 8000D3F0 0000A350 FC 20 08 50 */ fneg f1, f1
|
||||
/* 8000D3F4 0000A354 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1768,7 +1768,7 @@ lbl_8000D404:
|
|||
|
||||
.global DRADown__11CFinalInputCFv
|
||||
DRADown__11CFinalInputCFv:
|
||||
/* 8000D40C 0000A36C C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D40C 0000A36C C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D410 0000A370 C0 03 00 14 */ lfs f0, 0x14(r3)
|
||||
/* 8000D414 0000A374 FC 20 08 50 */ fneg f1, f1
|
||||
/* 8000D418 0000A378 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1781,7 +1781,7 @@ lbl_8000D428:
|
|||
|
||||
.global DRAUp__11CFinalInputCFv
|
||||
DRAUp__11CFinalInputCFv:
|
||||
/* 8000D430 0000A390 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D430 0000A390 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D434 0000A394 C0 03 00 14 */ lfs f0, 0x14(r3)
|
||||
/* 8000D438 0000A398 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D43C 0000A39C 40 80 00 0C */ bge lbl_8000D448
|
||||
|
@ -1793,7 +1793,7 @@ lbl_8000D448:
|
|||
|
||||
.global DLARight__11CFinalInputCFv
|
||||
DLARight__11CFinalInputCFv:
|
||||
/* 8000D450 0000A3B0 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D450 0000A3B0 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D454 0000A3B4 C0 03 00 08 */ lfs f0, 8(r3)
|
||||
/* 8000D458 0000A3B8 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D45C 0000A3BC 40 80 00 0C */ bge lbl_8000D468
|
||||
|
@ -1805,7 +1805,7 @@ lbl_8000D468:
|
|||
|
||||
.global DLALeft__11CFinalInputCFv
|
||||
DLALeft__11CFinalInputCFv:
|
||||
/* 8000D470 0000A3D0 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D470 0000A3D0 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D474 0000A3D4 C0 03 00 08 */ lfs f0, 8(r3)
|
||||
/* 8000D478 0000A3D8 FC 20 08 50 */ fneg f1, f1
|
||||
/* 8000D47C 0000A3DC FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1818,7 +1818,7 @@ lbl_8000D48C:
|
|||
|
||||
.global DLADown__11CFinalInputCFv
|
||||
DLADown__11CFinalInputCFv:
|
||||
/* 8000D494 0000A3F4 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D494 0000A3F4 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D498 0000A3F8 C0 03 00 0C */ lfs f0, 0xc(r3)
|
||||
/* 8000D49C 0000A3FC FC 20 08 50 */ fneg f1, f1
|
||||
/* 8000D4A0 0000A400 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
|
@ -1831,7 +1831,7 @@ lbl_8000D4B0:
|
|||
|
||||
.global DLAUp__11CFinalInputCFv
|
||||
DLAUp__11CFinalInputCFv:
|
||||
/* 8000D4B8 0000A418 C0 22 CC 28 */ lfs f1, lbl_805AE948@sda21(r2)
|
||||
/* 8000D4B8 0000A418 C0 22 CC 28 */ lfs f1, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 8000D4BC 0000A41C C0 03 00 0C */ lfs f0, 0xc(r3)
|
||||
/* 8000D4C0 0000A420 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 8000D4C4 0000A424 40 80 00 0C */ bge lbl_8000D4D0
|
||||
|
|
|
@ -1660,7 +1660,7 @@ lbl_802071A0:
|
|||
/* 802071D4 00204134 7C 00 00 34 */ cntlzw r0, r0
|
||||
/* 802071D8 00204138 54 1D D9 7E */ srwi r29, r0, 5
|
||||
/* 802071DC 0020413C 41 82 01 34 */ beq lbl_80207310
|
||||
/* 802071E0 00204140 C0 02 CC 28 */ lfs f0, lbl_805AE948@sda21(r2)
|
||||
/* 802071E0 00204140 C0 02 CC 28 */ lfs f0, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 802071E4 00204144 38 80 00 00 */ li r4, 0
|
||||
/* 802071E8 00204148 C0 3C 00 0C */ lfs f1, 0xc(r28)
|
||||
/* 802071EC 0020414C FC 00 08 40 */ fcmpo cr0, f0, f1
|
||||
|
|
|
@ -1901,7 +1901,7 @@ ProcessInput__14CLogBookScreenFRC11CFinalInput:
|
|||
/* 80247364 002442C4 7C 00 00 34 */ cntlzw r0, r0
|
||||
/* 80247368 002442C8 54 1D D9 7E */ srwi r29, r0, 5
|
||||
/* 8024736C 002442CC 41 82 01 34 */ beq lbl_802474A0
|
||||
/* 80247370 002442D0 C0 02 CC 28 */ lfs f0, lbl_805AE948@sda21(r2)
|
||||
/* 80247370 002442D0 C0 02 CC 28 */ lfs f0, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 80247374 002442D4 38 80 00 00 */ li r4, 0
|
||||
/* 80247378 002442D8 C0 3C 00 0C */ lfs f1, 0xc(r28)
|
||||
/* 8024737C 002442DC FC 00 08 40 */ fcmpo cr0, f0, f1
|
||||
|
|
|
@ -2684,7 +2684,7 @@ lbl_80072DC0:
|
|||
/* 80072DD8 0006FD38 7F 46 D3 78 */ mr r6, r26
|
||||
/* 80072DDC 0006FD3C 48 00 09 21 */ bl StartTransition__12CPauseScreenFfRC13CStateManagerQ212CPauseScreen10ESubScreeni
|
||||
lbl_80072DE0:
|
||||
/* 80072DE0 0006FD40 C0 22 CC 2C */ lfs f1, lbl_805AE94C@sda21(r2)
|
||||
/* 80072DE0 0006FD40 C0 22 CC 2C */ lfs f1, kInput_AnalogTriggerOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 80072DE4 0006FD44 C0 1C 00 18 */ lfs f0, 0x18(r28)
|
||||
/* 80072DE8 0006FD48 FC 01 00 40 */ fcmpo cr0, f1, f0
|
||||
/* 80072DEC 0006FD4C 40 80 00 0C */ bge lbl_80072DF8
|
||||
|
|
|
@ -1204,7 +1204,7 @@ lbl_800290FC:
|
|||
/* 80029114 00026074 80 1D 00 20 */ lwz r0, 0x20(r29)
|
||||
/* 80029118 00026078 2C 00 00 01 */ cmpwi r0, 1
|
||||
/* 8002911C 0002607C 40 82 00 A0 */ bne lbl_800291BC
|
||||
/* 80029120 00026080 C0 42 CC 28 */ lfs f2, lbl_805AE948@sda21(r2)
|
||||
/* 80029120 00026080 C0 42 CC 28 */ lfs f2, kInput_AnalogOnThreshhold__11CFinalInput@sda21(r2)
|
||||
/* 80029124 00026084 C0 23 00 08 */ lfs f1, 8(r3)
|
||||
/* 80029128 00026088 FC 00 10 50 */ fneg f0, f2
|
||||
/* 8002912C 0002608C FC 00 08 40 */ fcmpo cr0, f0, f1
|
||||
|
|
|
@ -75,6 +75,7 @@ COMPLETE_OBJECTS = [
|
|||
"Kyoto/zlib/infutil",
|
||||
"Kyoto/zlib/zutil",
|
||||
"Kyoto/Graphics/CColor",
|
||||
"Kyoto/Input/CFinalInput",
|
||||
"Kyoto/Input/RumbleAdsr",
|
||||
"Kyoto/Input/DolphinIController",
|
||||
"Kyoto/Input/CDolphinController",
|
||||
|
|
|
@ -19,6 +19,8 @@ public:
|
|||
COsKeyState(int key, bool down, bool released, bool repeat, bool unk)
|
||||
: x0_key(key), x4_down(down), x4_released(released), x4_repeat(repeat), x4_unk(unk) {}
|
||||
|
||||
bool IsPressed() const { return x4_down; }
|
||||
bool JustPressed() const { return x4_unk && x4_down; }
|
||||
private:
|
||||
int x0_key;
|
||||
short x4_down : 1;
|
||||
|
|
|
@ -7,9 +7,9 @@ public:
|
|||
void SetIsPressed(bool pressed) { x0_pressed = pressed; }
|
||||
uint GetIsPressed() const { return x0_pressed; }
|
||||
void SetPressEvent(bool press) { x1_pressEvent = press; }
|
||||
bool GetPressEvent() const { return x1_pressEvent; }
|
||||
uint GetPressEvent() const { return x1_pressEvent; }
|
||||
void SetReleaseEvent(bool release) { x2_releaseEvent = release; };
|
||||
bool GetReleaseEvent() const { return x2_releaseEvent; }
|
||||
uint GetReleaseEvent() const { return x2_releaseEvent; }
|
||||
|
||||
private:
|
||||
uchar x0_pressed;
|
||||
|
|
|
@ -6,8 +6,17 @@
|
|||
#pragma cpp_extensions on
|
||||
#endif
|
||||
|
||||
class CControllerGamepadData;
|
||||
class COsContext;
|
||||
class CFinalInput {
|
||||
|
||||
static const float kInput_AnalogOnThreshhold;
|
||||
static const float kInput_AnalogTriggerOnThreshhold;
|
||||
public:
|
||||
CFinalInput();
|
||||
CFinalInput(int channel, float dt, const CControllerGamepadData& data, float leftDif,
|
||||
float rightDiv);
|
||||
CFinalInput(int channel, float dt, const COsContext& context);
|
||||
CFinalInput(const CFinalInput& other)
|
||||
: x0_dt(other.x0_dt)
|
||||
, x4_controllerIdx(other.x4_controllerIdx)
|
||||
|
@ -27,6 +36,10 @@ public:
|
|||
, btns2(other.btns2)
|
||||
, btns3(other.btns3) {}
|
||||
|
||||
void InitializeAnalog(float leftDiv, float rightDiv);
|
||||
|
||||
CFinalInput ScaleAnalogueSticks(float leftDiv, float rightDiv) const;
|
||||
|
||||
private:
|
||||
float x0_dt;
|
||||
uint x4_controllerIdx;
|
||||
|
@ -47,44 +60,43 @@ private:
|
|||
|
||||
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;
|
||||
uchar x2c_b24_A : 1;
|
||||
uchar x2c_b25_B : 1;
|
||||
uchar x2c_b26_X : 1;
|
||||
uchar x2c_b27_Y : 1;
|
||||
uchar x2c_b28_Z : 1;
|
||||
uchar x2c_b29_L : 1;
|
||||
uchar x2c_b30_R : 1;
|
||||
uchar x2c_b31_DPUp : 1;
|
||||
};
|
||||
u8 btns1;
|
||||
uchar 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;
|
||||
uchar x2d_b24_DPRight : 1;
|
||||
uchar x2d_b25_DPDown : 1;
|
||||
uchar x2d_b26_DPLeft : 1;
|
||||
uchar x2d_b27_Start : 1;
|
||||
uchar x2d_b28_PA : 1;
|
||||
uchar x2d_b29_PB : 1;
|
||||
uchar x2d_b30_PX : 1;
|
||||
uchar x2d_b31_PY : 1;
|
||||
};
|
||||
u8 btns2;
|
||||
uchar 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;
|
||||
uchar x2e_b24_PZ : 1;
|
||||
uchar x2e_b25_PL : 1;
|
||||
uchar x2e_b26_PR : 1;
|
||||
uchar x2e_b27_PDPUp : 1;
|
||||
uchar x2e_b28_PDPRight : 1;
|
||||
uchar x2e_b29_PDPDown : 1;
|
||||
uchar x2e_b30_PDPLeft : 1;
|
||||
uchar x2e_b31_PStart : 1;
|
||||
};
|
||||
u8 btns3;
|
||||
uchar btns3;
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
#ifdef __MWERKS__
|
||||
|
|
|
@ -0,0 +1,207 @@
|
|||
#include "Kyoto/Input/CFinalInput.hpp"
|
||||
|
||||
#include "Kyoto/Basics/COsContext.hpp"
|
||||
#include "Kyoto/Input/CControllerGamepadData.hpp"
|
||||
#include "Kyoto/Math/CMath.hpp"
|
||||
|
||||
const float CFinalInput::kInput_AnalogOnThreshhold = 0.7f;
|
||||
const float CFinalInput::kInput_AnalogTriggerOnThreshhold = 0.05f;
|
||||
|
||||
CFinalInput::CFinalInput()
|
||||
: x0_dt(0.f)
|
||||
, x4_controllerIdx(0)
|
||||
, x8_anaLeftX(0.f)
|
||||
, xc_anaLeftY(0.f)
|
||||
, x10_anaRightX(0.f)
|
||||
, x14_anaRightY(0.f)
|
||||
, x18_anaLeftTrigger(0.f)
|
||||
, x1c_anaRightTrigger(0.f)
|
||||
, x20_enableAnaLeftXP(false)
|
||||
, x21_enableAnaLeftYP(false)
|
||||
, x22_enableAnaRightXP(false)
|
||||
, x23_enableAnaRightYP(false)
|
||||
, x24_anaLeftTriggerP(0.f)
|
||||
, x28_anaRightTriggerP(0.f)
|
||||
, x2c_b24_A(false)
|
||||
, x2c_b25_B(false)
|
||||
, x2c_b26_X(false)
|
||||
, x2c_b27_Y(false)
|
||||
, x2c_b28_Z(false)
|
||||
, x2c_b29_L(false)
|
||||
, x2c_b30_R(false)
|
||||
, x2c_b31_DPUp(false)
|
||||
, x2d_b24_DPRight(false)
|
||||
, x2d_b25_DPDown(false)
|
||||
, x2d_b26_DPLeft(false)
|
||||
, x2d_b27_Start(false)
|
||||
, x2d_b28_PA(false)
|
||||
, x2d_b29_PB(false)
|
||||
, x2d_b30_PX(false)
|
||||
, x2d_b31_PY(false)
|
||||
, x2e_b24_PZ(false)
|
||||
, x2e_b25_PL(false)
|
||||
, x2e_b26_PR(false)
|
||||
, x2e_b27_PDPUp(false)
|
||||
, x2e_b28_PDPRight(false)
|
||||
, x2e_b29_PDPDown(false)
|
||||
, x2e_b30_PDPLeft(false)
|
||||
, x2e_b31_PStart(false) {}
|
||||
|
||||
CFinalInput::CFinalInput(int channel, float dt, const CControllerGamepadData& data, float leftDiv,
|
||||
float rightDiv)
|
||||
: x0_dt(dt)
|
||||
, x4_controllerIdx(channel)
|
||||
, x8_anaLeftX(data.GetAxis(kJA_LeftX).GetAbsoluteValue())
|
||||
, xc_anaLeftY(data.GetAxis(kJA_LeftY).GetAbsoluteValue())
|
||||
, x10_anaRightX(data.GetAxis(kJA_RightX).GetAbsoluteValue())
|
||||
, x14_anaRightY(data.GetAxis(kJA_RightY).GetAbsoluteValue())
|
||||
, x18_anaLeftTrigger(data.GetAnalogButton(kBA_Left).GetAbsoluteValue())
|
||||
, x1c_anaRightTrigger(data.GetAnalogButton(kBA_Right).GetAbsoluteValue())
|
||||
, x24_anaLeftTriggerP(data.GetAnalogButton(kBA_Left).GetRelativeValue())
|
||||
, x28_anaRightTriggerP(data.GetAnalogButton(kBA_Right).GetRelativeValue())
|
||||
, x20_enableAnaLeftXP(false)
|
||||
, x21_enableAnaLeftYP(false)
|
||||
, x22_enableAnaRightXP(false)
|
||||
, x23_enableAnaRightYP(false)
|
||||
, x2c_b24_A(data.GetButton(kBU_A).GetIsPressed())
|
||||
, x2c_b25_B(data.GetButton(kBU_B).GetIsPressed())
|
||||
, x2c_b26_X(data.GetButton(kBU_X).GetIsPressed())
|
||||
, x2c_b27_Y(data.GetButton(kBU_Y).GetIsPressed())
|
||||
, x2c_b28_Z(data.GetButton(kBU_Z).GetIsPressed())
|
||||
, x2c_b29_L(data.GetButton(kBU_L).GetIsPressed())
|
||||
, x2c_b30_R(data.GetButton(kBU_R).GetIsPressed())
|
||||
, x2c_b31_DPUp(data.GetButton(kBU_Up).GetIsPressed())
|
||||
, x2d_b24_DPRight(data.GetButton(kBU_Right).GetIsPressed())
|
||||
, x2d_b25_DPDown(data.GetButton(kBU_Down).GetIsPressed())
|
||||
, x2d_b26_DPLeft(data.GetButton(kBU_Left).GetIsPressed())
|
||||
, x2d_b27_Start(data.GetButton(kBU_Start).GetIsPressed())
|
||||
, x2d_b28_PA(data.GetButton(kBU_A).GetPressEvent())
|
||||
, x2d_b29_PB(data.GetButton(kBU_B).GetPressEvent())
|
||||
, x2d_b30_PX(data.GetButton(kBU_X).GetPressEvent())
|
||||
, x2d_b31_PY(data.GetButton(kBU_Y).GetPressEvent())
|
||||
, x2e_b24_PZ(data.GetButton(kBU_Z).GetPressEvent())
|
||||
, x2e_b25_PL(data.GetButton(kBU_L).GetPressEvent())
|
||||
, x2e_b26_PR(data.GetButton(kBU_R).GetPressEvent())
|
||||
, x2e_b27_PDPUp(data.GetButton(kBU_Up).GetPressEvent())
|
||||
, x2e_b28_PDPRight(data.GetButton(kBU_Right).GetPressEvent())
|
||||
, x2e_b29_PDPDown(data.GetButton(kBU_Down).GetPressEvent())
|
||||
, x2e_b30_PDPLeft(data.GetButton(kBU_Left).GetPressEvent())
|
||||
, x2e_b31_PStart(data.GetButton(kBU_Start).GetPressEvent()) {
|
||||
InitializeAnalog(leftDiv, rightDiv);
|
||||
}
|
||||
|
||||
static bool sIsAnalogPressed[4][4] = {};
|
||||
|
||||
void CFinalInput::InitializeAnalog(float leftDiv, float rightDiv) {
|
||||
x8_anaLeftX = CMath::Clamp(-1.f, x8_anaLeftX / leftDiv, 1.f);
|
||||
xc_anaLeftY = CMath::Clamp(-1.f, xc_anaLeftY / leftDiv, 1.f);
|
||||
x10_anaRightX = CMath::Clamp(-1.f, x10_anaRightX / rightDiv, 1.f);
|
||||
x14_anaRightY = CMath::Clamp(-1.f, x14_anaRightY / rightDiv, 1.f);
|
||||
|
||||
if (xc_anaLeftY > 0.7f && !sIsAnalogPressed[x4_controllerIdx][0]) {
|
||||
sIsAnalogPressed[x4_controllerIdx][0] = true;
|
||||
x21_enableAnaLeftYP = true;
|
||||
} else if (xc_anaLeftY > 0.7f && sIsAnalogPressed[x4_controllerIdx][0]) {
|
||||
x21_enableAnaLeftYP = false;
|
||||
} else if (xc_anaLeftY < -0.7f && !sIsAnalogPressed[x4_controllerIdx][0]) {
|
||||
x21_enableAnaLeftYP = true;
|
||||
sIsAnalogPressed[x4_controllerIdx][0] = true;
|
||||
} else if (xc_anaLeftY < -0.7f && sIsAnalogPressed[x4_controllerIdx][0]) {
|
||||
x21_enableAnaLeftYP = false;
|
||||
} else if ((float)fabs(xc_anaLeftY) < 0.7f) {
|
||||
x21_enableAnaLeftYP = false;
|
||||
sIsAnalogPressed[x4_controllerIdx][0] = false;
|
||||
}
|
||||
|
||||
if (x8_anaLeftX > 0.7f && !sIsAnalogPressed[x4_controllerIdx][1]) {
|
||||
x20_enableAnaLeftXP = true;
|
||||
sIsAnalogPressed[x4_controllerIdx][1] = true;
|
||||
} else if (x8_anaLeftX > 0.7f && sIsAnalogPressed[x4_controllerIdx][1]) {
|
||||
x20_enableAnaLeftXP = false;
|
||||
} else if (x8_anaLeftX < -0.7f && !sIsAnalogPressed[x4_controllerIdx][1]) {
|
||||
sIsAnalogPressed[x4_controllerIdx][1] = true;
|
||||
x20_enableAnaLeftXP = true;
|
||||
} else if (x8_anaLeftX < -0.7f && sIsAnalogPressed[x4_controllerIdx][1]) {
|
||||
x20_enableAnaLeftXP = false;
|
||||
} else if ((float)fabs(x8_anaLeftX) < 0.7f) {
|
||||
x20_enableAnaLeftXP = false;
|
||||
sIsAnalogPressed[x4_controllerIdx][1] = false;
|
||||
}
|
||||
|
||||
if (x14_anaRightY > 0.7f && !sIsAnalogPressed[x4_controllerIdx][2]) {
|
||||
sIsAnalogPressed[x4_controllerIdx][2] = true;
|
||||
x23_enableAnaRightYP = true;
|
||||
} else if (x14_anaRightY > 0.7f && sIsAnalogPressed[x4_controllerIdx][2]) {
|
||||
x23_enableAnaRightYP = false;
|
||||
} else if (x14_anaRightY < -0.7f && !sIsAnalogPressed[x4_controllerIdx][2]) {
|
||||
x23_enableAnaRightYP = true;
|
||||
sIsAnalogPressed[x4_controllerIdx][2] = true;
|
||||
} else if (x14_anaRightY < -0.7f && sIsAnalogPressed[x4_controllerIdx][2]) {
|
||||
x23_enableAnaRightYP = false;
|
||||
} else if ((float)fabs(x14_anaRightY) < 0.7f) {
|
||||
x23_enableAnaRightYP = false;
|
||||
sIsAnalogPressed[x4_controllerIdx][2] = false;
|
||||
}
|
||||
|
||||
if (x10_anaRightX > 0.7f && !sIsAnalogPressed[x4_controllerIdx][3]) {
|
||||
x22_enableAnaRightXP = true;
|
||||
sIsAnalogPressed[x4_controllerIdx][3] = true;
|
||||
} else if (x10_anaRightX > 0.7f && sIsAnalogPressed[x4_controllerIdx][3]) {
|
||||
x22_enableAnaRightXP = false;
|
||||
} else if (x10_anaRightX < -0.7f && !sIsAnalogPressed[x4_controllerIdx][3]) {
|
||||
sIsAnalogPressed[x4_controllerIdx][3] = true;
|
||||
x22_enableAnaRightXP = true;
|
||||
} else if (x10_anaRightX < -0.7f && sIsAnalogPressed[x4_controllerIdx][3]) {
|
||||
x22_enableAnaRightXP = false;
|
||||
} else if ((float)fabs(x10_anaRightX) < 0.7f) {
|
||||
x22_enableAnaRightXP = false;
|
||||
sIsAnalogPressed[x4_controllerIdx][3] = false;
|
||||
}
|
||||
}
|
||||
|
||||
CFinalInput::CFinalInput(int channel, float dt, const COsContext& ctx)
|
||||
: x0_dt(dt)
|
||||
, x4_controllerIdx(channel)
|
||||
, x8_anaLeftX(0.f)
|
||||
, xc_anaLeftY(0.f)
|
||||
, x10_anaRightX(0.f)
|
||||
, x14_anaRightY(0.f)
|
||||
, x18_anaLeftTrigger(0.f)
|
||||
, x1c_anaRightTrigger(0.f)
|
||||
, x22_enableAnaRightXP(false)
|
||||
, x23_enableAnaRightYP(false)
|
||||
, x24_anaLeftTriggerP(0.f)
|
||||
, x28_anaRightTriggerP(0.f)
|
||||
, x2c_b24_A(ctx.GetOsKeyState(0x6d).IsPressed())
|
||||
, x2c_b25_B(ctx.GetOsKeyState(0x6e).IsPressed())
|
||||
, x2c_b26_X(ctx.GetOsKeyState(0x84).IsPressed())
|
||||
, x2c_b27_Y(ctx.GetOsKeyState(0x85).IsPressed())
|
||||
, x2c_b28_Z(ctx.GetOsKeyState(0x16).IsPressed())
|
||||
, x2c_b29_L(ctx.GetOsKeyState(0x78).IsPressed())
|
||||
, x2c_b30_R(ctx.GetOsKeyState(0x7e).IsPressed())
|
||||
, x2c_b31_DPUp(ctx.GetOsKeyState(0x1c).IsPressed())
|
||||
, x2d_b24_DPRight(ctx.GetOsKeyState(0x1d).IsPressed())
|
||||
, x2d_b25_DPDown(ctx.GetOsKeyState(0x1e).IsPressed())
|
||||
, x2d_b26_DPLeft(ctx.GetOsKeyState(0x1b).IsPressed())
|
||||
, x2d_b27_Start(ctx.GetOsKeyState(5).IsPressed())
|
||||
, x2d_b28_PA(ctx.GetOsKeyState(0x6d).JustPressed())
|
||||
, x2d_b29_PB(ctx.GetOsKeyState(0x6e).JustPressed())
|
||||
, x2d_b30_PX(ctx.GetOsKeyState(0x84).JustPressed())
|
||||
, x2d_b31_PY(ctx.GetOsKeyState(0x85).JustPressed())
|
||||
, x2e_b24_PZ(ctx.GetOsKeyState(0x16).JustPressed())
|
||||
, x2e_b25_PL(ctx.GetOsKeyState(0x78).JustPressed())
|
||||
, x2e_b26_PR(ctx.GetOsKeyState(0x7e).JustPressed())
|
||||
, x2e_b27_PDPUp(ctx.GetOsKeyState(0x1c).JustPressed())
|
||||
, x2e_b28_PDPRight(ctx.GetOsKeyState(0x1d).JustPressed())
|
||||
, x2e_b29_PDPDown(ctx.GetOsKeyState(0x1e).JustPressed())
|
||||
, x2e_b30_PDPLeft(ctx.GetOsKeyState(0x1b).JustPressed())
|
||||
, x2e_b31_PStart(ctx.GetOsKeyState(5).JustPressed()) {}
|
||||
|
||||
CFinalInput CFinalInput::ScaleAnalogueSticks(float leftDiv, float rightDiv) const {
|
||||
CFinalInput ret = *this;
|
||||
ret.x8_anaLeftX = CMath::Clamp(-1.f, x8_anaLeftX / leftDiv, 1.f);
|
||||
ret.xc_anaLeftY = CMath::Clamp(-1.f, xc_anaLeftY / leftDiv, 1.f);
|
||||
ret.x10_anaRightX = CMath::Clamp(-1.f, x10_anaRightX / rightDiv, 1.f);
|
||||
ret.x14_anaRightY = CMath::Clamp(-1.f, x14_anaRightY / rightDiv, 1.f);
|
||||
return ret;
|
||||
}
|
Loading…
Reference in New Issue