//
// GJBaseGameLayer::updateScreenRotation from 0x87d650 to 0x87d738 (232 bytes)
//
// 5 xrefs:
// > PlayLayer::updateScreenRotation @ 0x5cc040
// > ??> @ 0x9ed48
// > ??> @ 0x1148a88
// > ??> @ 0x11552f8
// > ??> @ 0x1190778
//
// 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
//
void GJBaseGameLayer::updateScreenRotation(
GJBaseGameLayer *a1,
float a2,
bool a3,
bool a4,
float a5,
int a6,
float a7,
int a8,
int a9)
{
float v10; // s8
float v12; // s3
float v13; // s0
int v14; // [xsp+38h] [xbp+38h]
int v16; // [xsp+50h] [xbp+50h]
int v17; // [xsp+58h] [xbp+58h]
v10 = a2;
v12 = a7;
if ( a3 )
a2 = a2 + a1->m_gameState.m_targetCameraAngle;
a1->m_gameState.m_targetCameraAngle = a2;
if ( a4 )
{
v14 = a9;
v16 = a8;
v17 = a6;
a1->m_gameState.m_cameraAngle = GJBaseGameLayer::convertToClosestDirection(a1->m_gameState.m_cameraAngle, 180.0);
v13 = GJBaseGameLayer::convertToClosestDirection(a1->m_gameState.m_targetCameraAngle, 180.0);
a9 = v14;
a1->m_gameState.m_targetCameraAngle = v13;
a8 = v16;
v12 = a7;
a6 = v17;
}
if ( a5 <= 0.0 )
{
GJGameState::stopTweenAction(&a1->m_gameState, 17);
a1->m_gameState.m_cameraAngle = v10;
}
else
{
GJGameState::tweenValue(
&a1->m_gameState,
a1->m_gameState.m_cameraAngle,
a1->m_gameState.m_targetCameraAngle,
17,
a5,
a6,
v12,
a8,
a9);
}
}