// // AnimatedGameObject::init from 0x3e8194 to 0x3e82de (330 bytes) // // 1 xrefs: // > AnimatedGameObject::create @ 0x3e8368 // // 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 AnimatedGameObject::init(AnimatedGameObject *a1, int a2) { const char *v4; // r0 _BOOL4 v5; // r7 CCAnimatedSprite *v7; // r0 cocos2d::CCTexture2D *v8; // r0 const cocos2d::CCSize *v9; // r0 CCAnimatedSprite *m_animatedSprite; // r8 void (__fastcall *setPosition)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // r9 cocos2d::CCSize v12; // [sp+4h] [bp-18h] BYREF cocos2d::CCPoint v13; // [sp+Ch] [bp-10h] BYREF a1->m_classType = Animated; a1->m_objectID = a2; if ( a2 == 1327 ) { v4 = "GJBeast02"; } else if ( a2 >= 1328 ) { switch ( a2 ) { case 1584: a1->m_notGrounded = 1; v4 = "GJBeast04"; break; case 2012: a1->m_notGrounded = 1; v4 = "GJBeast05"; break; case 1328: v4 = "GJBeast03"; break; default: goto LABEL_13; } } else { if ( a2 != 918 ) { if ( a2 == 919 ) { v4 = "BlackSludge"; goto LABEL_16; } LABEL_13: LOBYTE(v5) = 0; return v5; } a1->m_notGrounded = 1; v4 = "GJBeast01"; } LABEL_16: v7 = CCAnimatedSprite::createWithType(v4, nullptr, 0); a1->m_animatedSprite = v7; SpriteAnimationManager::stopAnimations(v7->m_animationManager); a1->m_animatedSprite->m_delegate = &a1->AnimatedSpriteDelegate; v8 = a1->m_animatedSprite->getTexture(a1->m_animatedSprite); v5 = GameObject::initWithTexture(a1, v8); if ( v5 ) { AnimatedGameObject::setupAnimatedSize(a1, a2); a1->addChild(a1, a1->m_animatedSprite); v9 = a1->getContentSize(a1); cocos2d::CCSize::CCSize(&v12, v9); m_animatedSprite = a1->m_animatedSprite; setPosition = m_animatedSprite->setPosition; cocos2d::CCPoint::CCPoint(&v13, v12.width * 0.5, v12.height * 0.5); setPosition(m_animatedSprite, &v13); a1->m_unk367 = 1; a1->m_bUnkBool2 = 0; AnimatedGameObject::setupChildSprites(a1); } return v5; }
GD Web Decomp Icon

GD Web Decomp

Raw Source