//
// sub_1004B797C from 0x1004b797c to 0x1004b7a4c (208 bytes)
//
// 1 xrefs:
// > DeathMarkerSettingsPopup::init @ 0x1004b70d0
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:06:15 +0000
//
__int64 __fastcall sub_1004B797C(__int64 a1)
{
__int64 result; // x0
__int64 v3; // x20
__int64 v4; // x0
result = *(_QWORD *)(a1 + 1040);
if ( result )
{
if ( (int)llroundf(Slider::getValue(result) * 15.0) <= 14
&& (int)llroundf(Slider::getValue(*(_QWORD *)(a1 + 1040)) * 15.0) < 1 )
{
v3 = 50;
}
else if ( (int)llroundf(Slider::getValue(*(_QWORD *)(a1 + 1040)) * 15.0) > 14 )
{
v3 = 200;
}
else
{
v3 = 10 * llroundf(Slider::getValue(*(_QWORD *)(a1 + 1040)) * 15.0) + 50;
}
v4 = GameManager::sharedState();
GameManager::setIntGameVariable(v4, "0211", v3);
return sub_1004B7A4C(a1, v3);
}
return result;
}