//
// EnhancedGameObject::updateSyncedAnimation from 0x1401a7db0 to 0x1401a993a (7050 bytes)
//
// 40 xrefs:
// > SpecialAnimGameObject::updateSyncedAnimation @ 0x1401a994f
// > ??> @ 0x14055e868
// > ??> @ 0x14060eb00
// > ??> @ 0x14060f338
// > ??> @ 0x14060f9e0
// > ??> @ 0x1406100b0
// > ??> @ 0x140610eb0
// > ??> @ 0x140611710
// > ??> @ 0x140612630
// > ??> @ 0x140612cd8
// > ??> @ 0x140613380
// > ??> @ 0x140613af0
// > ??> @ 0x140614198
// > ??> @ 0x140614980
// > ??> @ 0x1406151b8
// > ??> @ 0x140615900
// > ??> @ 0x140615fa8
// > ??> @ 0x1406166f0
// > ??> @ 0x140616eb0
// > ??> @ 0x140617558
// > ??> @ 0x140617c00
// > ??> @ 0x140618370
// > ??> @ 0x140618a18
// > ??> @ 0x140619160
// > ??> @ 0x140619c00
// > ??> @ 0x14061a2a8
// > ??> @ 0x14061a950
// > ??> @ 0x14061b070
// > ??> @ 0x14061b718
// > ??> @ 0x14061be60
// > ??> @ 0x14061c5f8
// > ??> @ 0x14061cca0
// > ??> @ 0x14061d348
// > ??> @ 0x14061d9f0
// > ??> @ 0x14061e098
// > ??> @ 0x14061e740
// > ??> @ 0x14061ede8
// > ??> @ 0x14061f5f8
// > ??> @ 0x14061fd90
// > ??> @ 0x1406cc138
//
// 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
//
// Hidden C++ exception states: #wind=25
void EnhancedGameObject::updateSyncedAnimation(EnhancedGameObject *a1, float a2, int a3)
{
bool m_animateOnTrigger; // di
bool v6; // r14
float v7; // xmm8_4
char v8; // bl
float m_unk544; // xmm2_4
float m_animationStart; // xmm3_4
char v11; // r15
int m_frames; // r13d
float v13; // xmm0_4
int v14; // eax
int m_singleFrame; // ecx
unsigned int v16; // edi
cocos2d::CCSprite *v17; // rcx
int m_objectID; // r13d
__int64 v19; // rcx
__int64 v20; // rcx
__int64 v21; // rcx
const char *v22; // r14
EnhancedGameObject_vtbl *v23; // rbx
cocos2d::CCSpriteFrameCache *v24; // rax
struct cocos2d::CCSpriteFrame *v25; // rax
__int64 *v26; // rax
__int64 v27; // rdx
__int64 v28; // rdx
const char *v29; // rdi
cocos2d::CCSprite *m_colorSprite; // rcx
cocos2d::CCNode_vtbl *v31; // rbx
cocos2d::CCSpriteFrameCache *v32; // rax
struct cocos2d::CCSpriteFrame *v33; // rax
cocos2d::CCSprite *v34; // rcx
const char *v35; // r12
cocos2d::CCNode *v36; // rax
cocos2d::CCNode *v37; // r14
cocos2d::CCNode_vtbl *v38; // rbx
cocos2d::CCSpriteFrameCache *v39; // rax
struct cocos2d::CCSpriteFrame *v40; // rax
const char *v41; // r14
EnhancedGameObject_vtbl *v42; // rbx
cocos2d::CCSpriteFrameCache *v43; // rax
struct cocos2d::CCSpriteFrame *v44; // rax
__int64 v45; // rcx
cocos2d::CCSprite *v46; // r15
bool v47; // r12
__int64 v48; // rcx
const char *v49; // rdi
cocos2d::CCSprite_vtbl *v50; // rbx
cocos2d::CCSpriteFrameCache *v51; // rax
struct cocos2d::CCSpriteFrame *v52; // rax
__int64 v53; // rcx
const char *v54; // r14
cocos2d::CCNode *v55; // rax
__int64 v56; // rcx
cocos2d::CCNode *v57; // r15
cocos2d::CCNode_vtbl *v58; // rbx
cocos2d::CCSpriteFrameCache *v59; // rax
struct cocos2d::CCSpriteFrame *v60; // rax
__int64 v61; // rax
cocos2d::CCSprite *v62; // rbx
__int64 v63; // rcx
const char *v64; // r14
cocos2d::CCSprite_vtbl *v65; // rbx
cocos2d::CCSpriteFrameCache *v66; // rax
struct cocos2d::CCSpriteFrame *v67; // rax
cocos2d::CCSprite_vtbl *v68; // rbx
const cocos2d::CCPoint *v69; // rax
cocos2d::CCNode *v70; // rax
__int64 v71; // rcx
__int64 *v72; // r14
unsigned int v73; // edi
unsigned int v74; // edi
unsigned int v75; // edi
const char *v76; // rdi
cocos2d::CCNode_vtbl *v77; // rbx
cocos2d::CCSpriteFrameCache *v78; // rax
struct cocos2d::CCSpriteFrame *v79; // rax
const struct cocos2d::CCSize *v80; // rax
double v81; // xmm0_8
__int64 v82; // rbx
__int64 v83; // rax
float v84; // xmm7_4
int v85; // r15d
int m_unkAnimationInt; // r14d
__int64 v87; // rcx
unsigned int v88; // edi
int m_maybeAnimationVariableXInt; // eax
__int64 v90; // rdx
__int64 v91; // rcx
const char *v92; // r14
EnhancedGameObject_vtbl *v93; // rbx
cocos2d::CCSpriteFrameCache *v94; // rax
struct cocos2d::CCSpriteFrame *v95; // rax
cocos2d::CCSprite **p_m_colorSprite; // r14
int v97; // eax
__int64 v98; // rax
__int64 v99; // rcx
cocos2d::CCSprite **v100; // r15
__int64 v101; // rdx
const char *v102; // rdi
cocos2d::CCSprite_vtbl *v103; // rbx
cocos2d::CCSpriteFrameCache *v104; // rax
struct cocos2d::CCSpriteFrame *v105; // rax
const struct cocos2d::CCSize *v106; // rax
double v107; // xmm0_8
cocos2d::CCSprite_vtbl *v108; // rbx
const cocos2d::CCPoint *v109; // rax
__int64 v110; // rcx
const char *v111; // r14
EnhancedGameObject_vtbl *v112; // rbx
cocos2d::CCSpriteFrameCache *v113; // rax
struct cocos2d::CCSpriteFrame *v114; // rax
cocos2d::CCSprite *v115; // rcx
__int64 v116; // rcx
cocos2d::CCSprite *v117; // r14
__int64 v118; // rcx
const char *v119; // rdi
cocos2d::CCSpriteFrameCache *v120; // rax
__int64 v121; // rcx
float v122; // xmm0_4
const char *v123; // r14
EnhancedGameObject_vtbl *v124; // rbx
cocos2d::CCSpriteFrameCache *v125; // rax
struct cocos2d::CCSpriteFrame *v126; // rax
float m_randomFrameTime; // xmm1_4
float m_animationSpeed; // xmm0_4
int v129; // ebx
int v130; // ecx
int v131; // r9d
int v132; // r15d
cocos2d::CCArray *m_pChildren; // rdi
cocos2d::ccArray *data; // rdi
__int64 num; // rax
cocos2d::CCObject **arr; // rdi
cocos2d::CCObject **i; // r14
cocos2d::CCObject *v138; // rbx
__int64 v139; // rcx
const char *v140; // r14
EnhancedGameObject_vtbl *v141; // rbx
cocos2d::CCSpriteFrameCache *v142; // rax
struct cocos2d::CCSpriteFrame *v143; // rax
const char *v144; // r15
cocos2d::CCNode *v145; // rax
__int64 v146; // rcx
cocos2d::CCNode *v147; // r13
cocos2d::CCNode_vtbl *v148; // rbx
cocos2d::CCSpriteFrameCache *v149; // rax
struct cocos2d::CCSpriteFrame *v150; // rax
cocos2d::CCSprite **v151; // r15
cocos2d::CCSprite **v152; // r13
const char *v153; // rdi
cocos2d::CCSprite **v154; // rdx
cocos2d::CCSprite_vtbl *v155; // rbx
cocos2d::CCSpriteFrameCache *v156; // rax
struct cocos2d::CCSpriteFrame *v157; // rax
cocos2d::CCSprite **v158; // r15
cocos2d::CCNode *v159; // rax
const char *v160; // rdi
const char *v161; // r12
const char *v162; // r15
EnhancedGameObject_vtbl *v163; // rbx
cocos2d::CCSpriteFrameCache *v164; // rax
struct cocos2d::CCSpriteFrame *v165; // rax
cocos2d::CCNode *v166; // rax
__int64 v167; // rcx
cocos2d::CCNode *v168; // rdi
cocos2d::CCNode_vtbl *v169; // rbx
cocos2d::CCSpriteFrameCache *v170; // rax
struct cocos2d::CCSpriteFrame *v171; // rax
cocos2d::CCNode *v172; // rax
__int64 v173; // rcx
cocos2d::CCSprite *v174; // rdi
cocos2d::CCSpriteFrameCache *v175; // rax
__int64 v176; // rcx
cocos2d::CCSprite *v177; // r13
bool v178; // r12
__int64 v179; // rcx
const char *v180; // r14
cocos2d::CCSprite_vtbl *v181; // rbx
cocos2d::CCSpriteFrameCache *v182; // rax
struct cocos2d::CCSpriteFrame *v183; // rax
cocos2d::CCSprite *v184; // rcx
__int64 v185; // rcx
cocos2d::CCSprite *v186; // r14
__int64 v187; // rcx
const char *v188; // rdi
cocos2d::CCSprite_vtbl *v189; // rbx
cocos2d::CCSpriteFrameCache *v190; // rax
struct cocos2d::CCSpriteFrame *v191; // rax
float v192; // xmm1_4
float v193; // xmm0_4
float v194; // xmm2_4
__int64 v195; // rcx
int v196; // r12d
int v197; // edi
int v198; // ebx
__int64 v199; // rcx
const char *v200; // r13
const char *v201; // rdi
cocos2d::CCNode *v202; // r14
cocos2d::CCArray *v203; // rax
struct cocos2d::CCObject *v204; // r15
cocos2d::CCNode_vtbl *v205; // rbx
__int64 v206; // rcx
cocos2d::CCSpriteFrameCache *v207; // rax
struct cocos2d::CCSpriteFrame *v208; // rax
cocos2d::CCObject_vtbl *v209; // rbx
__int64 v210; // rcx
cocos2d::CCSpriteFrameCache *v211; // rax
struct cocos2d::CCSpriteFrame *v212; // rax
__int64 v213; // rcx
const char *v214; // r14
EnhancedGameObject_vtbl *v215; // rbx
cocos2d::CCSpriteFrameCache *v216; // rax
struct cocos2d::CCSpriteFrame *v217; // rax
const char *v218; // r14
cocos2d::CCArray *v219; // rax
struct cocos2d::CCObject *v220; // rbx
cocos2d::CCObject_vtbl *v221; // rdi
__int64 v222; // rcx
cocos2d::CCSpriteFrameCache *v223; // rax
struct cocos2d::CCSpriteFrame *v224; // rax
int v225; // [rsp+28h] [rbp-59h]
cocos2d::CCSize v226; // [rsp+30h] [rbp-51h] BYREF
cocos2d::CCSize v227; // [rsp+38h] [rbp-49h] BYREF
__int128 v228; // [rsp+40h] [rbp-41h]
char v229; // [rsp+E8h] [rbp+67h]
int v230; // [rsp+100h] [rbp+7Fh]
m_animateOnTrigger = a1->m_animateOnTrigger;
if ( m_animateOnTrigger )
{
if ( !a1->m_animationTriggered )
return;
if ( *(float *)&a1->m_animationRandomizedStartValue == 0.0 )
*(float *)&a1->m_animationRandomizedStartValue = -a2;
}
v6 = a1->m_animationShouldUseSpeed && a1->m_animationSpeed < 0.0;
v7 = a2 + *(float *)&a1->m_animationRandomizedStartValue;
v8 = 0;
if ( a1->m_visible )
{
m_unk544 = a1->m_unk544;
v7 = v7 + m_unk544;
m_animationStart = a1->m_animationStart;
if ( m_animationStart > 0.0 )
{
if ( (float)(v7 - (float)(m_animationStart + a1->m_unk540)) >= 0.0 )
{
a1->m_unk544 = m_unk544 - m_animationStart;
v7 = v7 - m_animationStart;
a1->m_animationStart = 0.0;
}
else
{
v8 = 1;
}
}
goto LABEL_13;
}
if ( m_animateOnTrigger )
{
LABEL_13:
v11 = 1;
m_frames = a1->m_frames + 1;
goto LABEL_14;
}
v11 = 0;
m_frames = a1->m_frames;
LABEL_14:
v225 = m_frames;
v13 = floorf(v7 / a1->m_frameTime);
v14 = (int)fmaxf(0.0, v13);
m_singleFrame = a1->m_singleFrame;
if ( m_singleFrame > 0 )
{
if ( a1->m_animationOffset )
{
v14 += m_singleFrame;
}
else if ( !m_animateOnTrigger )
{
v14 = m_singleFrame - 1;
}
}
v16 = v14 % m_frames + 1;
if ( v6 )
v16 = m_frames - v14 % m_frames;
if ( a3 > 0 )
v16 = a3;
v230 = v16;
if ( (v16 != a1->m_maybeAnimationVariableXInt && !v8 || a1->m_usesSpecialAnimation)
&& (a1->m_blackChildOpacityLocked
|| a1->_realOpacity
|| (v17 = a1->m_colorSprite) != nullptr && v17->getOpacity(&v17->cocos2d::CCRGBAProtocol)
|| a1->m_isDisabled2
|| a1->m_maybeAnimationVariableXInt <= 0) )
{
v229 = 0;
if ( v11 && v16 == a1->m_frames + 1 )
{
v16 = a1->m_frames;
v229 = 1;
}
m_objectID = a1->m_objectID;
v19 = (unsigned int)m_objectID;
if ( m_objectID <= 2020 )
{
if ( m_objectID == 2020 )
goto LABEL_340;
if ( m_objectID <= 1591 )
{
if ( m_objectID != 1591 )
{
if ( m_objectID > 1050 )
{
if ( m_objectID != 1051 && m_objectID != 1052 )
{
v20 = (unsigned int)(m_objectID - 1329);
if ( m_objectID != 1329 )
{
v19 = (unsigned int)(m_objectID - 1516);
if ( m_objectID == 1516 || m_objectID == 1518 )
{
if ( !qword_1406C2ED8 )
{
v227 = (cocos2d::CCSize)operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(*(_QWORD *)&v227);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v35 = (const char *)sub_1401AEC80(v19, (unsigned int)a1->m_objectID, v16);
if ( v35 )
{
v36 = a1->getChildByTag(a1, 1);
v37 = v36;
if ( v36 )
{
v38 = v36->__vftable;
v39 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v21);
v40 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v39, v35);
((void (__fastcall *)(cocos2d::CCNode *, struct cocos2d::CCSpriteFrame *))v38[1].setScaleX)(
v37,
v40);
}
}
if ( !a1->m_colorSprite )
goto LABEL_60;
if ( qword_1406C2ED8 )
goto LABEL_56;
v227 = (cocos2d::CCSize)operator new(0x668u);
v26 = (__int64 *)sub_14017AB00(*(_QWORD *)&v227);
goto LABEL_55;
}
goto LABEL_48;
}
goto LABEL_77;
}
}
else if ( m_objectID != 1050 )
{
v20 = (unsigned int)(m_objectID - 142);
if ( m_objectID != 142 )
{
v19 = (unsigned int)(m_objectID - 920);
if ( m_objectID != 920 )
{
v19 = (unsigned int)(m_objectID - 921);
if ( m_objectID != 921 )
{
v19 = (unsigned int)(m_objectID - 923);
if ( (unsigned int)v19 >= 2 )
{
LABEL_48:
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v22 = (const char *)sub_1401AEC80(v19, (unsigned int)a1->m_objectID, v16);
if ( v22 )
{
v23 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v24 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v21);
v25 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v24, v22);
v23->setDisplayFrame(a1, v25);
}
if ( !a1->m_colorSprite )
goto LABEL_60;
if ( qword_1406C2ED8 )
goto LABEL_56;
LABEL_54:
*(_QWORD *)&v228 = operator new(0x668u);
v26 = (__int64 *)sub_14017AB00(v228);
LABEL_55:
v27 = *v26;
qword_1406C2ED8 = (__int64)v26;
(*(void (__fastcall **)(__int64 *))(v27 + 72))(v26);
LABEL_56:
v28 = (unsigned int)a1->m_objectID;
LABEL_57:
v29 = (const char *)sub_1401AED00(v21, v28, v16);
if ( !v29 )
{
LABEL_60:
a1->m_maybeAnimationVariableXInt = v230;
if ( a1->m_visible )
{
if ( v229 )
{
a1->m_animationStart = (float)((float)((float)rand() / 32767.0) * 0.5) + 0.2;
a1->m_unk540 = v7;
if ( !a1->m_shouldNotHideAnimFreeze )
a1->m_isDisabled2 = 1;
}
else if ( !a1->m_shouldNotHideAnimFreeze )
{
a1->m_isDisabled2 = 0;
}
}
if ( a1->m_animateOnTrigger
&& a1->m_animationTriggered
&& a1->m_maybeAnimationVariableXInt == v225 )
{
a1->m_animationTriggered = 0;
*(_QWORD *)&a1->m_unk540 = 0;
*(_QWORD *)&a1->m_animationRandomizedStartValue = 0;
a1->m_isDisabled2 = 1;
a1->setOpacity(&a1->cocos2d::CCRGBAProtocol, 0);
}
return;
}
m_colorSprite = a1->m_colorSprite;
v31 = (cocos2d::CCNode_vtbl *)m_colorSprite->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v32 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(m_colorSprite);
v33 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v32, v29);
v34 = a1->m_colorSprite;
LABEL_59:
((void (__fastcall *)(cocos2d::CCSprite *, struct cocos2d::CCSpriteFrame *))v31[1].setScaleX)(
v34,
v33);
goto LABEL_60;
}
}
}
LABEL_340:
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v214 = (const char *)sub_1401AEC80(v19, (unsigned int)a1->m_objectID, v16);
if ( v214 )
{
v215 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v216 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v213);
v217 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v216, v214);
v215->setDisplayFrame(a1, v217);
}
if ( a1->m_colorSprite )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v218 = (const char *)sub_1401AED00(v213, (unsigned int)a1->m_objectID, v16);
if ( v218 )
{
v219 = a1->m_colorSprite->getChildren(a1->m_colorSprite);
v220 = cocos2d::CCArray::objectAtIndex(v219, 0);
v221 = v220->__vftable;
v223 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v222);
v224 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v223, v218);
((void (__fastcall *)(struct cocos2d::CCObject *, struct cocos2d::CCSpriteFrame *))v221[13].getTag)(
v220,
v224);
}
}
goto LABEL_60;
}
LABEL_77:
if ( a1->m_hasUniqueCoin )
m_objectID = -m_objectID;
if ( !qword_1406C2ED8 )
{
v227 = (cocos2d::CCSize)operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(*(_QWORD *)&v227);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v41 = (const char *)sub_1401AEC80(v20, (unsigned int)m_objectID, v16);
if ( v41 )
{
v42 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v43 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v21);
v44 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v43, v41);
v42->setDisplayFrame(a1, v44);
}
if ( !a1->m_colorSprite )
goto LABEL_60;
if ( !qword_1406C2ED8 )
{
v227 = (cocos2d::CCSize)operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(*(_QWORD *)&v227);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v28 = (unsigned int)m_objectID;
goto LABEL_57;
}
v46 = (cocos2d::CCSprite *)a1->getChildByTag(a1, 1);
if ( !v46 )
goto LABEL_60;
v47 = 1;
if ( a1->m_objectID == 1050 )
{
v45 = v16 - 4;
if ( v16 != 4 )
{
v45 = v16 - 5;
if ( v16 != 5 )
{
v45 = v16 - 9;
if ( v16 == 9 )
{
v16 = 8;
}
else if ( v16 == 10 )
{
v16 = 7;
}
else
{
v47 = 0;
}
goto LABEL_106;
}
goto LABEL_104;
}
}
else
{
if ( (unsigned int)(a1->m_objectID - 1051) > 1 )
{
LABEL_106:
if ( !qword_1406C2ED8 )
{
v227 = (cocos2d::CCSize)operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(*(_QWORD *)&v227);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v49 = (const char *)sub_1401AEC80(v45, (unsigned int)a1->m_objectID, v16);
if ( v49 )
{
v50 = v46->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v51 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v48);
v52 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v51, v49);
v50->setDisplayFrame(v46, v52);
}
cocos2d::CCSprite::setFlipX(v46, v47);
goto LABEL_60;
}
v45 = v16 - 7;
if ( v16 == 7 )
{
v16 = 5;
goto LABEL_106;
}
v45 = v16 - 8;
if ( v16 == 8 )
{
v16 = 4;
goto LABEL_106;
}
v45 = v16 - 9;
if ( v16 != 9 )
{
if ( v16 != 10 )
{
v47 = 0;
goto LABEL_106;
}
LABEL_104:
v16 = 2;
goto LABEL_106;
}
}
v16 = 3;
goto LABEL_106;
}
LABEL_149:
v84 = 1.0;
v85 = 1;
if ( m_objectID == 1593 )
a1->m_unkAnimationInt = 1;
m_unkAnimationInt = a1->m_unkAnimationInt;
if ( m_unkAnimationInt )
{
LABEL_159:
if ( m_unkAnimationInt == 1 )
{
v84 = 0.13;
}
else
{
if ( m_unkAnimationInt != 2 )
{
if ( m_unkAnimationInt == 3 )
{
v84 = 0.12;
v85 = 6;
}
LABEL_166:
v88 = (int)floorf(v7 / v84) % v85 + 1;
m_maybeAnimationVariableXInt = a1->m_maybeAnimationVariableXInt;
if ( v88 != m_maybeAnimationVariableXInt )
{
if ( m_maybeAnimationVariableXInt >= v85 && a1->m_objectID != 1593 )
{
a1->m_unkAnimationInt = 0;
return;
}
a1->m_maybeAnimationVariableXInt = v88;
if ( m_unkAnimationInt == 2 )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v90 = 2059;
}
else if ( m_unkAnimationInt == 3 )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v90 = 2060;
}
else
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v90 = 2058;
}
v92 = (const char *)sub_1401AEC80(v87, v90, v88);
if ( v92 )
{
v93 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v94 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v91);
v95 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v94, v92);
v93->setDisplayFrame(a1, v95);
}
p_m_colorSprite = &a1->m_colorSprite;
if ( a1->m_colorSprite )
{
v97 = a1->m_unkAnimationInt;
if ( v97 == 2 )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v98 = sub_1401AED00(v91, 2059, v88);
v100 = &a1->m_colorSprite;
}
else
{
v100 = &a1->m_colorSprite;
if ( v97 == 3 )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v100 = &a1->m_colorSprite;
}
v101 = 2060;
}
else
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v100 = &a1->m_colorSprite;
}
v101 = 2058;
}
v98 = sub_1401AED00(v91, v101, v88);
}
v102 = (const char *)v98;
v103 = (*p_m_colorSprite)->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v104 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v99);
v105 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v104, v102);
v103->setDisplayFrame(*p_m_colorSprite, v105);
if ( a1->m_colorSpriteLocked )
{
v106 = a1->getContentSize(a1);
v107 = cocos2d::CCSize::CCSize(&v227, v106);
v108 = (*v100)->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
cocos2d::CCPoint::CCPoint(*(float *)&v107, v227.width * 0.5);
v108->setPosition_0(*v100, v109);
}
}
}
goto LABEL_60;
}
v84 = 0.12;
}
v85 = 8;
goto LABEL_166;
}
if ( m_objectID != 1593 )
{
if ( (float)((float)rand() / 32767.0) > 0.69999999 )
{
m_unkAnimationInt = 2;
a1->m_unkAnimationInt = 2;
LABEL_158:
*(float *)&a1->m_animationRandomizedStartValue = -a2;
a1->m_maybeAnimationVariableXInt = -1;
v7 = 0.0;
goto LABEL_159;
}
if ( (float)((float)rand() / 32767.0) > 0.69999999 )
{
a1->m_unkAnimationInt = 3;
m_unkAnimationInt = 3;
goto LABEL_158;
}
}
m_unkAnimationInt = 1;
a1->m_unkAnimationInt = 1;
goto LABEL_158;
}
if ( m_objectID > 1697 )
{
v19 = (unsigned int)(m_objectID - 1839);
switch ( m_objectID )
{
case 1839:
case 1840:
case 1841:
case 1842:
m_randomFrameTime = a1->m_randomFrameTime;
if ( a1->m_animationShouldUseSpeed )
{
m_animationSpeed = a1->m_animationSpeed;
if ( m_animationSpeed != 0.0 )
m_randomFrameTime = fabs(m_animationSpeed);
}
v129 = (int)(float)(40.0 / m_randomFrameTime);
v130 = (int)floorf(v7 / (float)(0.02 / m_randomFrameTime)) % v129 + 1;
if ( v6 )
v130 = v129 - v130 + 1;
if ( v130 != a1->m_maybeAnimationVariableXInt )
{
if ( a1->m_animationStart == -1.0 )
{
a1->m_maybeAnimationVariableXInt = v129;
v131 = 0;
}
else
{
a1->m_maybeAnimationVariableXInt = v130;
if ( v130 == v129 )
{
v131 = 0;
}
else
{
v131 = 255;
if ( v130 >= v129 / 3 )
v131 = (v129 / 3 - v130) * (255 / (v129 - v129 / 3)) + 255;
}
}
v132 = (int)(float)((float)((float)a1->_realOpacity / 255.0) * (float)v131);
m_pChildren = a1->m_pChildren;
if ( m_pChildren )
{
data = m_pChildren->data;
num = data->num;
if ( (_DWORD)num )
{
arr = data->arr;
for ( i = &arr[num - 1]; arr <= i; ++arr )
{
v138 = *arr;
if ( !*arr )
break;
((void (__fastcall *)(cocos2d::CCObject *))v138->__vftable[2].isEqual)(*arr);
(*(void (__fastcall **)(int *, _QWORD))(*(_QWORD *)&v138[5].m_unknown2 + 40LL))(
&v138[5].m_unknown2,
(unsigned __int8)v132);
}
}
}
}
goto LABEL_60;
case 1855:
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v140 = (const char *)sub_1401AEC80(v19, (unsigned int)a1->m_objectID, v16);
if ( v140 )
{
v141 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v142 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v139);
v143 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v142, v140);
v141->setDisplayFrame(a1, v143);
}
v144 = "gj_drops05_2_001.png";
switch ( v230 )
{
case 8:
v144 = "gj_drops05_2_008.png";
break;
case 9:
v144 = "gj_drops05_2_009.png";
break;
case 10:
v144 = "gj_drops05_2_010.png";
break;
case 11:
v144 = "gj_drops05_2_011.png";
break;
case 12:
v144 = "gj_drops05_2_012.png";
break;
case 13:
v144 = "gj_drops05_2_013.png";
break;
case 14:
v144 = "gj_drops05_2_014.png";
break;
case 15:
v144 = "gj_drops05_2_015.png";
break;
case 16:
v144 = "gj_drops05_2_016.png";
break;
default:
break;
}
v145 = a1->getChildByTag(a1, 2);
v147 = v145;
if ( v145 )
{
v148 = v145->__vftable;
v149 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v146);
v150 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v149, v144);
((void (__fastcall *)(cocos2d::CCNode *, struct cocos2d::CCSpriteFrame *))v148[1].setScaleX)(v147, v150);
}
v151 = &a1->m_colorSprite;
if ( !a1->m_colorSprite )
goto LABEL_60;
v152 = &a1->m_colorSprite;
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v152 = &a1->m_colorSprite;
}
v153 = (const char *)sub_1401AED00(v146, (unsigned int)a1->m_objectID, v16);
v154 = &a1->m_colorSprite;
if ( v153 )
{
v155 = (*v151)->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v156 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(*v151);
v157 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v156, v153);
v155->setDisplayFrame(*v151, v157);
v154 = v152;
}
v119 = "gj_drops05_2_color_001.png";
v158 = v154;
switch ( v230 )
{
case 8:
v119 = "gj_drops05_2_color_008.png";
break;
case 9:
v119 = "gj_drops05_2_color_009.png";
break;
case 10:
v119 = "gj_drops05_2_color_010.png";
break;
case 11:
v119 = "gj_drops05_2_color_011.png";
break;
case 12:
v119 = "gj_drops05_2_color_012.png";
break;
case 13:
v119 = "gj_drops05_2_color_013.png";
break;
case 14:
v119 = "gj_drops05_2_color_014.png";
break;
case 15:
v119 = "gj_drops05_2_color_015.png";
break;
case 16:
v119 = "gj_drops05_2_color_016.png";
break;
default:
v158 = &a1->m_colorSprite;
break;
}
v159 = (*v158)->getChildByTag(*v158, 2);
v117 = (cocos2d::CCSprite *)v159;
if ( !v159 )
goto LABEL_60;
v31 = v159->__vftable;
break;
case 1858:
switch ( v16 )
{
case 1u:
v160 = "gj_drops06_001.png";
v161 = "gj_drops06_2_001.png";
v162 = "gj_drops06_3_001.png";
goto LABEL_284;
case 2u:
v160 = "gj_drops06_002.png";
v161 = "gj_drops06_2_002.png";
v162 = "gj_drops06_3_002.png";
goto LABEL_284;
case 3u:
v160 = "gj_drops06_003.png";
v161 = "gj_drops06_2_003.png";
v162 = "gj_drops06_3_003.png";
goto LABEL_284;
case 4u:
v160 = "gj_drops06_004.png";
v161 = "gj_drops06_2_004.png";
v162 = "gj_drops06_3_004.png";
goto LABEL_284;
case 5u:
v160 = "gj_drops06_005.png";
v161 = "gj_drops06_2_005.png";
v162 = "gj_drops06_3_005.png";
goto LABEL_284;
case 6u:
v160 = "gj_drops06_006.png";
v161 = "gj_drops06_2_006.png";
v162 = "gj_drops06_3_006.png";
goto LABEL_284;
case 7u:
v160 = "gj_drops06_007.png";
v161 = "gj_drops06_2_007.png";
v162 = "gj_drops06_3_007.png";
goto LABEL_284;
case 8u:
v160 = "gj_drops06_008.png";
v161 = "gj_drops06_2_008.png";
v162 = "gj_drops06_3_008.png";
LABEL_284:
v163 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v164 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v19);
v165 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v164, v160);
v163->setDisplayFrame(a1, v165);
v166 = a1->getChildByTag(a1, 2);
v168 = v166;
if ( v166 )
{
v169 = v166->__vftable;
v170 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v167);
v171 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v170, v161);
((void (__fastcall *)(cocos2d::CCNode *, struct cocos2d::CCSpriteFrame *))v169[1].setScaleX)(
v168,
v171);
}
v172 = a1->getChildByTag(a1, 3);
v174 = (cocos2d::CCSprite *)v172;
if ( !v172 )
goto LABEL_60;
v31 = v172->__vftable;
v175 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v173);
v33 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v175, v162);
v34 = v174;
break;
default:
goto LABEL_60;
}
goto LABEL_59;
case 1936:
case 1937:
case 1938:
case 1939:
goto LABEL_340;
default:
goto LABEL_48;
}
}
else
{
if ( m_objectID == 1697 )
{
v122 = (float)rand() / 32767.0;
if ( v122 <= 0.69999999 )
v16 = (v122 > 0.34999999) + 1;
else
v16 = 3;
if ( a1->m_maybeAnimationVariableYInt == v16 )
v16 = (v16 == 1) + 1;
a1->m_maybeAnimationVariableYInt = v16;
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v123 = (const char *)sub_1401AEC80(v121, (unsigned int)a1->m_objectID, v16);
if ( v123 )
{
v124 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v125 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v21);
v126 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v125, v123);
v124->setDisplayFrame(a1, v126);
}
if ( !a1->m_colorSprite )
goto LABEL_60;
if ( qword_1406C2ED8 )
goto LABEL_56;
goto LABEL_54;
}
v53 = (unsigned int)(m_objectID - 1592);
if ( m_objectID != 1592 )
{
v19 = (unsigned int)(m_objectID - 1593);
if ( m_objectID == 1593 )
goto LABEL_149;
if ( m_objectID != 1614 )
goto LABEL_48;
cocos2d::CCSize::CCSize(&v226);
v54 = nullptr;
switch ( v16 )
{
case 1u:
v54 = "smallCoin_01_001.png";
break;
case 2u:
v54 = "smallCoin_02_001.png";
break;
case 3u:
v54 = "smallCoin_03_001.png";
break;
case 4u:
v54 = "smallCoin_04_001.png";
break;
}
v55 = a1->getChildByTag(a1, 1);
v57 = v55;
if ( v55 && v54 )
{
v58 = v55->__vftable;
v59 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v56);
v60 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v59, v54);
((void (__fastcall *)(cocos2d::CCNode *, struct cocos2d::CCSpriteFrame *))v58[1].setScaleX)(v57, v60);
v61 = (__int64)v57->getContentSize(v57);
cocos2d::CCSize::operator=(&v226, v61);
}
v62 = a1->m_colorSprite;
if ( !v62 )
{
LABEL_138:
v70 = a1->getChildByTag(a1, 2);
v72 = (__int64 *)v70;
if ( !v70 )
goto LABEL_60;
v73 = v16 - 1;
if ( v73 )
{
v74 = v73 - 1;
if ( v74 )
{
v75 = v74 - 1;
if ( v75 )
{
if ( v75 != 1 )
{
LABEL_148:
v80 = a1->getContentSize(a1);
v81 = cocos2d::CCSize::CCSize(&v227, v80);
v82 = *v72;
cocos2d::CCPoint::CCPoint(*(float *)&v81, v227.width * 0.5);
(*(void (__fastcall **)(__int64 *, __int64))(v82 + 184))(v72, v83);
goto LABEL_60;
}
v76 = "smallCoin_04_highlight_001.png";
}
else
{
v76 = "smallCoin_03_highlight_001.png";
}
}
else
{
v76 = "smallCoin_02_highlight_001.png";
}
}
else
{
v76 = "smallCoin_01_highlight_001.png";
}
v77 = v70->__vftable;
v78 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v71);
v79 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v78, v76);
((void (__fastcall *)(__int64 *, struct cocos2d::CCSpriteFrame *))v77[1].setScaleX)(v72, v79);
goto LABEL_148;
}
v63 = v16 - 1;
if ( v16 == 1 )
{
v64 = "smallCoin_01_color_001.png";
}
else
{
v63 = v16 - 2;
if ( v16 == 2 )
{
v64 = "smallCoin_02_color_001.png";
}
else
{
v63 = v16 - 3;
if ( v16 == 3 )
{
v64 = "smallCoin_03_color_001.png";
}
else
{
if ( v16 != 4 )
{
LABEL_137:
v68 = a1->m_colorSprite->GameObject::__vftable;
cocos2d::CCPoint::CCPoint(v13, v226.width * 0.5);
v68->setPosition_0(a1->m_colorSprite, v69);
goto LABEL_138;
}
v64 = "smallCoin_04_color_001.png";
}
}
}
v65 = v62->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v66 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v63);
v67 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v66, v64);
v13 = ((float (__fastcall *)(cocos2d::CCSprite *, struct cocos2d::CCSpriteFrame *))v65->setDisplayFrame)(
a1->m_colorSprite,
v67);
goto LABEL_137;
}
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v111 = (const char *)sub_1401AEC80(v53, (unsigned int)a1->m_objectID, v16);
if ( v111 )
{
v112 = a1->GameObject::CCSpritePlus::cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v113 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v110);
v114 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v113, v111);
v112->setDisplayFrame(a1, v114);
}
v115 = a1->m_colorSprite;
if ( !v115 )
goto LABEL_60;
v117 = (cocos2d::CCSprite *)v115->getChildByTag(v115, 1);
if ( !v117 )
goto LABEL_60;
if ( (int)v16 > 1 )
{
v116 = 10 - v16;
v16 = 10 - v16;
}
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v119 = (const char *)sub_1401AED00(v116, (unsigned int)a1->m_objectID, v16);
if ( !v119 )
goto LABEL_60;
v31 = (cocos2d::CCNode_vtbl *)v117->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
}
v120 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v118);
v33 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v120, v119);
v34 = v117;
goto LABEL_59;
}
if ( m_objectID <= 2864 )
{
if ( m_objectID != 2864 )
{
v19 = (unsigned int)(m_objectID - 2021);
switch ( m_objectID )
{
case 2021:
case 2022:
case 2023:
case 2024:
case 2025:
case 2026:
case 2027:
case 2028:
case 2029:
case 2030:
case 2031:
case 2032:
case 2033:
case 2034:
case 2035:
case 2036:
case 2037:
case 2038:
case 2039:
case 2040:
case 2041:
case 2042:
case 2043:
case 2044:
case 2045:
case 2047:
case 2048:
case 2049:
case 2050:
case 2055:
goto LABEL_340;
default:
goto LABEL_48;
}
}
goto LABEL_340;
}
v19 = (unsigned int)(m_objectID - 2865);
switch ( m_objectID )
{
case 2865:
case 2867:
case 2868:
case 2869:
case 2870:
case 2871:
case 2872:
case 2873:
case 2874:
case 2875:
case 2876:
case 2877:
case 2878:
case 2879:
case 2880:
case 2881:
case 2882:
case 2883:
case 2884:
case 2885:
case 2886:
case 2887:
case 2888:
case 2889:
case 2890:
case 2891:
case 2894:
goto LABEL_340;
case 2892:
case 2893:
if ( m_objectID == 2892 )
v192 = 0.025;
else
v192 = 0.033333335;
v193 = a1->m_randomFrameTime;
if ( a1->m_animationShouldUseSpeed )
{
v194 = a1->m_animationSpeed;
if ( v194 != 0.0 )
v193 = fabs(v194);
}
v196 = (int)floorf(v7 / (float)(v192 / v193)) % 16 + 1;
if ( v6 )
v196 = 17 - v196;
if ( v196 != a1->m_maybeAnimationVariableXInt )
{
a1->m_maybeAnimationVariableXInt = v196;
v197 = 4;
if ( m_objectID == 2892 )
v197 = 2;
v198 = v196 % v197;
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v200 = (const char *)sub_1401AEC80(v195, (unsigned int)a1->m_objectID, (unsigned int)(v198 + 1));
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v201 = (const char *)sub_1401AED00(v199, (unsigned int)a1->m_objectID, (unsigned int)(v198 + 1));
v202 = a1->getChildByTag(a1, 1);
v203 = a1->m_colorSprite->getChildren(a1->m_colorSprite);
v204 = cocos2d::CCArray::objectAtIndex(v203, 0);
v205 = v202->__vftable;
v207 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v206);
v208 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v207, v200);
((void (__fastcall *)(cocos2d::CCNode *, struct cocos2d::CCSpriteFrame *))v205[1].setScaleX)(v202, v208);
v209 = v204->__vftable;
v211 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v210);
v212 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v211, v201);
((void (__fastcall *)(struct cocos2d::CCObject *, struct cocos2d::CCSpriteFrame *))v209[13].getTag)(
v204,
v212);
if ( a1->m_objectID != 2892 )
floorf((float)v196 * 0.25);
((void (__fastcall *)(cocos2d::CCNode *))v202->setRotation)(v202);
v204->__vftable[4].canEncode(v204);
}
goto LABEL_60;
case 3000:
case 3001:
case 3002:
v177 = (cocos2d::CCSprite *)a1->getChildByTag(a1, 1);
if ( !v177 )
goto LABEL_60;
v178 = 1;
if ( a1->m_objectID == 3000 )
{
v176 = v16 - 4;
if ( v16 != 4 )
{
v176 = v16 - 5;
if ( v16 == 5 )
{
LABEL_309:
v16 = 2;
goto LABEL_311;
}
v176 = v16 - 9;
if ( v16 == 9 )
{
v16 = 8;
}
else if ( v16 == 10 )
{
v16 = 7;
}
else
{
v178 = 0;
}
LABEL_311:
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v180 = (const char *)sub_1401AEC80(v176, (unsigned int)a1->m_objectID, v16);
if ( v180 )
{
v181 = v177->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v182 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v179);
v183 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v182, v180);
v181->setDisplayFrame(v177, v183);
}
cocos2d::CCSprite::setFlipX(v177, v178);
v184 = a1->m_colorSprite;
if ( v184 )
{
v186 = (cocos2d::CCSprite *)v184->getChildByTag(v184, 1);
if ( v186 )
{
if ( !qword_1406C2ED8 )
{
*(_QWORD *)&v228 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v228);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
}
v188 = (const char *)sub_1401AED00(v185, (unsigned int)a1->m_objectID, v16);
if ( v188 )
{
v189 = v186->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;
v190 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v187);
v191 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v190, v188);
v189->setDisplayFrame(v186, v191);
}
cocos2d::CCSprite::setFlipX(v186, v178);
}
}
goto LABEL_60;
}
}
else
{
if ( (unsigned int)(a1->m_objectID - 3001) > 1 )
goto LABEL_311;
v176 = v16 - 7;
if ( v16 == 7 )
{
v16 = 5;
goto LABEL_311;
}
v176 = v16 - 8;
if ( v16 == 8 )
{
v16 = 4;
goto LABEL_311;
}
v176 = v16 - 9;
if ( v16 != 9 )
{
if ( v16 != 10 )
{
v178 = 0;
goto LABEL_311;
}
goto LABEL_309;
}
}
v16 = 3;
goto LABEL_311;
default:
goto LABEL_48;
}
}
}