//
// SetupAnimSettingsPopup::init from 0x10009abd0 to 0x10009b348 (1912 bytes)
//
// 1 xrefs:
// > SetupAnimSettingsPopup::create @ 0x10009ab8b
//
// 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
//
bool __fastcall SetupAnimSettingsPopup::init(SetupAnimSettingsPopup *a1, EffectGameObject *a2, cocos2d::CCArray *a3)
{
bool result; // al
bool v4; // r12
_QWORD v5[2]; // [rsp+40h] [rbp-180h] BYREF
void *__p; // [rsp+50h] [rbp-170h]
char v7; // [rsp+58h] [rbp-168h] BYREF
char v8[15]; // [rsp+59h] [rbp-167h] BYREF
void *v9; // [rsp+68h] [rbp-158h]
char v10; // [rsp+70h] [rbp-150h] BYREF
char v11[15]; // [rsp+71h] [rbp-14Fh] BYREF
void *v12; // [rsp+80h] [rbp-140h]
_QWORD v13[2]; // [rsp+88h] [rbp-138h] BYREF
void *v14; // [rsp+98h] [rbp-128h]
char v15; // [rsp+A0h] [rbp-120h] BYREF
_BYTE v16[23]; // [rsp+A1h] [rbp-11Fh] BYREF
void *v17[3]; // [rsp+B8h] [rbp-108h] BYREF
float v18[2]; // [rsp+D0h] [rbp-F0h] BYREF
_BYTE v19[8]; // [rsp+D8h] [rbp-E8h] BYREF
char v20; // [rsp+E0h] [rbp-E0h] BYREF
_BYTE v21[23]; // [rsp+E1h] [rbp-DFh] BYREF
void *v22[3]; // [rsp+F8h] [rbp-C8h] BYREF
void *v23[3]; // [rsp+110h] [rbp-B0h] BYREF
char v24; // [rsp+128h] [rbp-98h] BYREF
_BYTE v25[23]; // [rsp+129h] [rbp-97h] BYREF
char v26; // [rsp+140h] [rbp-80h] BYREF
char v27[15]; // [rsp+141h] [rbp-7Fh] BYREF
void *v28; // [rsp+150h] [rbp-70h]
char v29; // [rsp+158h] [rbp-68h] BYREF
_BYTE v30[23]; // [rsp+159h] [rbp-67h] BYREF
char v31; // [rsp+170h] [rbp-50h] BYREF
_BYTE v32[23]; // [rsp+171h] [rbp-4Fh] BYREF
_BYTE v33[8]; // [rsp+188h] [rbp-38h] BYREF
_BYTE v34[8]; // [rsp+190h] [rbp-30h] BYREF
_BYTE v35[40]; // [rsp+198h] [rbp-28h] BYREF
result = SetupTriggerPopup::init(a1, a2, a3, 400.0, 240.0, 1);
if ( result )
{
v4 = result;
SetupTriggerPopup::preSetup(a1);
__p = operator new(0x1Au);
v5[0] = 27;
v5[1] = 23;
strcpy((char *)__p, "Edit Animation Settings");
SetupTriggerPopup::addTitle(a1, v5);
if ( (v5[0] & 1) != 0 )
operator delete(__p);
v7 = 4;
strcpy(v8, "OK");
SetupTriggerPopup::addCloseButton(a1, &v7);
if ( (v7 & 1) != 0 )
operator delete(v9);
v10 = 8;
strcpy(v11, "Help");
v14 = operator new(0x1C0u);
v13[0] = 449;
v13[1] = 446;
strcpy(
(char *)v14,
"Disable Anim Shine removes the white flash at the start of the animation for some animated objects.\n"
"Use Speed lets you set a custom animation speed.\n"
"Use Animate On Trigger to toggle on with Animate trigger.\n"
"Only If Active only does this if the object is active.\n"
"Single Frame lets you select a specific frame of the animation.\n"
"Offset Anim will offset the animation the value of single frame.");
SetupTriggerPopup::addHelpButton(a1, &v10, v13, 1.0);
if ( (v13[0] & 1) != 0 )
operator delete(v14);
if ( (v10 & 1) != 0 )
operator delete(v12);
cocos2d::CCDirector::sharedDirector();
cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)v18);
sub_10028CBE0(v19, v18[0] * 0.5, 0.5 * v18[1]);
sub_10028CBE0(v35, -40.0, 60.0);
sub_10028CCE0(v33, v19);
v20 = 30;
strcpy(v21, "Randomize\nStart");
sub_10028CBE0(v34, -125.0, 0.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 106, (unsigned int)&v20, (unsigned int)v35, 0, 0, 0);
if ( (v20 & 1) != 0 )
operator delete(*(void **)&v21[15]);
v15 = 18;
strcpy(v16, "Use\nSpeed");
sub_10028CBE0(v34, 0.0, 0.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 122, (unsigned int)&v15, (unsigned int)v35, 0, 0, 0);
if ( (v15 & 1) != 0 )
operator delete(*(void **)&v16[15]);
strcpy((char *)v22, "$Animate\non Trigger");
sub_10028CBE0(v34, 125.0, 0.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 123, (unsigned int)v22, (unsigned int)v35, 0, 0, 0);
if ( ((__int64)v22[0] & 1) != 0 )
operator delete(v22[2]);
strcpy((char *)v23, "(Disable\ndelayed\nloop");
sub_10028CBE0(v34, -125.0, -40.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 126, (unsigned int)v23, (unsigned int)v35, 0, 0, 0);
if ( ((__int64)v23[0] & 1) != 0 )
operator delete(v23[2]);
strcpy((char *)v17, "\"Disable\nAnimShine");
sub_10028CBE0(v34, 0.0, -40.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 127, (unsigned int)v17, (unsigned int)v35, 0, 0, 0);
if ( ((__int64)v17[0] & 1) != 0 )
operator delete(v17[2]);
v24 = 28;
strcpy(v25, "Only if\nactive");
sub_10028CBE0(v34, 125.0, -40.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 214, (unsigned int)&v24, (unsigned int)v35, 0, 0, 0);
if ( (v24 & 1) != 0 )
operator delete(*(void **)&v25[15]);
v26 = 12;
strcpy(v27, "Speed:");
sub_10028CBE0(v34, -100.0, -30.0);
sub_10028CCE0(v35, v19);
SetupTriggerPopup::createValueControlAdvanced(
(_DWORD)a1,
107,
(unsigned int)&v26,
(unsigned int)v35,
0,
1,
6,
0,
0,
0,
0,
2,
0);
if ( (v26 & 1) != 0 )
operator delete(v28);
v29 = 26;
strcpy(v30, "Single Frame:");
sub_10028CBE0(v34, 100.0, -45.0);
sub_10028CCE0(v35, v19);
SetupTriggerPopup::createValueControlAdvanced(
(_DWORD)a1,
462,
(unsigned int)&v29,
(unsigned int)v35,
1,
3,
3,
1,
0,
0,
0,
2,
0);
if ( (v29 & 1) != 0 )
operator delete(*(void **)&v30[15]);
v31 = 22;
strcpy(v32, "Offset\nAnim");
sub_10028CBE0(v34, 125.0, -155.0);
sub_10028CCE0(v35, v33);
SetupTriggerPopup::createToggleValueControl((_DWORD)a1, 592, (unsigned int)&v31, (unsigned int)v35, 0, 0, 0);
if ( (v31 & 1) != 0 )
operator delete(*(void **)&v32[15]);
SetupTriggerPopup::postSetup(a1);
return v4;
}
return result;
}