//
// GJGroundLayer::scaleGround from 0x434c24 to 0x434c7a (86 bytes)
//
// 6 xrefs:
// > GJBaseGameLayer::updateCameraBGArt @ 0x4775b8
// > GJBaseGameLayer::updateCameraBGArt @ 0x4775c8
// > GJBaseGameLayer::preUpdateVisibility @ 0x4890ee
// > GJBaseGameLayer::preUpdateVisibility @ 0x489102
// > GJBaseGameLayer::resetLevelVariables @ 0x491e04
// > GJBaseGameLayer::resetLevelVariables @ 0x491e1a
//
// 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
//
float GJGroundLayer::scaleGround(GJGroundLayer *a1, float a2)
{
void (__fastcall *setScaleY)(cocos2d::CCNode *__hidden, float); // r6
float v5; // r1
float m_groundWidth; // s16
float v7; // s15
((void (__fastcall *)(GJGroundLayer *))a1->setScaleX)(a1);
setScaleY = a1->setScaleY;
if ( COERCE_FLOAT(((int (__fastcall *)(GJGroundLayer *))a1->getScaleY)(a1)) >= 0.0 )
v5 = a2;
else
LODWORD(v5) = LODWORD(a2) ^ 0x80000000;
((void (__fastcall *)(GJGroundLayer *, _DWORD))setScaleY)(a1, LODWORD(v5));
m_groundWidth = a1->m_groundWidth;
GJGroundLayer::updateGroundWidth(a1, 1);
v7 = a1->m_groundWidth;
GJGroundLayer::updateShadows(a1);
return v7 - m_groundWidth;
}