//
// SetGroupIDLayer::init from 0x100312540 to 0x10031452d (8173 bytes)
//
// 1 xrefs:
// > SetGroupIDLayer::create @ 0x1003124f7
//
// 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 SetGroupIDLayer::init(SetGroupIDLayer *a1, GameObject *a2, cocos2d::CCArray *a3)
{
SetGroupIDLayer *v4; // r14
cocos2d::CCObject *v5; // rax
cocos2d::CCDictionary *v6; // rax
cocos2d::CCLayer *v7; // rax
cocos2d::CCObject *v8; // rax
cocos2d::extension::CCScale9Sprite *v9; // rbx
cocos2d::extension::CCScale9Sprite *v10; // rbx
cocos2d::CCLabelBMFont *v11; // r12
cocos2d::CCLabelBMFont *v12; // r15
cocos2d::CCLabelBMFont *v13; // r13
SetGroupIDLayer *v14; // rbx
__int64 v15; // rax
cocos2d::CCLabelBMFont *v16; // r12
unsigned __int64 *v17; // r15
cocos2d::CCLabelBMFont_vtbl *v18; // rax
cocos2d::CCLabelBMFont *v19; // r12
unsigned __int64 *v20; // rbx
cocos2d::CCLabelBMFont_vtbl *v21; // rax
cocos2d::CCMenu *v22; // rax
ButtonSprite *v23; // rax
CCMenuItemSpriteExtra *v24; // rax
cocos2d::CCMenu *m_buttonMenu; // rbx
cocos2d::CCSprite *v26; // rbx
CCMenuItemSpriteExtra *v27; // r15
const cocos2d::CCPoint *v28; // rbx
cocos2d::CCSprite *v29; // rbx
CCMenuItemSpriteExtra *v30; // r15
const cocos2d::CCPoint *v31; // rbx
cocos2d::CCSprite *v32; // rbx
CCMenuItemSpriteExtra *v33; // r15
const cocos2d::CCPoint *v34; // rbx
_DWORD *v35; // r13
const cocos2d::CCPoint *v36; // rbx
unsigned __int64 *v37; // rbx
unsigned __int64 *v38; // rbx
__int64 v39; // rax
unsigned __int64 *v40; // rbx
SetGroupIDLayer *v41; // r15
const char *v42; // rsi
__int64 v43; // r14
SetGroupIDLayer *v44; // r14
ButtonSprite *v45; // rax
CCMenuItemSpriteExtra *v46; // r12
const cocos2d::CCPoint *v47; // r13
__int64 v48; // rax
int v49; // xmm0_4
ButtonSprite *v50; // rax
CCMenuItemSpriteExtra *v51; // rbx
const cocos2d::CCPoint *v52; // r15
__int64 v53; // rax
ButtonSprite *v54; // rax
CCMenuItemSpriteExtra *v55; // r15
unsigned __int64 *v56; // rbx
unsigned __int64 *v57; // rbx
void *v58; // rdi
cocos2d::CCNode *v59; // r15
int *v60; // rbx
int v61; // r13d
SetGroupIDLayer *v62; // r12
ButtonSprite *v63; // r14
CCMenuItemSpriteExtra *v64; // r15
unsigned int v65; // ebx
ButtonSprite_vtbl *v66; // rax
ButtonSprite *v67; // rdi
SetGroupIDLayer *v68; // r14
int v69; // eax
const char *v70; // rdi
const cocos2d::CCPoint *v71; // rbx
unsigned __int64 *v72; // r12
__int64 v73; // xmm0_8
cocos2d::CCArray *m_targetObjects; // rdi
cocos2d::CCSprite *v75; // r15
const char *v76; // rbx
const char *v77; // rdi
cocos2d::CCLabelBMFont *v78; // r12
CCMenuItemSpriteExtra *v79; // r15
const cocos2d::CCPoint *v80; // r12
unsigned __int64 *v81; // r13
cocos2d::CCSprite *v82; // r15
cocos2d::CCLabelBMFont *v83; // rbx
CCMenuItemSpriteExtra *v84; // rbx
const cocos2d::CCPoint *v85; // r15
unsigned __int64 *v86; // r12
GameObject *m_targetObject; // rdi
int ParentMode; // ebx
cocos2d::CCString *v89; // rax
const char *CString; // rbx
cocos2d::CCArray *v91; // rdi
unsigned int v92; // r15d
GameObject *v93; // rax
int v94; // eax
size_t v95; // rax
size_t v96; // r15
char *v97; // r12
const char *v98; // rdi
size_t v99; // r14
cocos2d::CCLabelBMFont *v100; // rbx
unsigned __int64 *v101; // r15
cocos2d::CCSprite *v102; // rbx
CCMenuItemSpriteExtra *v103; // rbx
unsigned int v104; // ebx
ButtonSprite *v105; // r15
ZLayer m_zLayerValue; // r12d
const char *v107; // rsi
SetGroupIDLayer *v108; // r14
const cocos2d::CCPoint *v109; // rbx
ButtonSprite *v110; // rbx
ButtonSprite *v111; // r13
ButtonSprite *v112; // r12
ButtonSprite *v113; // r15
CCMenuItemSpriteExtra *v114; // rbx
CCMenuItemSpriteExtra *v115; // r13
CCMenuItemSpriteExtra *v116; // r12
CCMenuItemSpriteExtra *v117; // r15
GameManager *v118; // rax
double v119; // xmm0_8
GameObject *v120; // rbx
SetGroupIDLayer *v121; // rax
unsigned __int8 m_pobTexture; // r14
cocos2d::CCMenu *v123; // rbx
EffectGameObject *m_playbackObject; // r14
cocos2d::CCMenu *v125; // rbx
EffectGameObject *m_traceOutObject; // r14
cocos2d::CCMenu *v127; // rbx
EffectGameObject *m_traceInObject; // r14
cocos2d::CCMenu *v129; // rbx
char v131; // [rsp+0h] [rbp-220h]
char v132; // [rsp+40h] [rbp-1E0h] BYREF
char __dst[15]; // [rsp+41h] [rbp-1DFh] BYREF
void *v134; // [rsp+50h] [rbp-1D0h]
__int16 v135; // [rsp+58h] [rbp-1C8h] BYREF
char v136; // [rsp+5Ah] [rbp-1C6h]
void *v137; // [rsp+68h] [rbp-1B8h]
char v138; // [rsp+70h] [rbp-1B0h] BYREF
int v139; // [rsp+71h] [rbp-1AFh]
void *v140; // [rsp+80h] [rbp-1A0h]
char v141; // [rsp+88h] [rbp-198h] BYREF
char v142[15]; // [rsp+89h] [rbp-197h] BYREF
void *v143; // [rsp+98h] [rbp-188h]
_QWORD v144[2]; // [rsp+A0h] [rbp-180h] BYREF
void *__p; // [rsp+B0h] [rbp-170h]
char v146; // [rsp+B8h] [rbp-168h] BYREF
char v147[15]; // [rsp+B9h] [rbp-167h] BYREF
void *v148; // [rsp+C8h] [rbp-158h]
char v149; // [rsp+D0h] [rbp-150h] BYREF
char v150[15]; // [rsp+D1h] [rbp-14Fh] BYREF
void *v151; // [rsp+E0h] [rbp-140h]
char v152; // [rsp+E8h] [rbp-138h] BYREF
char v153[15]; // [rsp+E9h] [rbp-137h] BYREF
void *v154; // [rsp+F8h] [rbp-128h]
char v155; // [rsp+100h] [rbp-120h] BYREF
_BYTE v156[23]; // [rsp+101h] [rbp-11Fh] BYREF
char v157; // [rsp+118h] [rbp-108h] BYREF
_BYTE v158[23]; // [rsp+119h] [rbp-107h] BYREF
char v159; // [rsp+130h] [rbp-F0h] BYREF
_BYTE v160[23]; // [rsp+131h] [rbp-EFh] BYREF
char v161; // [rsp+148h] [rbp-D8h] BYREF
char v162[15]; // [rsp+149h] [rbp-D7h] BYREF
void *v163; // [rsp+158h] [rbp-C8h]
cocos2d::CCArray *v164; // [rsp+160h] [rbp-C0h]
__int64 v165; // [rsp+168h] [rbp-B8h] BYREF
int *v166; // [rsp+170h] [rbp-B0h]
cocos2d::CCLabelBMFont *v167; // [rsp+178h] [rbp-A8h]
cocos2d::CCLabelBMFont *v168; // [rsp+180h] [rbp-A0h]
GameObject *v169; // [rsp+188h] [rbp-98h]
unsigned __int64 v170; // [rsp+194h] [rbp-8Ch] BYREF
unsigned __int64 v171; // [rsp+19Ch] [rbp-84h] BYREF
unsigned __int64 v172; // [rsp+1A4h] [rbp-7Ch] BYREF
bool v173; // [rsp+1AFh] [rbp-71h]
unsigned __int64 v174[2]; // [rsp+1B0h] [rbp-70h] BYREF
void *v175; // [rsp+1C0h] [rbp-60h]
cocos2d::CCNode *v176; // [rsp+1C8h] [rbp-58h]
SetGroupIDLayer *v177; // [rsp+1D0h] [rbp-50h]
float v178; // [rsp+1D8h] [rbp-48h] BYREF
float v179; // [rsp+1DCh] [rbp-44h]
unsigned __int64 v180; // [rsp+1E0h] [rbp-40h] BYREF
unsigned __int64 v181; // [rsp+1E8h] [rbp-38h] BYREF
unsigned __int64 v182[6]; // [rsp+1F0h] [rbp-30h] BYREF
double v183; // 0:xmm0_8.8
double v184; // 0:xmm0_8.8
double v185; // 0:xmm0_8.8
double v186; // 0:xmm0_8.8
double v187; // 0:xmm0_8.8
double v188; // 0:xmm0_8.8
cocos2d::CCRect v189; // 0:xmm0_8.8,8:xmm1_8.8
v4 = a1;
LODWORD(v174[0]) = 1258291200;
v173 = cocos2d::CCLayerColor::initWithColor(a1, (const cocos2d::ccColor4B *)v174);
if ( !v173 )
return v173;
a1->m_editorLayerEdited = 1;
a1->m_noElasticity = 1;
v169 = a2;
if ( a2 )
{
a1->m_targetObject = a2;
}
else
{
a1->m_targetObjects = a3;
a1 = (SetGroupIDLayer *)a3;
cocos2d::CCObject::retain(a3);
}
v5 = (cocos2d::CCObject *)sub_10071F9E0(a1, v174);
v4->m_zLayerButtons = (cocos2d::CCArray *)v5;
cocos2d::CCObject::retain(v5);
v6 = cocos2d::CCDictionary::create();
v4->m_parentGroups = v6;
cocos2d::CCObject::retain(v6);
FLAlertLayer::incrementForcePrio(v4);
((void (__fastcall *)(SetGroupIDLayer *, __int64))v4->setTouchEnabled)(v4, 1);
((void (__fastcall *)(SetGroupIDLayer *, __int64))v4->setKeypadEnabled)(v4, 1);
cocos2d::CCDirector::sharedDirector();
*(cocos2d::CCSize *)&v183 = cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v178);
v7 = cocos2d::CCLayer::create();
v4->m_mainLayer = v7;
((void (__fastcall *)(SetGroupIDLayer *, cocos2d::CCLayer *, double))v4->addChild)(v4, v7, v183);
((void (__fastcall *)(SetGroupIDLayer *, __int64))v4->setOpacity)(v4, 200);
v8 = (cocos2d::CCObject *)sub_10071F9E0(v4, 200);
v4->m_groupIDObjects = (cocos2d::CCArray *)v8;
cocos2d::CCObject::retain(v8);
v4->m_groupIDValue = GameManager::sharedState()->m_currentGroupID;
v189.origin = 0;
v189.size = 0;
sub_10028CC00((__int64)v174, 0.0, 0.0, (__m128)0x42A00000u, (__m128)0x42A00000u);
v9 = cocos2d::extension::CCScale9Sprite::create_2("GJ_square01.png", v189);
sub_10028CBF0((float *)v174, 390.0, 310.0);
((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, unsigned __int64 *))v9->setContentSize)(v9, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::extension::CCScale9Sprite *, __int64))v4->m_mainLayer->addChild_0)(
v4->m_mainLayer,
v9,
4294967294LL);
sub_10028CBE0((float *)v174, v178 * 0.5, v179 * 0.5);
((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, unsigned __int64 *))v9->setPosition)(v9, v174);
v189.origin = 0;
v189.size = 0;
sub_10028CC00((__int64)v174, 0.0, 0.0, (__m128)0x42A00000u, (__m128)0x42A00000u);
v10 = cocos2d::extension::CCScale9Sprite::create_2("square02_001.png", v189);
((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, __int64))v10->setOpacity)(v10, 50);
sub_10028CBF0((float *)v174, 360.0, 68.0);
((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, unsigned __int64 *))v10->setContentSize)(v10, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::extension::CCScale9Sprite *, __int64))v4->m_mainLayer->addChild_0)(
v4->m_mainLayer,
v10,
0xFFFFFFFFLL);
sub_10028CBE0((float *)v174, v178 * 0.5, (float)(v179 * 0.5) + -17.0);
((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, unsigned __int64 *))v10->setPosition)(v10, v174);
v11 = cocos2d::CCLabelBMFont::create_3("Editor L", "goldFont.fnt");
sub_10028CBE0((float *)v174, (float)(v178 * 0.5) + -125.0, (float)((float)(v179 * 0.5) + 155.0) + -17.0);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v11->setPosition)(v11, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v4->m_mainLayer->addChild)(v4->m_mainLayer, v11);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v11->setScale)(v11, 0.64999998);
v12 = cocos2d::CCLabelBMFont::create_3("Editor L2", "goldFont.fnt");
sub_10028CBE0((float *)v174, v178 * 0.5, (float)((float)(v179 * 0.5) + 155.0) + -17.0);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v12->setPosition)(v12, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v4->m_mainLayer->addChild)(v4->m_mainLayer, v12);
v176 = v12;
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v12->setScale)(v12, 0.64999998);
v13 = cocos2d::CCLabelBMFont::create_3("Add Group ID", "goldFont.fnt");
*(float *)&v168 = v178 * 0.5;
v14 = (SetGroupIDLayer *)v11;
v15 = ((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v11->getPosition)(v11);
sub_10028CBE0((float *)v174, *(float *)&v168, *(float *)(v15 + 4) + -65.0);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v13->setPosition)(v13, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v4->m_mainLayer->addChild)(v4->m_mainLayer, v13);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v13->setScale)(v13, 0.64999998);
v16 = cocos2d::CCLabelBMFont::create_3("Z Order", "goldFont.fnt");
v177 = v14;
v17 = (unsigned __int64 *)((__int64 (__fastcall *)(SetGroupIDLayer *))v14->getPosition)(v14);
sub_10028CBE0((float *)&v170, 250.0, 0.0);
sub_10028CCE0((double *)v174, v17, &v170);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v16->setPosition)(v16, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v4->m_mainLayer->addChild)(v4->m_mainLayer, v16);
v18 = v16->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v168 = v16;
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v18->setScale)(v16, 0.64999998);
v19 = cocos2d::CCLabelBMFont::create_3("Z Layer", "goldFont.fnt");
v166 = (int *)v13;
v20 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v13->getPosition)(v13);
sub_10028CBE0((float *)&v170, 0.0, -137.0);
sub_10028CCE0((double *)v174, v20, &v170);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v19->setPosition)(v19, v174);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v4->m_mainLayer->addChild)(v4->m_mainLayer, v19);
v21 = v19->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v167 = v19;
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v21->setScale)(v19, 0.64999998);
v22 = cocos2d::CCMenu::create();
v4->m_buttonMenu = v22;
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCMenu *, __int64))v4->m_mainLayer->addChild_0)(
v4->m_mainLayer,
v22,
10);
v4->m_joystickConnected = -1;
v23 = ButtonSprite::create_1("OK", 40, 0, 0.80000001, 1, "goldFont.fnt", "GJ_button_01.png", 30.0);
v24 = CCMenuItemSpriteExtra::create(
v23,
nullptr,
v4,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onClose);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v4->m_buttonMenu->addChild)(v4->m_buttonMenu, v24);
m_buttonMenu = v4->m_buttonMenu;
sub_10028CBE0((float *)v174, v178 * 0.5, (float)((float)(v179 * 0.5) + -155.0) + 23.0);
((void (__fastcall *)(cocos2d::CCMenu *, unsigned __int64 *))m_buttonMenu->setPosition)(m_buttonMenu, v174);
v26 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_plus2Btn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, float))v26->setScale)(v26, 0.80000001);
v27 = CCMenuItemSpriteExtra::create(
v26,
nullptr,
v4,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onNextFreeEditorLayer1);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v4->m_buttonMenu->addChild)(v4->m_buttonMenu, v27);
v28 = (const cocos2d::CCPoint *)v4->m_buttonMenu;
((void (__fastcall *)(SetGroupIDLayer *))v177->getPosition)(v177);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v170, v28);
sub_10028CBE0((float *)&v180, 50.0, 0.0);
sub_10028CCE0((double *)v174, &v170, &v180);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v27->setPosition)(v27, v174);
v29 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_plus2Btn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, float))v29->setScale)(v29, 0.80000001);
v30 = CCMenuItemSpriteExtra::create(
v29,
nullptr,
v4,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onNextFreeEditorLayer2);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v4->m_buttonMenu->addChild)(v4->m_buttonMenu, v30);
v31 = (const cocos2d::CCPoint *)v4->m_buttonMenu;
((void (__fastcall *)(cocos2d::CCNode *))v176->getPosition)(v176);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v170, v31);
sub_10028CBE0((float *)&v180, 54.0, 0.0);
sub_10028CCE0((double *)v174, &v170, &v180);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v30->setPosition)(v30, v174);
v32 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_optionsBtn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, float))v32->setScale)(v32, 0.34999999);
v33 = CCMenuItemSpriteExtra::create(
v32,
nullptr,
v4,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onGroupIDOptions);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v4->m_buttonMenu->addChild)(v4->m_buttonMenu, v33);
v34 = (const cocos2d::CCPoint *)v4->m_buttonMenu;
(*(void (__fastcall **)(int *))(*(_QWORD *)v166 + 192LL))(v166);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v170, v34);
sub_10028CBE0((float *)&v180, 73.0, 0.0);
sub_10028CCE0((double *)v174, &v170, &v180);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v33->setPosition)(v33, v174);
v141 = 8;
strcpy(v142, "Help");
__p = operator new(0x268u);
v144[0] = 617;
v144[1] = 608;
strcpy(
(char *)__p,
"Add assigns up to 10 groups to the selected object(s).\n"
" P sets a single object as group parent.\n"
"Editor L1 and L2 places the object(s) on an editor layer.\n"
"Z layer sets the draw layer of the object(s). T layers are above, while B layers are below the player.\n"
"Z order sets the draw order of the object(s) within the Z layer.\n"
"CH sets the channel of the object(s).\n"
"ORD sets the order of the object(s).\n"
"Extra has more advanced options.\n"
"Preview makes touch toggled triggers preview in editor.\n"
"Playback starts playback from this object.");
v35 = (_DWORD *)InfoAlertButton::create(&v141, v144, 0.80000001);
if ( (v144[0] & 1) != 0 )
operator delete(__p);
if ( (v141 & 1) != 0 )
operator delete(v143);
v35[138] = 1063675494;
((void (__fastcall *)(cocos2d::CCMenu *, _DWORD *))v4->m_buttonMenu->addChild)(v4->m_buttonMenu, v35);
v36 = (const cocos2d::CCPoint *)v4->m_buttonMenu;
sub_10028CBE0(
(float *)&v170,
(float)((float)(v178 * 0.5) + 195.0) + -17.0,
(float)((float)(v179 * 0.5) + 155.0) + -17.0);
*(cocos2d::CCPoint *)&v184 = cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v174, v36);
(*(void (__fastcall **)(_DWORD *, unsigned __int64 *, double))(*(_QWORD *)v35 + 184LL))(v35, v174, v184);
v37 = (unsigned __int64 *)((__int64 (__fastcall *)(SetGroupIDLayer *))v177->getPosition)(v177);
sub_10028CBE0((float *)&v170, 0.0, -30.0);
sub_10028CCE0((double *)v174, v37, &v170);
v146 = 4;
strcpy(v147, "L1");
v4->m_editorLayerInput = (CCTextInputNode *)SetGroupIDLayer::createTextInput(v4, v174, 5, 6, &v146, 2, 50.0);
if ( (v146 & 1) != 0 )
operator delete(v148);
v38 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCNode *))v176->getPosition)(v176);
sub_10028CBE0((float *)&v170, 0.0, -30.0);
sub_10028CCE0((double *)v174, v38, &v170);
v149 = 4;
strcpy(v150, "L2");
v39 = SetGroupIDLayer::createTextInput(v4, v174, 6, 6, &v149, 3, 50.0);
v177 = v4;
v4->m_editorLayer2Input = (CCTextInputNode *)v39;
if ( (v149 & 1) != 0 )
operator delete(v151);
v40 = (unsigned __int64 *)(*(__int64 (__fastcall **)(int *))(*(_QWORD *)v166 + 192LL))(v166);
sub_10028CBE0((float *)v174, 0.0, -30.0);
sub_10028CCE0((double *)&v170, v40, v174);
sub_10028CC60(v174, (double *)&v170);
v41 = v177;
v42 = "Num";
if ( v177->m_groupIDValue == -1 )
v42 = "Mixed";
v43 = 2 * (unsigned int)(v177->m_groupIDValue == -1);
v132 = 2 * (2 * (v177->m_groupIDValue == -1) + 3);
memcpy(__dst, v42, v43 + 3);
__dst[v43 + 3] = 0;
v44 = v41;
v41->m_groupIDInput = (CCTextInputNode *)SetGroupIDLayer::createTextInput(v41, v174, 1, 6, &v132, 1, 50.0);
if ( (v132 & 1) != 0 )
operator delete(v134);
v45 = ButtonSprite::create_1("Next Free", 50, 0, 0.69999999, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v46 = CCMenuItemSpriteExtra::create(
v45,
nullptr,
v41,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onNextGroupID1);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v41->m_buttonMenu->addChild)(v41->m_buttonMenu, v46);
v47 = (const cocos2d::CCPoint *)v41->m_buttonMenu;
*(float *)&v176 = (float)(v178 * 0.5) + -125.0;
v48 = ((__int64 (__fastcall *)(CCTextInputNode *))v41->m_groupIDInput->getPosition)(v41->m_groupIDInput);
sub_10028CBE0((float *)&v180, *(float *)&v176, *(float *)(v48 + 4));
*(cocos2d::CCPoint *)&v185 = cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v174, v47);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *, double))v46->setPosition)(v46, v174, v185);
v49 = 0;
if ( v169 )
v49 = -1046478848;
LODWORD(v176) = v49;
v50 = ButtonSprite::create_1("Add", 50, 0, 0.69999999, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v51 = CCMenuItemSpriteExtra::create(
v50,
nullptr,
v41,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onAddGroup);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v41->m_buttonMenu->addChild)(v41->m_buttonMenu, v51);
v52 = (const cocos2d::CCPoint *)v41->m_buttonMenu;
*(float *)&v176 = (float)((float)(v178 * 0.5) + 125.0) + *(float *)&v176;
v53 = ((__int64 (__fastcall *)(CCTextInputNode *))v44->m_groupIDInput->getPosition)(v44->m_groupIDInput);
sub_10028CBE0((float *)&v180, *(float *)&v176, *(float *)(v53 + 4));
*(cocos2d::CCPoint *)&v186 = cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v174, v52);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *, double))v51->setPosition)(v51, v174, v186);
if ( v169 )
{
v54 = ButtonSprite::create_1("P", 50, 0, 0.69999999, 0, "goldFont.fnt", "GJ_button_04.png", 25.0);
v55 = CCMenuItemSpriteExtra::create(
v54,
nullptr,
v44,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onAddGroupParent);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v44->m_buttonMenu->addChild)(
v44->m_buttonMenu,
v55);
v56 = (unsigned __int64 *)((__int64 (__fastcall *)(CCMenuItemSpriteExtra *))v51->getPosition)(v51);
sub_10028CBE0((float *)&v180, 60.0, 0.0);
sub_10028CCE0((double *)v174, v56, &v180);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v55->setPosition)(v55, v174);
}
v57 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v168->getPosition)(v168);
sub_10028CBE0((float *)&v180, 0.0, -30.0);
sub_10028CCE0((double *)v174, v57, &v180);
v135 = 23042;
v136 = 0;
v58 = v44;
v44->m_zOrderInput = (CCTextInputNode *)SetGroupIDLayer::createTextInput(v44, v174, 7, 6, &v135, 2, 50.0);
if ( (v135 & 1) != 0 )
{
v58 = v137;
operator delete(v137);
}
v59 = nullptr;
v60 = (int *)&unk_1008198FC;
v61 = -5;
v164 = (cocos2d::CCArray *)sub_10071F9E0(v58, v174);
v62 = v177;
do
{
v69 = 0;
v70 = "Default";
v176 = v59;
if ( (unsigned int)v59 <= 8 )
{
v70 = (char *)&unk_1008198FC + *v60;
v69 = v61;
}
LODWORD(v168) = v69;
v166 = v60;
v63 = ButtonSprite::create_1(v70, 220, 0, 0.30000001, 0, "bigFont.fnt", "GJ_button_04.png", 25.0);
sub_10071FCD0(v62->m_zLayerButtons, v63);
v64 = CCMenuItemSpriteExtra::create(
v63,
nullptr,
v62,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onZLayer);
v65 = (unsigned int)v168;
((void (__fastcall *)(CCMenuItemSpriteExtra *, _QWORD))v64->setTag)(v64, (unsigned int)v168);
v66 = v63->cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v67 = v63;
v68 = v62;
((void (__fastcall *)(ButtonSprite *, _QWORD))v66->setTag)(v67, v65);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v62->m_buttonMenu->addChild)(
v62->m_buttonMenu,
v64);
sub_10071FCD0(v164, v64);
v59 = (cocos2d::CCNode *)(unsigned int)((_DWORD)v176 + 1);
v60 = v166 + 1;
v61 += 2;
}
while ( v61 != 15 );
v71 = (const cocos2d::CCPoint *)v62->m_buttonMenu;
v72 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v167->getPosition)(v167);
sub_10028CBE0((float *)v182, 0.0, -28.0);
sub_10028CCE0((double *)&v180, v72, v182);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v174, v71);
GameToolbox::alignItemsHorisontally(v164, 5.0, (cocos2d::CCPoint)3252682752LL, (bool)v174);
SetGroupIDLayer::determineStartValues(v68);
v73 = 1109393408;
LODWORD(v176) = 1109393408;
if ( v68->m_zLayerValue == -100 )
{
m_targetObjects = v68->m_targetObjects;
if ( m_targetObjects )
{
if ( (unsigned int)sub_100720070(m_targetObjects) )
{
LOWORD(v174[0]) = 11522;
BYTE2(v174[0]) = 0;
v75 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_colorBtn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, void *))v75->setColor)(v75, &unk_1008198A8);
((void (__fastcall *)(cocos2d::CCSprite *, __int64))v75->setOpacity)(v75, 100);
v76 = (char *)v174 + 1;
v77 = (char *)v174 + 1;
if ( (v174[0] & 1) != 0 )
v77 = (const char *)v175;
v78 = cocos2d::CCLabelBMFont::create_3(v77, "bigFont.fnt");
((void (__fastcall *)(cocos2d::CCSprite *, cocos2d::CCLabelBMFont *))v75->addChild)(v75, v78);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v78->setScale)(v78, 1.4);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v182, (const cocos2d::CCPoint *)v75);
sub_10028CBE0((float *)&v181, 2.0, 2.5);
sub_10028CCE0((double *)&v180, v182, &v181);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v78->setPosition)(v78, &v180);
((void (__fastcall *)(cocos2d::CCSprite *, float))v75->setScale)(v75, 0.30000001);
v79 = CCMenuItemSpriteExtra::create(
v75,
nullptr,
v68,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onZLayerShift);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v68->m_buttonMenu->addChild)(
v68->m_buttonMenu,
v79);
((void (__fastcall *)(CCMenuItemSpriteExtra *, _QWORD))v79->setTag)(v79, 0);
v80 = (const cocos2d::CCPoint *)v68->m_buttonMenu;
v81 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v167->getPosition)(v167);
sub_10028CBE0((float *)&v181, -40.0, -2.0);
sub_10028CCE0((double *)v182, v81, &v181);
*(cocos2d::CCPoint *)&v187 = cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v180, v80);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *, double))v79->setPosition)(v79, &v180, v187);
CCMenuItemSpriteExtra::setSizeMult(v79, 2.0);
if ( (v174[0] & 1) != 0 )
operator delete(v175);
LOWORD(v174[0]) = 11010;
BYTE2(v174[0]) = 0;
v82 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_colorBtn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, void *))v82->setColor)(v82, &unk_1008198AB);
((void (__fastcall *)(cocos2d::CCSprite *, __int64))v82->setOpacity)(v82, 100);
if ( (v174[0] & 1) != 0 )
v76 = (const char *)v175;
v83 = cocos2d::CCLabelBMFont::create_3(v76, "bigFont.fnt");
((void (__fastcall *)(cocos2d::CCSprite *, cocos2d::CCLabelBMFont *))v82->addChild)(v82, v83);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v83->setScale)(v83, 1.4);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v182, (const cocos2d::CCPoint *)v82);
sub_10028CBE0((float *)&v181, 2.0, 2.5);
sub_10028CCE0((double *)&v180, v182, &v181);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v83->setPosition)(v83, &v180);
((void (__fastcall *)(cocos2d::CCSprite *, float))v82->setScale)(v82, 0.30000001);
v84 = CCMenuItemSpriteExtra::create(
v82,
nullptr,
v68,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onZLayerShift);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v68->m_buttonMenu->addChild)(
v68->m_buttonMenu,
v84);
((void (__fastcall *)(CCMenuItemSpriteExtra *, __int64))v84->setTag)(v84, 1);
v85 = (const cocos2d::CCPoint *)v68->m_buttonMenu;
v86 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v167->getPosition)(v167);
sub_10028CBE0((float *)&v181, 40.0, -2.0);
sub_10028CCE0((double *)v182, v86, &v181);
*(cocos2d::CCPoint *)&v188 = cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v180, v85);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *, double))v84->setPosition)(v84, &v180, v188);
CCMenuItemSpriteExtra::setSizeMult(v84, 2.0);
if ( (v174[0] & 1) != 0 )
operator delete(v175);
v73 = 1113325568;
LODWORD(v176) = 1113325568;
}
}
}
m_targetObject = v68->m_targetObject;
if ( m_targetObject )
{
ParentMode = GameObject::getParentMode(m_targetObject);
LABEL_41:
if ( ParentMode != -1 )
{
v89 = (cocos2d::CCString *)sub_1007AB580("(%i)", v131);
CString = cocos2d::CCString::getCString(v89);
goto LABEL_51;
}
}
else
{
v91 = v68->m_targetObjects;
if ( v91 && (unsigned int)sub_100720070(v91) )
{
v92 = 0;
ParentMode = -1;
while ( 1 )
{
v93 = (GameObject *)sub_1007200C0(v68->m_targetObjects, v92);
v94 = GameObject::getParentMode(v93);
if ( ParentMode == -1 )
{
ParentMode = v94;
}
else if ( ParentMode != v94 )
{
break;
}
if ( ++v92 >= (unsigned int)sub_100720070(v68->m_targetObjects) )
goto LABEL_41;
}
}
}
CString = "(-)";
LABEL_51:
v95 = strlen(CString);
if ( v95 >= 0xFFFFFFFFFFFFFFF8LL )
sub_100006BF0(*(double *)&v73);
v96 = v95;
if ( v95 >= 0x17 )
{
v99 = 26;
if ( (v95 | 7) != 0x17 )
v99 = (v95 | 7) + 1;
v97 = (char *)operator new(v99);
v175 = v97;
v174[0] = v99 + 1;
v68 = v177;
v174[1] = v96;
LABEL_59:
memmove(v97, CString, v96);
v97[v96] = 0;
if ( (v174[0] & 1) != 0 )
goto LABEL_55;
goto LABEL_60;
}
LOBYTE(v174[0]) = 2 * v95;
v97 = (char *)v174 + 1;
if ( v95 )
goto LABEL_59;
BYTE1(v174[0]) = 0;
if ( (v174[0] & 1) != 0 )
{
LABEL_55:
v98 = (const char *)v175;
goto LABEL_61;
}
LABEL_60:
v98 = (char *)v174 + 1;
LABEL_61:
v100 = cocos2d::CCLabelBMFont::create_3(v98, "chatFont.fnt");
v101 = (unsigned __int64 *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v167->getPosition)(v167);
sub_10028CBE0((float *)v182, *(float *)&v176, -2.0);
sub_10028CCE0((double *)&v180, v101, v182);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, unsigned __int64 *))v100->setPosition)(v100, &v180);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCLabelBMFont *))v68->m_mainLayer->addChild)(
v68->m_mainLayer,
v100);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v100->setScale)(v100, 0.60000002);
((void (__fastcall *)(cocos2d::CCLabelBMFont *, void *))v100->setColor)(v100, &unk_1008198AE);
if ( v68->m_showChannelOrder )
{
sub_10028CBE0((float *)&v180, (float)(v178 * 0.5) + -125.0, (float)((float)(v179 * 0.5) + -155.0) + 25.0);
sub_10028CBE0((float *)v182, (float)(v178 * 0.5) + 125.0, *((float *)&v180 + 1));
sub_10028CC60(&v181, (double *)&v180);
v138 = 6;
v139 = 4477519;
v68->m_orderInput = (CCTextInputNode *)SetGroupIDLayer::createTextInput(v68, &v181, 3, 6, &v138, 2, 50.0);
if ( (v138 & 1) != 0 )
operator delete(v140);
SetGroupIDLayer::updateEditorOrderLabel(v68);
sub_10028CC60(&v181, (double *)v182);
v152 = 4;
strcpy(v153, "CH");
v68->m_channelInput = (CCTextInputNode *)SetGroupIDLayer::createTextInput(v68, &v181, 4, 6, &v152, 2, 50.0);
if ( (v152 & 1) != 0 )
operator delete(v154);
SetGroupIDLayer::updateOrderChannelLabel(v68);
v102 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_plus2Btn_001.png");
((void (__fastcall *)(cocos2d::CCSprite *, float))v102->setScale)(v102, 0.80000001);
v103 = CCMenuItemSpriteExtra::create(
v102,
nullptr,
v68,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onNextFreeOrderChannel);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v68->m_buttonMenu->addChild)(
v68->m_buttonMenu,
v103);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v172, (const cocos2d::CCPoint *)v68->m_buttonMenu);
sub_10028CBE0((float *)&v171, -75.0, 0.0);
sub_10028CCE0((double *)&v181, &v172, &v171);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v103->setPosition)(v103, &v181);
}
SetGroupIDLayer::updateGroupIDLabel(v68);
SetGroupIDLayer::updateEditorLabel(v68);
SetGroupIDLayer::updateEditorLabel2(v68);
SetGroupIDLayer::updateZOrderLabel(v68);
if ( (unsigned int)sub_100720070(v68->m_zLayerButtons) )
{
v104 = 0;
do
{
v105 = (ButtonSprite *)sub_1007200C0(v177->m_zLayerButtons, v104);
m_zLayerValue = v177->m_zLayerValue;
v107 = "GJ_button_02.png";
if ( m_zLayerValue != ((unsigned int (__fastcall *)(ButtonSprite *))v105->getTag)(v105) )
v107 = "GJ_button_04.png";
ButtonSprite::updateBGImage(v105, v107);
++v104;
}
while ( v104 < (unsigned int)sub_100720070(v177->m_zLayerButtons) );
}
v108 = v177;
SetGroupIDLayer::updateGroupIDButtons(v177);
v109 = (const cocos2d::CCPoint *)v108->m_buttonMenu;
sub_10028CBE0((float *)v182, (float)(v178 * 0.5) + 217.0, (float)(0.5 * v179) + 142.0);
cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)&v180, v109);
v110 = ButtonSprite::create_1("Copy", 20, 0, 0.5, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v176 = ButtonSprite::create_1("Paste", 20, 0, 0.5, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v111 = ButtonSprite::create_1("Extra", 20, 0, 0.5, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v112 = ButtonSprite::create_1("Extra2", 20, 0, 0.5, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v113 = ButtonSprite::create_1("Anim", 20, 0, 0.5, 1, "goldFont.fnt", "GJ_button_04.png", 25.0);
v114 = CCMenuItemSpriteExtra::create(
v110,
nullptr,
v108,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onCopy);
v176 = CCMenuItemSpriteExtra::create(
v176,
nullptr,
v108,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onPaste);
v115 = CCMenuItemSpriteExtra::create(
v111,
nullptr,
v108,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onExtra);
v116 = CCMenuItemSpriteExtra::create(
v112,
nullptr,
v108,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onExtra2);
v117 = CCMenuItemSpriteExtra::create(
v113,
nullptr,
v108,
(cocos2d::SEL_MenuHandler)(unsigned __int64)SetGroupIDLayer::onAnim);
if ( v169 )
{
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v108->m_buttonMenu->addChild)(
v108->m_buttonMenu,
v114);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v114->setPosition)(v114, &v180);
LABEL_75:
((void (__fastcall *)(cocos2d::CCMenu *, cocos2d::CCNode *))v108->m_buttonMenu->addChild)(v108->m_buttonMenu, v176);
v119 = sub_10028CC60(v182, (double *)&v180);
if ( v169 )
{
sub_10028CBE0((float *)&v172, 0.0, -31.0);
sub_10028CCE0((double *)&v181, v182, &v172);
v119 = sub_10028CC90(v182, (double *)&v181);
}
((void (__fastcall *)(cocos2d::CCNode *, unsigned __int64 *, double))v176->setPosition)(v176, v182, v119);
goto LABEL_78;
}
v118 = GameManager::sharedState();
if ( LevelEditorLayer::canPasteState(v118->m_levelEditorLayer) )
goto LABEL_75;
LABEL_78:
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v108->m_buttonMenu->addChild)(
v108->m_buttonMenu,
v115);
sub_10028CBE0((float *)&v181, 0.0, -62.0);
sub_10028CCE0((double *)v182, &v180, &v181);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v115->setPosition)(v115, v182);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v108->m_buttonMenu->addChild)(
v108->m_buttonMenu,
v116);
sub_10028CBE0((float *)&v181, 0.0, -93.0);
sub_10028CCE0((double *)v182, &v180, &v181);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v116->setPosition)(v116, v182);
((void (__fastcall *)(cocos2d::CCMenu *, CCMenuItemSpriteExtra *))v108->m_buttonMenu->addChild)(
v108->m_buttonMenu,
v117);
sub_10028CBE0((float *)&v181, 0.0, -124.0);
sub_10028CCE0((double *)v182, &v180, &v181);
((void (__fastcall *)(CCMenuItemSpriteExtra *, unsigned __int64 *))v117->setPosition)(v117, v182);
sub_10028CBE0((float *)v182, 0.0, 2.0);
v120 = v169;
sub_10028CBE0((float *)&v181, (float)(v178 * 0.5) + 217.0, (float)((float)(0.5 * v179) + 142.0) + -164.0);
if ( v120 )
{
if ( v120->m_classType == Effect && GameManager::sharedState()->m_levelEditorLayer )
{
v161 = 14;
strcpy(v162, "Preview");
v121 = v108;
m_pobTexture = (unsigned __int8)v120[1].m_pobTexture;
v123 = v121->m_buttonMenu;
sub_10028CBE0((float *)&v171, 0.0, -0.0);
sub_10028CCE0((double *)&v172, &v181, &v171);
sub_10028CC60(&v165, (double *)v182);
GameToolbox::createToggleButton(
(unsigned int)&v161,
(unsigned int)SetGroupIDLayer::onToggleGuide,
0,
m_pobTexture,
(_DWORD)v123,
(unsigned int)&v172,
(__int64)v177,
(__int64)v177,
(__int64)&v165,
(__int64)"goldFont.fnt",
1,
0,
0);
if ( (v161 & 1) != 0 )
operator delete(v163);
m_playbackObject = GameManager::sharedState()->m_levelEditorLayer->m_playbackObject;
v155 = 16;
strcpy(v156, "Playback");
v125 = v177->m_buttonMenu;
sub_10028CBE0((float *)&v171, 0.0, -38.0);
sub_10028CCE0((double *)&v172, &v181, &v171);
sub_10028CC60(&v165, (double *)v182);
GameToolbox::createToggleButton(
(unsigned int)&v155,
(unsigned int)SetGroupIDLayer::onToggleSelectedOrder,
0,
m_playbackObject == v169,
(_DWORD)v125,
(unsigned int)&v172,
(__int64)v177,
(__int64)v177,
(__int64)&v165,
(__int64)"goldFont.fnt",
1,
0,
0);
if ( (v155 & 1) != 0 )
operator delete(*(void **)&v156[15]);
m_traceOutObject = GameManager::sharedState()->m_levelEditorLayer->m_traceOutObject;
v157 = 18;
strcpy(v158, "Trace Out");
v127 = v177->m_buttonMenu;
sub_10028CBE0((float *)&v171, 0.0, -76.0);
sub_10028CCE0((double *)&v172, &v181, &v171);
sub_10028CC60(&v165, (double *)v182);
GameToolbox::createToggleButton(
(unsigned int)&v157,
(unsigned int)SetGroupIDLayer::onToggleTraceOut,
0,
m_traceOutObject == v169,
(_DWORD)v127,
(unsigned int)&v172,
(__int64)v177,
(__int64)v177,
(__int64)&v165,
(__int64)"goldFont.fnt",
1,
0,
0);
v108 = v177;
if ( (v157 & 1) != 0 )
operator delete(*(void **)&v158[15]);
}
if ( GameManager::sharedState()->m_levelEditorLayer )
{
m_traceInObject = GameManager::sharedState()->m_levelEditorLayer->m_traceInObject;
v159 = 16;
strcpy(v160, "Trace In");
v129 = v177->m_buttonMenu;
sub_10028CBE0((float *)&v171, 0.0, -114.0);
sub_10028CCE0((double *)&v172, &v181, &v171);
sub_10028CC60(&v165, (double *)v182);
GameToolbox::createToggleButton(
(unsigned int)&v159,
(unsigned int)SetGroupIDLayer::onToggleTraceIn,
0,
m_traceInObject == v169,
(_DWORD)v129,
(unsigned int)&v172,
(__int64)v177,
(__int64)v177,
(__int64)&v165,
(__int64)"goldFont.fnt",
1,
0,
0);
v108 = v177;
if ( (v159 & 1) != 0 )
operator delete(*(void **)&v160[15]);
}
}
v108->m_editorLayerEdited = 0;
if ( (v174[0] & 1) != 0 )
operator delete(v175);
return v173;
}