//
// UIObjectSettingsPopup::init from 0x6b4bc0 to 0x6b5260 (1696 bytes)
//
// 1 xrefs:
// > UIObjectSettingsPopup::create @ 0x6b530e
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:56:42 +0000
//
GameManager *__fastcall UIObjectSettingsPopup::init(
UIObjectSettingsPopup *this,
UISettingsGameObject *a2,
cocos2d::CCArray *a3)
{
GameManager *v4; // r11
cocos2d::CCDirector *v5; // r0
unsigned int v6; // r10
float v7; // r0
int v8; // r9
_BOOL4 v9; // r10
float v11; // [sp+2Ch] [bp-48h] BYREF
float v12; // [sp+30h] [bp-44h]
_BYTE v13[8]; // [sp+34h] [bp-40h] BYREF
_BYTE v14[4]; // [sp+3Ch] [bp-38h] BYREF
float v15; // [sp+40h] [bp-34h]
_BYTE v16[8]; // [sp+44h] [bp-30h] BYREF
_BYTE v17[8]; // [sp+4Ch] [bp-28h] BYREF
int v18[3]; // [sp+54h] [bp-20h] BYREF
int v19; // [sp+60h] [bp-14h] BYREF
int v20; // [sp+64h] [bp-10h]
int v21; // [sp+68h] [bp-Ch]
v4 = SetupTriggerPopup::init(this, a2, a3, 380.0, 280.0, (_BYTE *)&dword_0 + 1, 0.0);
if ( v4 )
{
SetupTriggerPopup::preSetup(this);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "UI Object Settings", 0x12u);
SetupTriggerPopup::addTitle((int)this, (unsigned __int8 *)&v19);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "OK", 2u);
SetupTriggerPopup::addCloseButton((int)this, (int)&v19);
std::string::~string((int)&v19);
memset(v18, 0, sizeof(v18));
std::string::__init(v18, "Help", 4u);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(
&v19,
"Group ID specify the objects to use for the UI. This is permanent from the start and cannot be edited.\n"
"UI Target is a single object used as a reference for the camera center. Camera Guide is a recommended tool"
".\n"
"XRef and YRef are reference points for aligning the object.\n"
"Relative makes UI positions scale with aspect ratio.",
0x163u);
SetupTriggerPopup::addHelpButton((int)this, (int)v18, (int)&v19, 1065353216);
std::string::~string((int)&v19);
v5 = (cocos2d::CCDirector *)std::string::~string((int)v18);
cocos2d::CCDirector::sharedDirector(v5);
cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v11);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v13, v11 * 0.5, v12 * 0.5);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Group ID:", 9u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -80.0, 60.0);
cocos2d::CCPoint::operator+(v17, v13, v16);
IDNameInput::create((int)this, (int)this + 440, 1, 51, (int)&v19, (int)v17, 0.8, 6, 0, 0, 0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "UI Target:", 0xAu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 80.0, 60.0);
cocos2d::CCPoint::operator+(v17, v13, v16);
IDNameInput::create((int)this, (int)this + 440, 1, 71, (int)&v19, (int)v17, 0.8, 6, 0, 0, 0);
std::string::~string((int)&v19);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v14, (float)(v11 * 0.5) - 25.0, (float)(v12 * 0.5) - 10.0);
v6 = (int)COERCE_FLOAT((*(int (__fastcall **)(UIObjectSettingsPopup *, int))(*(_DWORD *)this + 732))(this, 385));
v7 = (*(float (__fastcall **)(UIObjectSettingsPopup *, int))(*(_DWORD *)this + 732))(this, 386);
v19 = 0;
v20 = 0;
v21 = 0;
v8 = (int)v7;
std::string::__init(&v19, "XRef:", 5u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -125.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::addInfoLabel((int)this, (int)&v19, COERCE_CONST_CHAR_(0.5), (int)v17, 0, 0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Auto", 4u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -75.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
1,
v6 <= 1,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Center", 6u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -25.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
2,
v6 == 2,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Left", 4u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 25.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
3,
v6 == 3,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Right", 5u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 75.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
4,
v6 == 4,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Relative", 8u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 150.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createToggleValueControl((int)this, 387, (int)&v19, (const cocos2d::CCPoint *)v17, 1, 0, 0, 1.0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
v15 = v15 - 60.0;
std::string::__init(&v19, "YRef:", 5u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -125.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::addInfoLabel((int)this, (int)&v19, (const char *)0x3F000000, (int)v17, 0, 0);
std::string::~string((int)&v19);
if ( v8 == 5 )
v9 = (_BOOL4)v4;
else
v9 = v8 == 0;
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Auto", 4u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -75.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
5,
v9,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Center", 6u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, -25.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
6,
v8 == 6,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Bottom", 6u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 25.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
7,
v8 == 7,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Top", 3u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 75.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createCustomToggleValueControl(
(int)this,
8,
v8 == 8,
1,
(int)&v19,
(const cocos2d::CCPoint *)v17,
1,
0,
0);
std::string::~string((int)&v19);
v19 = 0;
v20 = 0;
v21 = 0;
std::string::__init(&v19, "Relative", 8u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 150.0, 0.0);
cocos2d::CCPoint::operator+(v17, v14, v16);
SetupTriggerPopup::createToggleValueControl((int)this, 388, (int)&v19, (const cocos2d::CCPoint *)v17, 1, 0, 0, 1.0);
std::string::~string((int)&v19);
SetupTriggerPopup::postSetup(this);
}
return v4;
}