//
// SetupShaderEffectPopup::init from 0xb3aa00 to 0xb3aca8 (680 bytes)
//
// 2 xrefs:
// > SetupShaderEffectPopup::create @ 0xb3aee8
// > ??> @ 0x59230
//
// 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 13:01:48 +0000
//
__int64 __fastcall SetupShaderEffectPopup::init(
SetupShaderEffectPopup *this,
EffectGameObject *a2,
cocos2d::CCArray *a3,
int a4)
{
unsigned __int8 v6; // w0
unsigned int v7; // w21
__int64 v9; // x2
__int64 v10; // x3
__int64 v11; // x4
__int64 v12; // x5
const char *v13; // x6
__int64 v14; // x0
cocos2d::CCDirector *v15; // x0
__int64 v16; // [xsp+40h] [xbp+40h] BYREF
_BYTE v17[8]; // [xsp+48h] [xbp+48h] BYREF
__int64 v18; // [xsp+50h] [xbp+50h] BYREF
__int64 v19; // [xsp+58h] [xbp+58h]
void *v20; // [xsp+60h] [xbp+60h]
v6 = SetupTriggerPopup::init(this, a2, a3, 430.0, 285.0, 1u, 0.0);
v7 = v6;
if ( v6 )
{
SetupTriggerPopup::preSetup(this);
v18 = 0;
v19 = 0;
v20 = nullptr;
std::string::__init(&v18, "OK", 2u);
SetupTriggerPopup::addCloseButton((__int64)this, (__int64)&v18, v9, v10, v11, v12, v13);
if ( (v18 & 1) != 0 )
operator delete(v20);
SetupTriggerPopup::createMultiTriggerItemsDefaultHorizontal(this);
*((_DWORD *)this + 259) = a4;
v14 = (unsigned int)(a4 - 2904);
*((_BYTE *)this + 904) = 1;
switch ( a4 )
{
case 2904:
SetupShaderEffectPopup::setupShaderTrigger(this);
goto LABEL_7;
case 2905:
v14 = SetupShaderEffectPopup::setupShockWave((cocos2d::CCArray **)this);
goto LABEL_10;
case 2907:
v14 = SetupShaderEffectPopup::setupShockLine((cocos2d::CCArray **)this);
goto LABEL_10;
case 2909:
v14 = SetupShaderEffectPopup::setupGlitch((cocos2d::CCArray **)this);
goto LABEL_10;
case 2910:
v14 = SetupShaderEffectPopup::setupChromatic((cocos2d::CCArray **)this);
goto LABEL_10;
case 2911:
v14 = SetupShaderEffectPopup::setupChromaticGlitch((cocos2d::CCArray **)this);
goto LABEL_10;
case 2912:
v14 = SetupShaderEffectPopup::setupPixelate((cocos2d::CCArray **)this);
goto LABEL_10;
case 2913:
v14 = SetupShaderEffectPopup::setupLensCircle((cocos2d::CCArray **)this);
goto LABEL_10;
case 2914:
v14 = SetupShaderEffectPopup::setupRadialBlur((cocos2d::CCArray **)this);
goto LABEL_10;
case 2915:
v14 = SetupShaderEffectPopup::setupMotionBlur((cocos2d::CCArray **)this);
goto LABEL_10;
case 2916:
v14 = SetupShaderEffectPopup::setupBulge((cocos2d::CCArray **)this);
goto LABEL_10;
case 2917:
v14 = SetupShaderEffectPopup::setupPinch((cocos2d::CCArray **)this);
goto LABEL_10;
case 2919:
v14 = SetupShaderEffectPopup::setupGrayscale((cocos2d::CCArray **)this);
goto LABEL_10;
case 2920:
v14 = SetupShaderEffectPopup::setupSepia((cocos2d::CCArray **)this);
goto LABEL_10;
case 2921:
v14 = SetupShaderEffectPopup::setupInvertColor((cocos2d::CCArray **)this);
goto LABEL_10;
case 2922:
v14 = SetupShaderEffectPopup::setupHueShift((cocos2d::CCArray **)this);
goto LABEL_10;
case 2923:
v14 = SetupShaderEffectPopup::setupColorChange((cocos2d::CCArray **)this);
goto LABEL_10;
case 2924:
v14 = SetupShaderEffectPopup::setupSplitScreen((cocos2d::CCArray **)this);
goto LABEL_10;
default:
if ( a4 == 2904 )
goto LABEL_7;
LABEL_10:
v15 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector((cocos2d::CCDirector *)v14);
cocos2d::CCDirector::getWinSize(&v16, v15);
v18 = 0;
v19 = 0;
v20 = nullptr;
std::string::__init(&v18, &byte_11E1A70, 1u);
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)v17,
(float)((float)(*((float *)this + 183) * 0.5) + (float)(*(float *)&v16 * 0.5)) - 15.0,
(float)((float)(*((float *)this + 184) * 0.5) + (float)(*((float *)&v16 + 1) * 0.5)) - 15.0);
SetupTriggerPopup::createToggleValueControl(
(__int64)this,
0x213u,
&v18,
(const cocos2d::CCPoint *)v17,
0,
0,
0,
0.6);
if ( (v18 & 1) != 0 )
operator delete(v20);
LABEL_7:
SetupTriggerPopup::postSetup(this);
break;
}
}
return v7;
}