//
// GJBaseGameLayer::processAreaTransformGroupAction from 0x1001f4ce4 to 0x1001f515c (1144 bytes)
//
// 1 xrefs:
// > GJBaseGameLayer::processAreaEffects @ 0x1001f493c
//
// 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
//
// local variable allocation has failed, the output may be wrong!
void __fastcall GJBaseGameLayer::processAreaTransformGroupAction(
GJBaseGameLayer *a1,
cocos2d::CCArray *a2,
EnterEffectInstance *a3,
cocos2d::CCPoint a4,
int a5,
int a6,
int a7,
int a8,
int a9,
bool a10,
bool a11)
{
__int64 v11; // x20
__int64 v12; // x21
float v17; // s8
float v18; // s9
__int64 *v19; // x0
int m_areaScaledCount; // w8
cocos2d::ccArray *data; // x10
__int64 num; // x9
GameObject **arr; // x23
__int64 v24; // x22
int v31; // w26
GameObject *v32; // x27
_BOOL4 v33; // w28
float AreaObjectValue; // s0
float32x2_t v35; // d1
float32x2_t v36; // d3
float32x2_t v37; // d3
float32x2_t v38; // d2
EnterEffectObject *m_gameObject; // x8
_BOOL4 v40; // w9
std::__vector_base::pointer begin; // x10
int v42; // w12
int m_easeIndex; // w11
int m_outerSectionIndex; // w8
int m_middleSectionIndex; // w8
int m_easingOutType; // w1
float m_easingOutRate; // s1
int m_easingOutBuffer; // w2
__int64 v51; // x24
__int64 v52; // x21
intptr_t m_uniqueID; // x20
cocos2d::CCDictionary *v54; // x0
cocos2d::CCArray *v55; // x26
intptr_t v56; // x20
cocos2d::CCDictionary *v57; // x0
GameObject *v58; // x20
int v59; // w0
float32x2_t v60; // d0
float32x2_t v61; // d1
float32x4_t v62; // q2
int v63; // w10
int v64; // [xsp+8h] [xbp-E8h]
float32x2_t v65; // [xsp+10h] [xbp-E0h]
__int64 v67; // [xsp+30h] [xbp-C0h]
cocos2d::CCPoint *v68; // [xsp+38h] [xbp-B8h]
unsigned __int64 v69; // [xsp+40h] [xbp-B0h]
bool v70; // [xsp+4Fh] [xbp-A1h] BYREF
__int64 v71[2]; // [xsp+50h] [xbp-A0h] BYREF
char v72; // [xsp+104h] [xbp+14h]
bool v73; // [xsp+105h] [xbp+15h]
v11 = *(_QWORD *)&a9;
v12 = *(_QWORD *)&a8;
v68 = *(cocos2d::CCPoint **)&a5;
v17 = ((float (__fastcall *)(cocos2d::CCLayer *, __n128, __n128))a1->m_objectLayer->getScaleX)(
a1->m_objectLayer,
*(__n128 *)&a4.x,
*(__n128 *)&a4.y);
v18 = ((float (__fastcall *)(cocos2d::CCLayer *))a1->m_objectLayer->getScaleY)(a1->m_objectLayer);
v19 = (__int64 *)((__int64 (__fastcall *)(cocos2d::CCLayer *))a1->m_objectLayer->getPosition)(a1->m_objectLayer);
sub_1000229B8(v71, v19);
((void (__fastcall *)(cocos2d::CCLayer *, float))a1->m_objectLayer->setScale)(a1->m_objectLayer, 1.0);
((void (__fastcall *)(cocos2d::CCLayer *, __int64 *))a1->m_objectLayer->setPosition)(
a1->m_objectLayer,
&qword_10086C9A0);
m_areaScaledCount = a1->m_areaScaledCount + sub_10024A36C(a2);
a1->m_areaScaledCount = m_areaScaledCount;
if ( !a2 )
{
v63 = 0;
LODWORD(num) = 0;
goto LABEL_45;
}
data = a2->data;
num = data->num;
if ( !(_DWORD)num )
{
v63 = 0;
goto LABEL_45;
}
v67 = 0;
arr = (GameObject **)data->arr;
v69 = (unsigned __int64)&arr[num - 1];
v24 = a10;
__asm
{
FMOV V13.2S, #1.0
FMOV V14.2S, #-1.0
}
v31 = a6;
v64 = a7;
do
{
v32 = *arr;
if ( !*arr )
break;
if ( !v32->m_isActivated )
{
m_outerSectionIndex = v32->m_outerSectionIndex;
if ( m_outerSectionIndex > a7 || m_outerSectionIndex < v31 )
goto LABEL_41;
m_middleSectionIndex = v32->m_middleSectionIndex;
if ( m_middleSectionIndex > (int)v11 || m_middleSectionIndex < (int)v12 )
goto LABEL_41;
}
v33 = GJBaseGameLayer::resetAreaObjectValues(a1, *arr, 1);
v70 = 0;
AreaObjectValue = GJBaseGameLayer::getAreaObjectValue(a1, a3, v32, v68, &v70);
if ( AreaObjectValue < 1.0 )
{
v36.i32[0] = LODWORD(a3->m_scaleX);
v35.i32[0] = LODWORD(a3->m_scaleXVariance);
v35.i32[1] = LODWORD(a3->m_scaleYVariance);
v36.i32[1] = LODWORD(a3->m_scaleY);
v37 = vmla_f32(v36, *(float32x2_t *)&a1->m_varianceValues.__elems_[v32->m_varianceIndex + 12], v35);
if ( v37.f32[0] == 0.0 )
{
v38 = _D13;
if ( v37.f32[1] == 0.0 )
goto LABEL_31;
}
m_gameObject = a3->m_gameObject;
if ( m_gameObject->m_easeOutEnabled )
{
v40 = v70;
if ( AreaObjectValue <= 0.01 || AreaObjectValue >= 0.99 )
{
if ( !v70 )
goto LABEL_29;
}
else
{
begin = a3->m_easeIndices.__begin_;
v42 = begin[v24];
m_easeIndex = a3->m_easeIndex;
if ( v42 == m_easeIndex - 2 )
{
begin[v24] = m_easeIndex;
goto LABEL_29;
}
if ( v42 == m_easeIndex - 1 )
v40 = 1;
begin[v24] = m_easeIndex + v40;
if ( !v40 )
{
LABEL_29:
m_easingOutType = m_gameObject->m_easingOutType;
m_easingOutRate = m_gameObject->m_easingOutRate;
m_easingOutBuffer = m_gameObject->m_easingOutBuffer;
LABEL_30:
v38 = vmla_n_f32(
_D13,
vadd_f32(v37, _D14),
1.0
- GJBaseGameLayer::getEnterEasingValue(
a1,
AreaObjectValue,
m_easingOutType,
m_easingOutRate,
m_easingOutBuffer));
LABEL_31:
++HIDWORD(v67);
if ( v72 )
{
v65 = v38;
v51 = v12;
v52 = v11;
m_uniqueID = v32->m_uniqueID;
v54 = (cocos2d::CCDictionary *)sub_10024A388(
a1->m_targetGroupsArray,
(unsigned int)(a3->m_targetGroupIndex + 1));
v55 = (cocos2d::CCArray *)cocos2d::CCDictionary::objectForKey(v54, m_uniqueID);
v56 = v32->m_uniqueID;
v57 = (cocos2d::CCDictionary *)sub_10024A388(
a1->m_targetGroupsArray,
(unsigned int)(a3->m_targetGroupIndex + 2));
v58 = (GameObject *)cocos2d::CCDictionary::objectForKey(v57, v56);
v59 = sub_10024A36C(v55);
if ( a3->m_gameObject->m_dontEditAreaParent )
v32->m_unk508 = 1;
LODWORD(v67) = v67 + v59 - 1;
GJBaseGameLayer::transformAreaObjects(a1, v58, v55, v65.f32[0], v65.f32[1], v73);
v32->m_unk508 = 0;
v11 = v52;
v12 = v51;
a7 = v64;
v31 = a6;
}
else
{
v60 = *(float32x2_t *)&v32->m_scaleX;
v61 = vmul_f32(vadd_f32(v38, _D14), v60);
if ( v61.f32[0] != 0.0 || v61.f32[1] != 0.0 )
{
*(float32x2_t *)v62.f32 = v61;
*(float32x2_t *)&v62.u32[2] = v61;
*(float32x4_t *)&v32->m_scaleXOffset = vaddq_f32(v62, *(float32x4_t *)&v32->m_scaleXOffset);
*(float32x2_t *)&v32->m_scaleX = vadd_f32(v60, v61);
v32->m_isDirty = 1;
v32->m_isObjectRectDirty = 1;
if ( v73 )
((void (__fastcall *)(GameObject *, float))v32->setRScale)(v32, 1.0);
}
}
goto LABEL_39;
}
}
}
m_easingOutType = m_gameObject->m_easingInType;
m_easingOutRate = m_gameObject->m_easingInRate;
m_easingOutBuffer = m_gameObject->m_easingInBuffer;
goto LABEL_30;
}
LABEL_39:
if ( v33 )
((void (__fastcall *)(GJBaseGameLayer *, GameObject *))a1->updateObjectSection)(a1, v32);
LABEL_41:
++arr;
++v24;
}
while ( (unsigned __int64)arr <= v69 );
m_areaScaledCount = a1->m_areaScaledCount;
v63 = v67;
LODWORD(num) = HIDWORD(v67);
LABEL_45:
a1->m_areaScaledCount = m_areaScaledCount + v63;
a1->m_areaScaledCountTotal += num + v63;
((void (__fastcall *)(cocos2d::CCLayer *, float))a1->m_objectLayer->setScaleX)(a1->m_objectLayer, v17);
((void (__fastcall *)(cocos2d::CCLayer *, float))a1->m_objectLayer->setScaleY)(a1->m_objectLayer, v18);
((void (__fastcall *)(cocos2d::CCLayer *, __int64 *))a1->m_objectLayer->setPosition)(a1->m_objectLayer, v71);
}