//
// SetupCheckpointPopup::init from 0xb7423c to 0xb7472c (1264 bytes)
//
// 2 xrefs:
// > SetupCheckpointPopup::create @ 0xb74960
// > ??> @ 0x70750
//
// 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:02:22 +0000
//
__int64 __fastcall SetupCheckpointPopup::init(
SetupCheckpointPopup *this,
CheckpointGameObject *a2,
cocos2d::CCArray *a3)
{
unsigned __int8 v4; // w0
unsigned int v5; // w24
__int64 v7; // x2
__int64 v8; // x3
__int64 v9; // x4
__int64 v10; // x5
const char *v11; // x6
cocos2d::CCDirector *MultiTriggerItemsDefault; // x0
cocos2d::CCDirector *v13; // x0
int v14; // [xsp+8h] [xbp-8h]
int v15; // [xsp+8h] [xbp-8h]
int v16; // [xsp+8h] [xbp-8h]
__int64 v17; // [xsp+88h] [xbp+78h] BYREF
_BYTE v18[8]; // [xsp+90h] [xbp+80h] BYREF
_BYTE v19[8]; // [xsp+98h] [xbp+88h] BYREF
__int64 v20; // [xsp+A0h] [xbp+90h] BYREF
__int64 v21[2]; // [xsp+A8h] [xbp+98h] BYREF
void *v22; // [xsp+B8h] [xbp+A8h]
__int64 v23; // [xsp+C0h] [xbp+B0h] BYREF
__int64 v24; // [xsp+C8h] [xbp+B8h]
void *v25; // [xsp+D0h] [xbp+C0h]
v4 = SetupTriggerPopup::init(this, a2, a3, 380.0, 280.0, 1u, 0.0);
v5 = v4;
if ( v4 )
{
SetupTriggerPopup::preSetup(this);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "Setup Checkpoint", 0x10u);
SetupTriggerPopup::addTitle((__int64)this, (__int64)&v23);
if ( (v23 & 1) != 0 )
operator delete(v25);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "OK", 2u);
SetupTriggerPopup::addCloseButton((__int64)this, (__int64)&v23, v7, v8, v9, v10, v11);
if ( (v23 & 1) != 0 )
operator delete(v25);
v21[0] = 0;
v21[1] = 0;
v22 = nullptr;
std::string::__init(v21, "Help", 4u);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(
&v23,
"Checkpoints used when the game type is Platformer.\n"
"PreSpawnID spawned before the checkpoint is saved.\n"
"SpawnID spawned after the checkpoint is saved.\n"
"RespawnID spawned after respawning at the checkpoint.\n"
"TargetPos lets you set a respawn location upon death after the checkpoint. Make sure this group contains o"
"ne object.\n"
"Player Pos respawns where the player was when the checkpoint was touched.",
0x1B9u);
SetupTriggerPopup::addHelpButton((__int64)this, (char *)v21, (char *)&v23, 1.0);
if ( (v23 & 1) != 0 )
operator delete(v25);
if ( (v21[0] & 1) != 0 )
operator delete(v22);
MultiTriggerItemsDefault = (cocos2d::CCDirector *)SetupTriggerPopup::createMultiTriggerItemsDefault(this);
v13 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(MultiTriggerItemsDefault);
cocos2d::CCDirector::getWinSize(&v17, v13);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v18, *(float *)&v17 * 0.5, *((float *)&v17 + 1) * 0.5);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "PreSpawnID:", 0xBu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v19, -80.0, 60.0);
cocos2d::CCPoint::operator+(&v20, v18);
IDNameInput::create(this, (char *)this + 544, 1, 604, &v23, &v20, 6, 0, 0.8, 0, 0);
if ( (v23 & 1) != 0 )
operator delete(v25);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "SpawnID:", 8u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v19, 80.0, 60.0);
cocos2d::CCPoint::operator+(&v20, v18);
LOBYTE(v14) = 0;
IDNameInput::create(this, (char *)this + 544, 1, 51, &v23, &v20, 6, 0, 0.8, 0, v14);
if ( (v23 & 1) != 0 )
operator delete(v25);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "RespawnID:", 0xAu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v19, -80.0, -5.0);
cocos2d::CCPoint::operator+(&v20, v18);
LOBYTE(v15) = 0;
IDNameInput::create(this, (char *)this + 544, 1, 448, &v23, &v20, 6, 0, 0.8, 0, v15);
if ( (v23 & 1) != 0 )
operator delete(v25);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "TargetPos:", 0xAu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v19, 80.0, -5.0);
cocos2d::CCPoint::operator+(&v20, v18);
LOBYTE(v16) = 0;
IDNameInput::create(this, (char *)this + 544, 1, 71, &v23, &v20, 6, 0, 0.8, 0, v16);
if ( (v23 & 1) != 0 )
operator delete(v25);
v23 = 0;
v24 = 0;
v25 = nullptr;
std::string::__init(&v23, "Player Pos", 0xAu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v19, 80.0, -60.0);
cocos2d::CCPoint::operator+(&v20, v18);
SetupTriggerPopup::createToggleValueControl(
(__int64)this,
0x8Au,
&v23,
(const cocos2d::CCPoint *)&v20,
1,
0,
0,
1.0);
if ( (v23 & 1) != 0 )
operator delete(v25);
SetupTriggerPopup::postSetup(this);
}
return v5;
}