// // cocos2d::CCDirector::setDefaultValues from 0x100482850 to 0x1004829a7 (343 bytes) // // 2 xrefs: // > cocos2d::CCDirector::init @ 0x10048259e // > cocos2d::CCConfiguration::loadConfigFile @ 0x10051a677 // // 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 // void __fastcall cocos2d::CCDirector::setDefaultValues(cocos2d::CCDirector *a1) { cocos2d::CCConfiguration *v1; // rbx double Number; // xmm0_8 const char *CString; // rax int v4; // ecx cocos2d::ccDirectorProjection v5; // eax const char *v6; // r14 cocos2d::CCTexture2DPixelFormat v7; // edi bool Bool; // al v1 = cocos2d::CCConfiguration::sharedConfiguration(); Number = cocos2d::CCConfiguration::getNumber(v1, "cocos2d.x.fps", 60.0); a1->m_dAnimationInterval = 1.0 / Number; a1->m_dOldAnimationInterval = 1.0 / Number; a1->m_bDisplayStats = cocos2d::CCConfiguration::getBool(v1, "cocos2d.x.display_fps", 0); CString = cocos2d::CCConfiguration::getCString(v1, "cocos2d.x.gl.projection", "3d"); v4 = *(unsigned __int8 *)CString; if ( v4 == 50 ) { if ( CString[1] == 100 && !CString[2] ) { v5 = kCCDirectorProjection2D; goto LABEL_10; } } else if ( v4 == 51 && CString[1] == 100 && !CString[2] ) { v5 = kCCDirectorProjection3D; goto LABEL_10; } if ( strcmp(CString, "custom") ) goto LABEL_11; v5 = kCCDirectorProjectionCustom; LABEL_10: a1->m_eProjection = v5; LABEL_11: v6 = cocos2d::CCConfiguration::getCString(v1, "cocos2d.x.texture.pixel_format_for_png", "rgba8888"); if ( !strcmp(v6, "rgba8888") ) { v7 = kCCTexture2DPixelFormat_RGBA8888; goto LABEL_17; } if ( !strcmp(v6, "rgba4444") ) { v7 = kCCTexture2DPixelFormat_RGBA4444; goto LABEL_17; } if ( !strcmp(v6, "rgba5551") ) { v7 = kCCTexture2DPixelFormat_RGB5A1; LABEL_17: cocos2d::CCTexture2D::setDefaultAlphaPixelFormat(v7); } Bool = cocos2d::CCConfiguration::getBool(v1, "cocos2d.x.texture.pvrv2_has_alpha_premultiplied", 0); cocos2d::CCTexture2D::PVRImagesHavePremultipliedAlpha(Bool); }
GD Web Decomp Icon

GD Web Decomp

Raw Source