//
// LevelEditorLayer::updateDebugDraw from 0x140406bd0 to 0x1404089df (7695 bytes)
//
// 2 xrefs:
// > ??> @ 0x14078b250
// > ??> @ 0x140925c10
//
// This function is hookable on this platform (idp: pc, 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 11:31:59 +0000
//
// Hidden C++ exception states: #wind=8
void __fastcall LevelEditorLayer::updateDebugDraw(__int64 a1)
{
__int64 v1; // rsi
__int64 v2; // rcx
__int64 v3; // rcx
double v4; // xmm2_8
double v5; // xmm0_8
float v6; // xmm0_4
__int64 v7; // rax
float v8; // xmm6_4
__int64 v9; // rcx
bool GameVariable; // r13
__int64 v11; // rcx
bool v12; // di
signed int v13; // r14d
float v14; // xmm13_4
float v15; // xmm14_4
float v16; // xmm7_4
struct cocos2d::CCObject *v17; // rbx
float v18; // xmm6_4
float *v19; // rax
float v20; // xmm11_4
const struct cocos2d::CCPoint *v21; // rax
float v22; // xmm8_4
float v23; // xmm7_4
float v24; // xmm9_4
float v25; // xmm6_4
const struct cocos2d::CCPoint *v26; // rax
float v27; // xmm6_4
float v28; // xmm2_4
float v29; // xmm9_4
float v30; // xmm7_4
float v31; // xmm2_4
float v32; // xmm10_4
cocos2d::CCDrawNode *v33; // rdi
const struct cocos2d::CCPoint *v34; // rax
const struct cocos2d::CCPoint *v35; // rbx
const struct cocos2d::CCPoint *v36; // rax
__int64 v37; // rcx
struct cocos2d::CCPoint *v38; // r12
int v39; // eax
__int64 v40; // rbx
__int64 v41; // rbx
__int64 v42; // r15
int v43; // eax
int v44; // eax
int v45; // ecx
int v46; // edx
cocos2d::CCArray *v47; // rbx
struct cocos2d::CCObject *v48; // rax
_QWORD *KeyframeCommand; // r13
__int64 v50; // r14
__int64 v51; // r8
float v52; // r9d
__int64 v53; // r15
__int64 v54; // rbx
cocos2d::CCPoint *v55; // rdi
int v56; // ebx
struct cocos2d::CCPoint *v57; // rdi
float v58; // xmm7_4
float v59; // xmm1_4
__int64 v60; // rax
int v61; // edi
__int64 v62; // rbx
__int64 v63; // rdx
__int64 v64; // rax
__int64 v65; // r8
__int64 v66; // rax
__int64 v67; // rdi
__int64 v68; // rbx
__int64 v69; // rax
__int64 v70; // r8
__int64 v71; // rdx
__int64 v72; // r9
_QWORD *v73; // rcx
__int64 v74; // rax
__int64 v75; // rcx
__int64 v76; // r13
_QWORD *v77; // r12
__int64 v78; // rdi
__int64 v79; // r15
__int16 *v80; // rbx
int v81; // eax
int v82; // ecx
const struct cocos2d::CCRect *v83; // rax
float v84; // xmm0_4
__int64 v85; // rbx
__int64 v86; // rdx
__int64 v87; // rax
__int64 v88; // rax
__int64 v89; // rax
__int64 v90; // rcx
int v91; // r14d
__int64 v92; // rcx
__int64 v93; // rcx
__int64 v94; // rcx
__int64 v95; // rcx
__int64 v96; // rcx
__int64 v97; // rcx
__int64 v98; // rbx
_DWORD *v99; // rbx
int v100; // eax
int v101; // r15d
int v102; // eax
__int64 v103; // r14
cocos2d::CCArray *v104; // rdi
float v105; // xmm9_4
float v106; // xmm7_4
float v107; // xmm8_4
bool v108; // bl
float MinX; // xmm10_4
float MinY; // xmm11_4
float MaxX; // xmm12_4
float MaxY; // xmm13_4
int v113; // r14d
unsigned int *v114; // r12
__int64 v115; // rax
_QWORD *v116; // r12
__m128i si128; // xmm14
__m128i v118; // xmm15
bool v119; // al
float v120; // xmm6_4
cocos2d::CCDrawNode *v121; // rdi
const struct cocos2d::CCPoint *v122; // rax
const struct cocos2d::CCPoint *v123; // rbx
const struct cocos2d::CCPoint *v124; // rax
unsigned __int8 v125; // al
float v126; // xmm6_4
cocos2d::CCDrawNode *v127; // rdi
const struct cocos2d::CCPoint *v128; // rax
const struct cocos2d::CCPoint *v129; // rbx
const struct cocos2d::CCPoint *v130; // rax
unsigned __int8 v131; // al
float v132; // xmm6_4
cocos2d::CCDrawNode *v133; // rdi
const struct cocos2d::CCPoint *v134; // rax
const struct cocos2d::CCPoint *v135; // rbx
const struct cocos2d::CCPoint *v136; // rax
unsigned __int8 v137; // al
float v138; // xmm6_4
cocos2d::CCDrawNode *v139; // rdi
const struct cocos2d::CCPoint *v140; // rax
const struct cocos2d::CCPoint *v141; // rbx
const struct cocos2d::CCPoint *v142; // rax
bool v143; // al
float v144; // xmm6_4
cocos2d::CCDrawNode *v145; // rdi
const struct cocos2d::CCPoint *v146; // rax
const struct cocos2d::CCPoint *v147; // rbx
const struct cocos2d::CCPoint *v148; // rax
unsigned __int8 v149; // al
float v150; // xmm6_4
cocos2d::CCDrawNode *v151; // rdi
const struct cocos2d::CCPoint *v152; // rax
const struct cocos2d::CCPoint *v153; // rbx
const struct cocos2d::CCPoint *v154; // rax
unsigned __int8 v155; // al
float v156; // xmm6_4
cocos2d::CCDrawNode *v157; // rdi
const struct cocos2d::CCPoint *v158; // rax
const struct cocos2d::CCPoint *v159; // rbx
const struct cocos2d::CCPoint *v160; // rax
unsigned __int8 v161; // al
float v162; // xmm6_4
cocos2d::CCDrawNode *v163; // rdi
const struct cocos2d::CCPoint *v164; // rax
const struct cocos2d::CCPoint *v165; // rbx
const struct cocos2d::CCPoint *v166; // rax
bool v167; // al
float v168; // xmm6_4
cocos2d::CCDrawNode *v169; // rdi
const struct cocos2d::CCPoint *v170; // rax
const struct cocos2d::CCPoint *v171; // rbx
const struct cocos2d::CCPoint *v172; // rax
unsigned __int8 v173; // al
float v174; // xmm6_4
cocos2d::CCDrawNode *v175; // rdi
const struct cocos2d::CCPoint *v176; // rax
const struct cocos2d::CCPoint *v177; // rbx
const struct cocos2d::CCPoint *v178; // rax
unsigned __int8 v179; // al
float v180; // xmm6_4
cocos2d::CCDrawNode *v181; // rdi
const struct cocos2d::CCPoint *v182; // rax
const struct cocos2d::CCPoint *v183; // rbx
const struct cocos2d::CCPoint *v184; // rax
unsigned __int8 v185; // al
float v186; // xmm6_4
cocos2d::CCDrawNode *v187; // rdi
const struct cocos2d::CCPoint *v188; // rax
const struct cocos2d::CCPoint *v189; // rbx
const struct cocos2d::CCPoint *v190; // rax
__int64 v191; // rcx
int v192; // r13d
__int64 v193; // r15
int v194; // edi
__int64 v195; // r14
__m128i v196; // xmm6
__int64 v197; // rbx
const struct cocos2d::CCPoint *v198; // r8
__int64 v199; // rax
__int64 v200; // rcx
__int64 v201; // rdx
float v202; // ecx
__int64 v203; // rdi
__m128i v204; // xmm6
__int64 v205; // r14
__int64 v206; // r13
int v207; // r15d
__int64 v208; // r12
__int64 v209; // rbx
const struct cocos2d::CCPoint *v210; // r8
bool v211; // zf
__int64 v212; // rcx
const struct cocos2d::CCPoint *v213; // r15
const struct cocos2d::CCPoint *v214; // r14
__m128i v215; // xmm8
float v216; // xmm7_4
float v217; // xmm6_4
__int64 v218; // rdi
__int64 v219; // rax
__int64 v220; // rbx
__int64 v221; // rax
bool v222; // [rsp+78h] [rbp-90h]
char v223; // [rsp+78h] [rbp-90h]
bool v224; // [rsp+79h] [rbp-8Fh]
float v225; // [rsp+7Ch] [rbp-8Ch]
int v226; // [rsp+7Ch] [rbp-8Ch]
float v227; // [rsp+80h] [rbp-88h] BYREF
float v228; // [rsp+84h] [rbp-84h]
float v229; // [rsp+88h] [rbp-80h] BYREF
float v230; // [rsp+8Ch] [rbp-7Ch]
__int64 v231; // [rsp+90h] [rbp-78h] BYREF
float v232; // [rsp+98h] [rbp-70h] BYREF
float v233; // [rsp+9Ch] [rbp-6Ch]
_BYTE v234[4]; // [rsp+A0h] [rbp-68h] BYREF
float v235; // [rsp+A4h] [rbp-64h]
__int64 v236; // [rsp+A8h] [rbp-60h] BYREF
struct cocos2d::CCPoint *v237; // [rsp+B0h] [rbp-58h] BYREF
__int64 v238; // [rsp+B8h] [rbp-50h] BYREF
unsigned __int64 v239; // [rsp+C0h] [rbp-48h]
_BYTE v240[16]; // [rsp+C8h] [rbp-40h] BYREF
float v241; // [rsp+D8h] [rbp-30h] BYREF
float v242; // [rsp+DCh] [rbp-2Ch]
__int64 v243; // [rsp+E0h] [rbp-28h] BYREF
struct cocos2d::CCPoint *v244; // [rsp+E8h] [rbp-20h] BYREF
char v245[8]; // [rsp+F0h] [rbp-18h] BYREF
char v246[8]; // [rsp+F8h] [rbp-10h] BYREF
char v247[8]; // [rsp+100h] [rbp-8h] BYREF
char v248[8]; // [rsp+108h] [rbp+0h] BYREF
char v249[8]; // [rsp+110h] [rbp+8h] BYREF
char v250[8]; // [rsp+118h] [rbp+10h] BYREF
char v251[8]; // [rsp+120h] [rbp+18h] BYREF
char v252[8]; // [rsp+128h] [rbp+20h] BYREF
char v253[8]; // [rsp+130h] [rbp+28h] BYREF
char v254[8]; // [rsp+138h] [rbp+30h] BYREF
char v255[8]; // [rsp+140h] [rbp+38h] BYREF
struct __timeb64 Time; // [rsp+148h] [rbp+40h] BYREF
__int128 v257; // [rsp+158h] [rbp+50h] BYREF
_BYTE v258[12]; // [rsp+168h] [rbp+60h] BYREF
float v259; // [rsp+174h] [rbp+6Ch]
__m128i v260; // [rsp+178h] [rbp+70h] BYREF
__int64 v261; // [rsp+188h] [rbp+80h]
__int128 v262; // [rsp+190h] [rbp+88h] BYREF
__m128i v263; // [rsp+1A0h] [rbp+98h] BYREF
v1 = a1;
v239 = a1;
GJBaseGameLayer::updateDebugDraw(a1);
v2 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v238 = (__int64)operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(v238);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v2 = qword_14090BFD0;
}
byte_1409097DE = GameManager::getGameVariable(v2, "0181");
ftime64(&Time);
v4 = (double)Time.millitm / 1000.0 + (double)SLODWORD(Time.time);
dbl_14090C058 = v4;
if ( byte_1409097DE )
{
v5 = 0.5199999809265137;
}
else
{
v6 = fmod(v4, 2.0) * 0.5;
v5 = (float)(1.0 - v6);
}
qword_14090C060 = *(_QWORD *)&v5;
v7 = cocos2d::CCDirector::sharedDirector(v3);
cocos2d::CCDirector::getWinSize(v7, &v241);
v8 = 0.25 / (*(float (__fastcall **)(_QWORD))(**(_QWORD **)(v1 + 4296) + 168LL))(*(_QWORD *)(v1 + 4296));
v225 = v8;
cocos2d::CCDrawNode::getDrawArea(*(_QWORD *)(v1 + 14448), v240);
v9 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v238 = (__int64)operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(v238);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v9 = qword_14090BFD0;
}
GameVariable = GameManager::getGameVariable(v9, "0121");
v224 = GameVariable;
v11 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v238 = (__int64)operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(v238);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v11 = qword_14090BFD0;
}
v12 = GameManager::getGameVariable(v11, "0209");
v222 = v12;
cocos2d::CCDrawNode::enableDrawArea(*(cocos2d::CCDrawNode **)(v1 + 14448), (struct cocos2d::CCRect *)v240);
v13 = 0;
if ( cocos2d::CCArray::count(*(cocos2d::CCArray **)(v1 + 14736)) )
{
v14 = v241 * 2.0;
v15 = v242 * 2.0;
if ( cocos2d::CCArray::count(*(cocos2d::CCArray **)(v1 + 14736)) )
{
v16 = v14 * 0.5;
v227 = v14 * 0.5;
do
{
v17 = cocos2d::CCArray::objectAtIndex(*(cocos2d::CCArray **)(v1 + 14736), v13);
v18 = *(float *)((*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v17 + 200LL))(v17) + 4)
- (float)(v15 * 0.5);
v19 = (float *)(*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v17 + 200LL))(v17);
cocos2d::CCRect::CCRect((cocos2d::CCRect *)&v263, *v19 - v16, v18, v14, v15);
if ( *((_DWORD *)v17 + 259) != 2016
|| !cocos2d::CCRect::intersectsRect((cocos2d::CCRect *)v240, (const struct cocos2d::CCRect *)&v263)
|| (GameVariable && *((_BYTE *)v17 + 1302) || v12 && *((_BYTE *)v17 + 1267)) && !*((_BYTE *)v17 + 1141)
|| (v20 = *((float *)v17 + 470), v20 <= 0.0) )
{
v8 = v225;
}
else
{
v21 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v17 + 200LL))(v17);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v229, v21);
v22 = fminf(*((float *)v17 + 440), 3.0);
if ( v22 < 0.40000001 )
v22 = 0.40000001;
v23 = 320.0 / v22;
v24 = v241 / v22;
v25 = v242 / v22;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v257, (struct cocos2d::CCObject *)((char *)v17 + 1504));
if ( (float)(480.0 / v22) == v24 && v25 == v23 )
{
v8 = v225;
}
else
{
v26 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(struct cocos2d::CCObject *))(*(_QWORD *)v17 + 200LL))(v17);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v232, v26);
v27 = v25 * 0.5;
v28 = v233;
if ( (float)(v233 - v27) < 0.0 )
{
v28 = v27 + 0.0;
v233 = v27 + 0.0;
}
v29 = v24 * 0.5;
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)&v238,
(float)(v232 - v29) + *(float *)&v257,
(float)(v28 - v27) + *((float *)&v257 + 1));
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)&v236,
(float)(v29 + v232) + *(float *)&v257,
(float)(v27 + v233) + *((float *)&v257 + 1));
LODWORD(Time.time) = 1065353216;
*(__time64_t *)((char *)&Time.time + 4) = 1056964608;
*(float *)&Time.dstflag = v20;
v262 = 0;
v8 = v225;
cocos2d::CCDrawNode::drawRect(*(_QWORD *)(v1 + 14448), &v238, &v236, &v262, LODWORD(v225), &Time, 0);
}
v30 = v23 * 0.5;
v31 = v230;
if ( (float)(v230 - v30) < 0.0 )
{
v31 = v30 + 0.0;
v230 = v30 + 0.0;
}
v32 = (float)(480.0 / v22) * 0.5;
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)v234,
(float)(v229 - v32) + *(float *)&v257,
(float)(v31 - v30) + *((float *)&v257 + 1));
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)&v231,
(float)(v32 + v229) + *(float *)&v257,
(float)(v30 + v230) + *((float *)&v257 + 1));
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v237, v229 - (float)((float)*(int *)(v1 + 676) / v22), v230);
*(_DWORD *)v258 = 0;
*(_QWORD *)&v258[4] = 1065353216;
v259 = v20;
v262 = 0;
cocos2d::CCDrawNode::drawRect(*(_QWORD *)(v1 + 14448), v234, &v231, &v262, LODWORD(v8), v258, 0);
v260.m128i_i32[0] = 1065353216;
*(__int64 *)((char *)v260.m128i_i64 + 4) = 1065353216;
*(float *)&v260.m128i_i32[3] = v20;
v33 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v244, *(float *)&v237, *((float *)&v231 + 1));
v35 = v34;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v243, *(float *)&v237, v235);
cocos2d::CCDrawNode::drawSegment(v33, v36, v35, v8, (const struct cocos2d::_ccColor4F *)&v260);
v16 = v227;
v12 = v222;
}
++v13;
}
while ( v13 < cocos2d::CCArray::count(*(cocos2d::CCArray **)(v1 + 14736)) );
v13 = 0;
}
}
v37 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v243 = (__int64)operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(v243);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v37 = qword_14090BFD0;
}
if ( !GameManager::getGameVariable(v37, "0182") )
{
v38 = nullptr;
v237 = nullptr;
v39 = 0;
v40 = *(_QWORD *)(v1 + 13872);
if ( v40 )
{
v41 = *(_QWORD *)(v40 + 56);
if ( v41 )
{
v42 = *(_QWORD *)(v41 + 288);
while ( 1 )
{
v231 = v42;
v43 = v39 + 1;
LODWORD(v257) = v43;
if ( v43 > 5 )
break;
switch ( v43 )
{
case 1:
LODWORD(v257) = 1;
goto LABEL_53;
case 2:
LODWORD(v257) = 2;
v44 = 255;
v45 = 150;
v46 = 50;
goto LABEL_55;
case 3:
LODWORD(v257) = 3;
v44 = 0;
v45 = 255;
v46 = 255;
goto LABEL_55;
case 4:
LODWORD(v257) = 4;
v44 = 255;
v45 = 255;
v46 = 0;
goto LABEL_55;
}
if ( v43 != 5 )
goto LABEL_53;
LODWORD(v257) = 5;
v44 = 255;
v45 = 0;
LABEL_54:
v46 = v44;
LABEL_55:
*(float *)v258 = (float)v44 / 255.0;
*(float *)&v258[4] = (float)v45 / 255.0;
*(float *)&v258[8] = (float)v46 / 255.0;
v259 = 1.0;
v47 = *(cocos2d::CCArray **)(v41 + 264);
if ( v47 && cocos2d::CCArray::count(v47) > 1 )
{
if ( ((v48 = cocos2d::CCArray::objectAtIndex(v47, 0), !GameVariable) || !*((_BYTE *)v48 + 1302))
&& (!v12 || !*((_BYTE *)v48 + 1267))
|| *((_BYTE *)v48 + 1141) )
{
v260 = 0;
v261 = 0;
KeyframeCommand = GJEffectManager::createKeyframeCommand(
*(_QWORD *)(v1 + 2408),
0,
v47,
0,
0,
0,
1,
1.0,
1.0,
1.0,
1.0,
1.0,
1.0,
(char **)&v260);
v236 = (__int64)KeyframeCommand;
sub_140069730((__int64)&v260);
if ( KeyframeCommand )
{
v50 = KeyframeCommand[55];
v51 = KeyframeCommand[56];
if ( v50 != v51 )
{
v52 = 0.0;
v227 = 0.0;
if ( ((__int64)((unsigned __int128)((v51 - v50) * (__int128)0x4924924924924925LL) >> 64) >> 7)
+ ((unsigned __int64)((unsigned __int128)((v51 - v50) * (__int128)0x4924924924924925LL) >> 64) >> 63)
- 1 )
{
v53 = 0;
do
{
if ( *(double *)(v50 + v53 + 368) > 0.0 )
{
if ( !v38 )
{
v243 = 50;
v38 = (struct cocos2d::CCPoint *)operator new(0x190u);
v237 = v38;
v244 = v38;
v54 = 50;
v55 = v38;
do
{
cocos2d::CCPoint::CCPoint(v55);
v55 = (cocos2d::CCPoint *)((char *)v55 + 8);
--v54;
}
while ( v54 );
}
v56 = 0;
v57 = v38;
do
{
v58 = sub_1406678C0(v50 + v53 + 200);
v59 = sub_1406678C0(v53 + 32 + v50);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v234, v59, v58);
cocos2d::CCPoint::operator+(v53 + 400 + v50, &v238, v60);
cocos2d::CCPoint::operator=(v57, &v238);
++v56;
v57 = (struct cocos2d::CCPoint *)((char *)v57 + 8);
}
while ( v56 < 50 );
Time.time = 0x3F80000000000000LL;
*(_DWORD *)&Time.millitm = 1065353216;
*(_DWORD *)&Time.dstflag = *(_DWORD *)(v50 + v53 + 440);
v8 = v225;
v38 = v237;
v1 = v239;
cocos2d::CCDrawNode::drawLines(
*(cocos2d::CCDrawNode **)(v239 + 14448),
v237,
0x32u,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
KeyframeCommand = (_QWORD *)v236;
v52 = v227;
}
++LODWORD(v52);
v227 = v52;
v53 += 448;
v51 = KeyframeCommand[56];
v50 = KeyframeCommand[55];
}
while ( SLODWORD(v52) < ((__int64)((unsigned __int128)((v51 - v50) * (__int128)0x4924924924924925LL) >> 64) >> 7)
+ ((unsigned __int64)((unsigned __int128)((v51 - v50)
* (__int128)0x4924924924924925LL) >> 64) >> 63)
- 1 );
v42 = v231;
}
v61 = 0;
if ( ((__int64)((unsigned __int128)((v51 - v50) * (__int128)0x4924924924924925LL) >> 64) >> 7)
+ ((unsigned __int64)((unsigned __int128)((v51 - v50) * (__int128)0x4924924924924925LL) >> 64) >> 63)
- 1 )
{
v62 = 0;
do
{
v63 = v50 + v62;
v64 = v62 + 448;
v62 += 448;
if ( !*(_BYTE *)(v63 + 30) )
{
v259 = *(float *)(v50 + v64 + 440);
cocos2d::CCDrawNode::drawSegment(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)(v63 + 400),
(const struct cocos2d::CCPoint *)(v50 + v64 + 400),
v8,
(const struct cocos2d::_ccColor4F *)v258);
}
++v61;
v50 = KeyframeCommand[55];
}
while ( v61 < ((__int64)((unsigned __int128)((KeyframeCommand[56] - v50)
* (__int128)0x4924924924924925LL) >> 64) >> 7)
+ ((unsigned __int64)((unsigned __int128)((KeyframeCommand[56] - v50)
* (__int128)0x4924924924924925LL) >> 64) >> 63)
- 1 );
}
}
v13 = 0;
}
GameVariable = v224;
}
}
GJEffectManager::resetTempGroupCommands(*(_QWORD *)(v1 + 2408));
v41 = v42;
if ( !v42 )
{
if ( v38 )
j_j_free(v38);
goto LABEL_86;
}
v42 = *(_QWORD *)(v42 + 288);
v39 = v257;
v12 = v222;
}
LODWORD(v257) = 0;
LABEL_53:
v44 = 50;
v45 = 255;
goto LABEL_54;
}
}
}
LABEL_86:
cocos2d::CCDrawNode::disableDrawArea(*(cocos2d::CCDrawNode **)(v1 + 14448));
v66 = *(_QWORD *)(v1 + 14904);
if ( byte_140909787 && v66 && (v67 = *(_QWORD *)(v66 + 1568)) != 0 )
{
if ( *(_DWORD *)(v67 + 1256) != 1 && *(__int16 *)(v67 + 1176) <= 0 )
v67 = 0;
}
else
{
v67 = *(_QWORD *)(v1 + 15528);
}
if ( byte_140909785 && v66 && (v68 = *(_QWORD *)(v66 + 1568)) != 0 )
{
if ( *(_DWORD *)(v68 + 1256) != 1 )
v68 = 0;
}
else
{
v68 = *(_QWORD *)(v1 + 15536);
}
if ( v67 )
{
if ( v67 != *(_QWORD *)(v1 + 15680) || *(_DWORD *)(v1 + 15672) < *(_DWORD *)(v1 + 15668) )
{
*(_QWORD *)(v1 + 15680) = v67;
*(_DWORD *)(v1 + 15672) = *(_DWORD *)(v1 + 15668);
sub_140414320(v1 + 15744);
sub_140403620(v67, v1, (void **)(v1 + 15696), 1);
}
sub_140406240(v1, (_QWORD *)(v1 + 15696), v65, *(cocos2d::CCDrawNode **)(v1 + 14448));
}
if ( v68 )
{
if ( v68 != *(_QWORD *)(v1 + 15688) || *(_DWORD *)(v1 + 15676) < *(_DWORD *)(v1 + 15668) )
{
*(_QWORD *)(v1 + 15688) = v68;
*(_DWORD *)(v1 + 15676) = *(_DWORD *)(v1 + 15668);
sub_140414320(v1 + 15744);
sub_140403620(v68, v1, (void **)(v1 + 15720), 0);
}
sub_140406240(v1, (_QWORD *)(v1 + 15720), v65, *(cocos2d::CCDrawNode **)(v1 + 14448));
}
v69 = (__int64)(*(_QWORD *)(v1 + 13984) - *(_QWORD *)(v1 + 13976)) >> 3;
if ( *(_BYTE *)(v1 + 14656) )
{
v70 = *(int *)(v1 + 12652);
LODWORD(v257) = v70;
if ( (int)v70 <= *(_DWORD *)(v1 + 12656) )
{
v71 = v70;
v236 = v70;
v69 = (int)v69;
v238 = (int)v69;
v72 = 0xFFFFFFFFLL;
do
{
if ( v71 >= v69 )
break;
v73 = *(_QWORD **)(*(_QWORD *)(v1 + 13976) + 8 * v71);
if ( v73 )
v74 = (__int64)(v73[1] - *v73) >> 3;
else
LODWORD(v74) = -1;
v75 = *(int *)(v1 + 12660);
v227 = *(float *)&v75;
if ( (int)v75 <= *(_DWORD *)(v1 + 12664) )
{
v76 = v75;
v237 = (struct cocos2d::CCPoint *)v75;
v74 = (int)v74;
v239 = (int)v74;
do
{
if ( v76 >= v74 )
break;
v77 = *(_QWORD **)(**(_QWORD **)(*(_QWORD *)(v1 + 13976) + 8 * v71) + 8 * v76);
if ( v77 )
{
v78 = 0;
v79 = *(int *)(**(_QWORD **)(*(_QWORD *)(v1 + 14144) + 8 * v71) + 4 * v76);
if ( v79 > 0 )
{
while ( 1 )
{
v80 = *(__int16 **)(*v77 + 8 * v78);
if ( (*(unsigned __int8 (__fastcall **)(__int16 *, __int64, __int64, __int64))(*(_QWORD *)v80 + 344LL))(
v80,
v71,
v70,
v72) )
{
v71 = (unsigned int)v80[605];
v81 = v80[606];
if ( !v80[606] )
v81 = -1;
v82 = *(__int16 *)(v1 + 14866);
if ( (*(_WORD *)(v1 + 14866) == 0xFFFF || v82 == (_DWORD)v71 || v82 == v81)
&& ((!v224 || !*((_BYTE *)v80 + 1302)) && (!v222 || !*((_BYTE *)v80 + 1267))
|| *((_BYTE *)v80 + 1141))
&& (*((_DWORD *)v80 + 314) == 1 && *((_BYTE *)v80 + 1488)
|| (*(unsigned int (__fastcall **)(__int16 *, __int64))(*(_QWORD *)v80 + 1648LL))(v80, v71) == 30
&& !*((_BYTE *)v80 + 978))
&& (*(unsigned __int8 (__fastcall **)(__int16 *, __int64))(*(_QWORD *)v80 + 1568LL))(v80, v71)
&& !*((_BYTE *)v80 + 1354) )
{
v83 = (const struct cocos2d::CCRect *)(*(__int64 (__fastcall **)(__int16 *))(*(_QWORD *)v80
+ 1184LL))(v80);
cocos2d::CCRect::CCRect((cocos2d::CCRect *)v258, v83);
v84 = (*(float (__fastcall **)(__int16 *))(*(_QWORD *)v80 + 360LL))(v80);
if ( (int)v84 == 90 * ((int)v84 / 90) )
{
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v232);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v234);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v229);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v231);
cocos2d::CCPoint::operator=(&v232, v258);
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)&v243,
*(float *)&v258[8] + *(float *)v258,
v259 + *(float *)&v258[4]);
cocos2d::CCPoint::operator=(&v229, v87);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v244, v232, v230);
cocos2d::CCPoint::operator=(v234, v88);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v245, v229, v233);
v86 = v89;
}
else
{
*((_BYTE *)v80 + 744) = 1;
(*(void (__fastcall **)(__int16 *))(*(_QWORD *)v80 + 1416LL))(v80);
(*(void (__fastcall **)(__int16 *))(*(_QWORD *)v80 + 1184LL))(v80);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v232);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v234);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v229);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v231);
v85 = (*(__int64 (__fastcall **)(__int16 *))(*(_QWORD *)v80 + 1408LL))(v80);
cocos2d::CCPoint::operator=(&v232, v85 + 320);
cocos2d::CCPoint::operator=(v234, v85 + 328);
cocos2d::CCPoint::operator=(&v229, v85 + 336);
v86 = v85 + 344;
}
cocos2d::CCPoint::operator=(&v231, v86);
if ( v13 >= 1192 )
{
LABEL_145:
v76 = (__int64)v237;
v71 = v236;
break;
}
v90 = *(_QWORD *)(v1 + 14464) + 8LL * v13;
v91 = v13 + 1;
cocos2d::CCPoint::operator=(v90, &v232);
v92 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
cocos2d::CCPoint::operator=(v92, v234);
v93 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
cocos2d::CCPoint::operator=(v93, v234);
v94 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
cocos2d::CCPoint::operator=(v94, &v229);
v95 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
cocos2d::CCPoint::operator=(v95, &v229);
v96 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
cocos2d::CCPoint::operator=(v96, &v231);
v97 = *(_QWORD *)(v1 + 14464) + 8LL * v91++;
v98 = v91;
cocos2d::CCPoint::operator=(v97, &v231);
v13 = v91 + 1;
cocos2d::CCPoint::operator=(*(_QWORD *)(v1 + 14464) + 8 * v98, &v232);
}
}
if ( ++v78 >= v79 )
goto LABEL_145;
}
}
}
++LODWORD(v227);
v237 = (struct cocos2d::CCPoint *)++v76;
v74 = v239;
}
while ( SLODWORD(v227) <= *(_DWORD *)(v1 + 12664) );
LODWORD(v70) = v257;
v72 = 0xFFFFFFFFLL;
}
v70 = (unsigned int)(v70 + 1);
LODWORD(v257) = v70;
v236 = ++v71;
v69 = v238;
}
while ( (int)v70 <= *(_DWORD *)(v1 + 12656) );
if ( v13 > 0 )
{
Time = (struct __timeb64)_mm_load_si128((const __m128i *)&xmmword_140836BD0);
cocos2d::CCDrawNode::drawLines(
*(cocos2d::CCDrawNode **)(v1 + 14448),
*(struct cocos2d::CCPoint **)(v1 + 14464),
v13,
v8,
(const struct cocos2d::_ccColor4F *)&Time);
}
}
}
cocos2d::CCDrawNode::enableDrawArea(*(cocos2d::CCDrawNode **)(v1 + 14448), (struct cocos2d::CCRect *)v240);
v99 = *(_DWORD **)(*(_QWORD *)(v1 + 14904) + 1568LL);
if ( v99 )
{
v100 = v99[259];
if ( v100 == 3602 || ((v100 - 3603) & 0xFFFFFFFD) == 0 )
{
v101 = v99[491];
v102 = v99[370];
if ( v102 > 0 )
{
if ( v102 > 9999 )
v102 = 9999;
v103 = (unsigned int)v102;
v104 = *(cocos2d::CCArray **)(*(_QWORD *)(v1 + 3896) + 8LL * (unsigned int)v102);
if ( v104
|| (v104 = (cocos2d::CCArray *)cocos2d::CCArray::create(9999),
cocos2d::CCDictionary::setObject(*(cocos2d::CCDictionary **)(v1 + 3872), v104, (unsigned int)v103),
(*(_QWORD *)(*(_QWORD *)(v1 + 3896) + 8 * v103) = v104) != 0) )
{
if ( cocos2d::CCArray::count(v104) )
{
v105 = (float)(int)v99[488] * 3.0;
v106 = (float)((float)(int)v99[489] * 3.0) + v105;
v107 = (float)((float)(int)v99[490] * 3.0) + v106;
v108 = v105 > 0.0;
MinX = cocos2d::CCRect::getMinX((cocos2d::CCRect *)v240);
MinY = cocos2d::CCRect::getMinY((cocos2d::CCRect *)v240);
MaxX = cocos2d::CCRect::getMaxX((cocos2d::CCRect *)v240);
MaxY = cocos2d::CCRect::getMaxY((cocos2d::CCRect *)v240);
v113 = 0;
v114 = *((unsigned int **)v104 + 7);
v115 = *v114;
if ( (_DWORD)v115 )
{
v116 = *((_QWORD **)v114 + 2);
v239 = (unsigned __int64)&v116[v115 - 1];
if ( (unsigned __int64)v116 <= v239 )
{
si128 = _mm_load_si128((const __m128i *)&xmmword_140836B20);
v118 = _mm_load_si128((const __m128i *)&xmmword_140836A10);
while ( *v116 )
{
(*(void (__fastcall **)(_QWORD, float *))(*(_QWORD *)*v116 + 1208LL))(*v116, &v227);
if ( v108 )
{
Time = (struct __timeb64)_mm_load_si128((const __m128i *)&xmmword_140836990);
if ( !v101 )
{
v257 = 0;
v119 = cocos2d::CCDrawNode::drawCircle(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)&v227,
v105,
(const struct cocos2d::_ccColor4F *)&v257,
v8,
(const struct cocos2d::_ccColor4F *)&Time,
(int)v105);
LABEL_175:
v113 += v119;
goto LABEL_176;
}
if ( (unsigned int)(v101 - 1) <= 1 )
{
v120 = v227 - v105;
v121 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v245, v227 - v105, MaxY);
v123 = v122;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v243, v120, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v121,
v124,
v123,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v125;
if ( v101 == 1 )
goto LABEL_170;
}
if ( v101 == 3 )
{
LABEL_170:
v126 = v227 + v105;
v127 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v244, v227 + v105, MaxY);
v129 = v128;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v238, v126, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v127,
v130,
v129,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v131;
}
if ( (unsigned int)(v101 - 4) <= 1 )
{
v132 = v228 - v105;
v133 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v236, MaxX, v228 - v105);
v135 = v134;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v237, MinX, v132);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v133,
v136,
v135,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v137;
if ( v101 == 4 )
goto LABEL_174;
}
if ( v101 == 6 )
{
LABEL_174:
v138 = v228 + v105;
v139 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v231, MaxX, v228 + v105);
v141 = v140;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v234, MinX, v138);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v139,
v142,
v141,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
goto LABEL_175;
}
}
LABEL_176:
if ( v106 == v105 )
goto LABEL_188;
Time = (struct __timeb64)v118;
if ( !v101 )
{
v257 = 0;
v143 = cocos2d::CCDrawNode::drawCircle(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)&v227,
v106,
(const struct cocos2d::_ccColor4F *)&v257,
v8,
(const struct cocos2d::_ccColor4F *)&Time,
(int)v106);
LABEL_187:
v113 += v143;
goto LABEL_188;
}
if ( (unsigned int)(v101 - 1) <= 1 )
{
v144 = v227 - v106;
v145 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v232, v227 - v106, MaxY);
v147 = v146;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v229, v144, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(v145, v148, v147, v225, (const struct cocos2d::_ccColor4F *)&Time);
v113 += v149;
if ( v101 == 1 )
goto LABEL_182;
}
if ( v101 == 3 )
{
LABEL_182:
v150 = v227 + v106;
v151 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v246, v227 + v106, MaxY);
v153 = v152;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v247, v150, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(v151, v154, v153, v225, (const struct cocos2d::_ccColor4F *)&Time);
v113 += v155;
}
if ( (unsigned int)(v101 - 4) <= 1 )
{
v156 = v228 - v106;
v157 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v248, MaxX, v228 - v106);
v159 = v158;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v249, MinX, v156);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(v157, v160, v159, v225, (const struct cocos2d::_ccColor4F *)&Time);
v113 += v161;
if ( v101 == 4 )
goto LABEL_186;
}
if ( v101 == 6 )
{
LABEL_186:
v162 = v228 + v106;
v163 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v250, MaxX, v228 + v106);
v165 = v164;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v251, MinX, v162);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(v163, v166, v165, v225, (const struct cocos2d::_ccColor4F *)&Time);
goto LABEL_187;
}
LABEL_188:
if ( v107 != v106 )
{
Time = (struct __timeb64)si128;
if ( v101 )
{
if ( (unsigned int)(v101 - 1) <= 1 )
{
v168 = v227 - v107;
v169 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v252, v227 - v107, MaxY);
v171 = v170;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v253, v168, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v169,
v172,
v171,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v173;
if ( v101 == 1 )
goto LABEL_194;
}
if ( v101 == 3 )
{
LABEL_194:
v174 = v227 + v107;
v175 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v254, v227 + v107, MaxY);
v177 = v176;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v255, v174, MinY);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v175,
v178,
v177,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v179;
}
if ( (unsigned int)(v101 - 4) > 1 )
goto LABEL_197;
v180 = v228 - v107;
v181 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v262, MaxX, v228 - v107);
v183 = v182;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v263, MinX, v180);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v181,
v184,
v183,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
v113 += v185;
if ( v101 != 4 )
{
LABEL_197:
if ( v101 != 6 )
goto LABEL_200;
}
v186 = v228 + v107;
v187 = *(cocos2d::CCDrawNode **)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v260, MaxX, v228 + v107);
v189 = v188;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v258, MinX, v186);
v8 = v225;
cocos2d::CCDrawNode::drawSegment(
v187,
v190,
v189,
v225,
(const struct cocos2d::_ccColor4F *)&Time);
}
else
{
v257 = 0;
v167 = cocos2d::CCDrawNode::drawCircle(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)&v227,
v107,
(const struct cocos2d::_ccColor4F *)&v257,
v8,
(const struct cocos2d::_ccColor4F *)&Time,
(int)v107);
}
v113 += v167;
}
LABEL_200:
if ( v113 <= 100 )
{
++v116;
v108 = v105 > 0.0;
if ( (unsigned __int64)v116 <= v239 )
continue;
}
break;
}
}
}
}
}
}
}
}
cocos2d::CCDrawNode::disableDrawArea(*(cocos2d::CCDrawNode **)(v1 + 14448));
if ( *(_QWORD *)(v1 + 15072) != *(_QWORD *)(v1 + 15080) )
{
v191 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
*(_QWORD *)v258 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(*(__int64 *)v258);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v191 = qword_14090BFD0;
}
if ( !GameManager::getGameVariable(v191, "0152") )
{
v192 = *(_DWORD *)(v1 + 2204);
v226 = v192;
v193 = (__int64)(*(_QWORD *)(v1 + 15080) - *(_QWORD *)(v1 + 15072)) >> 3;
v194 = 0;
if ( (int)v193 - 1 > 0 )
{
v195 = 0;
v196 = _mm_load_si128((const __m128i *)&xmmword_140836A60);
do
{
v197 = v195 + 8;
if ( cocos2d::CCRect::containsPoint(
(cocos2d::CCRect *)v240,
(const struct cocos2d::CCPoint *)(v195 + *(_QWORD *)(v1 + 15072)))
|| cocos2d::CCRect::containsPoint(
(cocos2d::CCRect *)v240,
(const struct cocos2d::CCPoint *)(v197 + *(_QWORD *)(v1 + 15072))) )
{
Time = (struct __timeb64)v196;
if ( v194 == (_DWORD)v193 - 2 && v192 == 1 )
v198 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(v1 + 3512)
+ 200LL))(*(_QWORD *)(v1 + 3512));
else
v198 = (const struct cocos2d::CCPoint *)(v197 + *(_QWORD *)(v1 + 15072));
cocos2d::CCDrawNode::drawSegment(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)(v195 + *(_QWORD *)(v1 + 15072)),
v198,
0.5,
(const struct cocos2d::_ccColor4F *)&Time);
}
++v194;
v195 += 8;
}
while ( v194 < (int)v193 - 1 );
}
v199 = *(_QWORD *)(v1 + 15096);
v200 = *(_QWORD *)(v1 + 15104);
if ( v199 != v200 )
{
v201 = (v200 - v199) / 24;
v239 = v201;
v202 = 0.0;
v227 = 0.0;
v236 = (int)v201;
if ( (int)v201 > 0 )
{
v203 = 0;
v204 = _mm_load_si128((const __m128i *)&xmmword_140836BE0);
do
{
v205 = *(_QWORD *)(v1 + 15096);
if ( !*(_BYTE *)(v1 + 1058) || LODWORD(v202) != (_DWORD)v201 - 1 || (v223 = 1, v192 != 1) )
v223 = 0;
v206 = (__int64)(*(_QWORD *)(v203 + v205 + 8) - *(_QWORD *)(v203 + v205)) >> 3;
LODWORD(v257) = v206 - 1;
v207 = 0;
if ( (int)v206 - 1 > 0 )
{
v208 = 0;
do
{
v209 = v208 + 8;
if ( cocos2d::CCRect::containsPoint(
(cocos2d::CCRect *)v240,
(const struct cocos2d::CCPoint *)(v208 + *(_QWORD *)(v203 + v205)))
|| cocos2d::CCRect::containsPoint(
(cocos2d::CCRect *)v240,
(const struct cocos2d::CCPoint *)(v209 + *(_QWORD *)(v203 + v205))) )
{
v260 = v204;
if ( v223 && v207 == (_DWORD)v206 - 2 )
v210 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(v1 + 3520)
+ 200LL))(*(_QWORD *)(v1 + 3520));
else
v210 = (const struct cocos2d::CCPoint *)(v209 + *(_QWORD *)(v203 + v205));
cocos2d::CCDrawNode::drawSegment(
*(cocos2d::CCDrawNode **)(v1 + 14448),
(const struct cocos2d::CCPoint *)(v208 + *(_QWORD *)(v203 + v205)),
v210,
0.5,
(const struct cocos2d::_ccColor4F *)&v260);
}
++v207;
v208 += 8;
}
while ( v207 < (int)v257 );
v202 = v227;
LODWORD(v201) = v239;
}
++LODWORD(v202);
v227 = v202;
v203 += 24;
v211 = v236-- == 1;
v192 = v226;
}
while ( !v211 );
}
}
}
}
if ( *(_QWORD *)(v1 + 15120) != *(_QWORD *)(v1 + 15128) )
{
v212 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
*(_QWORD *)v258 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager(*(__int64 *)v258);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v212 = qword_14090BFD0;
}
if ( GameManager::getGameVariable(v212, "0149") )
{
v213 = *(const struct cocos2d::CCPoint **)(v1 + 15128);
v214 = *(const struct cocos2d::CCPoint **)(v1 + 15120);
if ( v214 != v213 )
{
v215 = _mm_load_si128((const __m128i *)&xmmword_1408369D0);
do
{
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v231, v214);
if ( cocos2d::CCRect::containsPoint((cocos2d::CCRect *)v240, (const struct cocos2d::CCPoint *)&v231) )
{
Time = 0;
v263 = v215;
v216 = *((float *)&v231 + 1) - 2.0;
v217 = *(float *)&v231 - 2.0;
v218 = *(_QWORD *)(v1 + 14448);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v258, *(float *)&v231 + 2.0, *((float *)&v231 + 1) + 2.0);
v220 = v219;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v260, v217, v216);
cocos2d::CCDrawNode::drawRect(v218, v221, v220, &v263, 0, &Time, 0);
}
v214 = (const struct cocos2d::CCPoint *)((char *)v214 + 8);
}
while ( v214 != v213 );
}
}
}
}