Skip to content

Instantly share code, notes, and snippets.

@Lusamine
Last active January 3, 2023 16:58
Show Gist options
  • Save Lusamine/3a3d9ee28d80d3db9c8295ca2dcc91f9 to your computer and use it in GitHub Desktop.
Save Lusamine/3a3d9ee28d80d3db9c8295ca2dcc91f9 to your computer and use it in GitHub Desktop.
__int64 __fastcall sub_71017B84D4(
__int64 a1,
__int64 a2,
__int64 (__fastcall ***a3)(_QWORD),
__int64 (__fastcall ***a4)(_QWORD),
unsigned int a5)
{
unsigned __int32 BallCaptureRatio; // w20
BallCaptureRatio = Dpr_Battle_Logic_Capture__getBallCaptureRatio(a1, a2, a3, a4, a5);
if ( sub_7101410B5C(a1) )
return BallCaptureRatio;
if ( Dpr_Battle_Logic_UltraBeast__IsUltraBeast((__int64)a4) )
return 410LL;
return BallCaptureRatio;
}
=====
.text:00000071017B84D4
.text:00000071017B84D4 ; =============== S U B R O U T I N E =======================================
.text:00000071017B84D4
.text:00000071017B84D4 ; Attributes: bp-based frame
.text:00000071017B84D4
.text:00000071017B84D4 ; __int64 __fastcall sub_71017B84D4(__int64, __int64, __int64 (__fastcall ***)(_QWORD), __int64 (__fastcall ***)(_QWORD), unsigned int)
.text:00000071017B84D4 sub_71017B84D4 ; CODE XREF: Dpr.Battle.Logic.Capture$$calcCaptureIndicator+118↑p
.text:00000071017B84D4
.text:00000071017B84D4 var_s0 = 0
.text:00000071017B84D4 var_s10 = 0x10
.text:00000071017B84D4 var_s20 = 0x20
.text:00000071017B84D4
.text:00000071017B84D4 STP X29, X30, [SP,#-0x30+var_s0]!
.text:00000071017B84D8 STP X22, X21, [SP,#var_s10]
.text:00000071017B84DC MOV X29, SP
.text:00000071017B84E0 STP X20, X19, [SP,#var_s20]
.text:00000071017B84E4 MOV W21, W4
.text:00000071017B84E8 MOV X19, X3
.text:00000071017B84EC MOV X22, X0
.text:00000071017B84F0 BL Dpr.Battle.Logic.Capture$$getBallCaptureRatio
.text:00000071017B84F4 MOV X1, #0x87B46F24
.text:00000071017B84FC MOV W20, W0
.text:00000071017B8500 MOVK X1, #0xFEBA,LSL#32
.text:00000071017B8504 MOVK X1, #0x5559,LSL#48
.text:00000071017B8508 MOV X0, X22
.text:00000071017B850C MOV W2, W21
.text:00000071017B8510 BL sub_7101410B5C
.text:00000071017B8514 TBNZ W0, #0, loc_71017B853C
.text:00000071017B8518 MOV X0, X19 ; __int64
.text:00000071017B851C BL Dpr.Battle.Logic.UltraBeast$$IsUltraBeast
.text:00000071017B8520 TST W0, #1
.text:00000071017B8524 MOV W8, #0x19A
.text:00000071017B8528 CSEL W0, W8, W20, NE
.text:00000071017B852C
.text:00000071017B852C loc_71017B852C ; CODE XREF: sub_71017B84D4+6C↓j
.text:00000071017B852C LDP X20, X19, [SP,#var_s20]
.text:00000071017B8530 LDP X22, X21, [SP,#var_s10]
.text:00000071017B8534 LDP X29, X30, [SP+var_s0],#0x30
.text:00000071017B8538 RET
.text:00000071017B853C ; ---------------------------------------------------------------------------
.text:00000071017B853C
.text:00000071017B853C loc_71017B853C ; CODE XREF: sub_71017B84D4+40↑j
.text:00000071017B853C MOV W0, W20
.text:00000071017B8540 B loc_71017B852C
.text:00000071017B8540 ; End of function sub_71017B84D4
.text:00000071017B8540
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment