//
// ParentalOptionsLayer::nextPosition from 0x1000f334c to 0x1000f343c (240 bytes)
//
// 1 xrefs:
// > ParentalOptionsLayer::addToggle @ 0x1000f2dac
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
cocos2d::CCPoint __fastcall ParentalOptionsLayer::nextPosition(ParentalOptionsLayer *a1, int a2)
{
__int64 v2; // x8
__int64 v5; // x19
cocos2d::CCDirector *v6; // x0
__n128 v7; // q0
__n128 v8; // q1
__n128 v9; // q0
__n128 v10; // q1
signed int v11; // w20
__int64 *v12; // x1
int v15; // [xsp+8h] [xbp-58h] BYREF
_DWORD v16[2]; // [xsp+10h] [xbp-50h] BYREF
float v17; // [xsp+18h] [xbp-48h]
float v18; // [xsp+1Ch] [xbp-44h]
cocos2d::CCPoint result; // 0:s0.4,4:s1.4
v5 = v2;
v6 = cocos2d::CCDirector::sharedDirector();
cocos2d::CCDirector::getWinSize(v6);
v7.n128_f32[0] = (float)(v17 * 0.5) + -135.0;
v8.n128_f32[0] = (float)(v18 * 0.5) + 60.0;
sub_100022980(v7, v8, v16);
v9.n128_f32[0] = (float)(v17 * 0.5) + 35.0;
v10.n128_u32[0] = v16[1];
sub_100022980(v9, v10, &v15);
v11 = ParentalOptionsLayer::countForPage(a1, a2);
if ( (v11 & 1) != 0 )
v12 = (__int64 *)&v15;
else
v12 = (__int64 *)v16;
result.x = sub_1000229B8((__int64 *)v5, v12);
if ( v11 >= 2 )
{
result.y = *(float *)(v5 + 4);
result.x = result.y - (float)(int)(48 * vcvtms_s32_f32(vcvts_n_f32_u32(v11, 1u)));
*(float *)(v5 + 4) = result.x;
}
return result;
}