//
// SetupSmartBlockLayer::onCreateAll from 0x674024 to 0x674118 (244 bytes)
//
// 0 xrefs:
//
// 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:55:54 +0000
//
unsigned int __fastcall SetupSmartBlockLayer::onCreateAll(SetupSmartBlockLayer *this, cocos2d::CCObject *a2)
{
GameLevelManager *v2; // r0
unsigned int result; // r0
int v4; // r7
cocos2d::CCDictionary *v5; // r9
unsigned int v6; // r4
cocos2d::CCString *v7; // r0
const char *CString; // r0
const char *v9; // r8
size_t v10; // r0
cocos2d::CCArray *v11; // r11
unsigned int i; // r8
cocos2d::CCArray *v13; // [sp+0h] [bp-34h]
int *v14; // [sp+4h] [bp-30h]
int v15; // [sp+8h] [bp-2Ch]
int v16[3]; // [sp+14h] [bp-20h] BYREF
int v17[3]; // [sp+20h] [bp-14h] BYREF
v2 = (GameLevelManager *)GameLevelManager::sharedState(this);
result = GameLevelManager::getActiveSmartTemplate(v2);
v4 = result;
if ( result )
{
v5 = *(cocos2d::CCDictionary **)(result + 52);
v6 = 0;
*(_DWORD *)(result + 124) = 0;
if ( v5 )
{
v13 = (cocos2d::CCArray *)cocos2d::CCDictionary::allKeys(v5);
while ( 1 )
{
result = cocos2d::CCArray::count(v13);
if ( v6 >= result )
break;
v7 = (cocos2d::CCString *)cocos2d::CCArray::stringAtIndex(v13, v6);
CString = (const char *)cocos2d::CCString::getCString(v7);
memset(v16, 0, sizeof(v16));
v9 = CString;
v10 = strlen(CString);
std::string::__init(v16, v9, v10);
v11 = (cocos2d::CCArray *)cocos2d::CCDictionary::objectForKey(v5, v16);
for ( i = 0; i < cocos2d::CCArray::count(v11); ++i )
{
v14 = (int *)cocos2d::CCArray::objectAtIndex(v11, i);
v15 = *(_DWORD *)(*(_DWORD *)(GameManager::sharedState((GameManager *)v14) + 408) + 11856);
std::string::basic_string(v17, (int)v16);
EditorUI::createPrefab(v15, v4, (unsigned __int8 *)v17, v14[19]);
std::string::~string((int)v17);
}
++v6;
std::string::~string((int)v16);
}
}
}
return result;
}