// // PlayerObject::togglePlayerScale from 0x3448a8 to 0x344b2a (642 bytes) // // 9 xrefs: // > PlayerObject::copyAttributes @ 0x3477d4 // > PlayerObject::resetObject @ 0x347c4a // > PlayerObject::loadFromCheckpoint @ 0x35085e // > MenuGameLayer::resetPlayer @ 0x3a9700 // > MenuGameLayer::resetPlayer @ 0x3a98b6 // > GJBaseGameLayer::setupLevelStart @ 0x491976 // > GJBaseGameLayer::setupLevelStart @ 0x49198a // > GJBaseGameLayer::collisionCheckObjects @ 0x4928f0 // > GJBaseGameLayer::collisionCheckObjects @ 0x492946 // // 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 PlayerObject::togglePlayerScale(PlayerObject *a1, bool a2, bool a3) { float *p_m_vehicleSize; // r5 _BOOL4 v4; // r9 PlayerObject *v5; // r4 int v6; // r1 int m_isDart; // r1 _BOOL4 m_defaultMiniIcon; // r3 GameManager *v9; // r0 int random; // r1 int seed; // r3 float v12; // r1 cocos2d::CCParticleSystem *m_landParticles0; // r0 float v14; // s15 GhostTrailEffect *m_ghostTrail; // r3 cocos2d::CCMotionStreak *m_shipStreak; // r0 float v17; // r7 cocos2d::CCScaleTo *v18; // r0 cocos2d::CCEaseElasticOut *v19; // r7 PlayLayer *m_playLayer; // r7 cocos2d::CCPoint v21; // r1 cocos2d::ccColor3B v22; // r3 float v23; // [sp+0h] [bp-14h] cocos2d::CCPoint v24; // [sp+4h] [bp-10h] BYREF p_m_vehicleSize = &a1->m_vehicleSize; v4 = a3; v5 = a1; if ( a1->m_vehicleSize == 1.0 ) { if ( !a2 ) return; *p_m_vehicleSize = 0.6; if ( !a1->m_defaultMiniIcon ) goto LABEL_22; if ( a1->m_isBall ) { v6 = 0; LABEL_17: PlayerObject::updatePlayerRollFrame(a1, v6); goto LABEL_22; } if ( a1->m_isRobot ) goto LABEL_22; m_isDart = a1->m_isDart; if ( a1->m_isDart ) goto LABEL_22; goto LABEL_21; } if ( a2 ) return; if ( a1->m_isPlatformer ) a1->m_stateScale = 2; m_defaultMiniIcon = a1->m_defaultMiniIcon; *p_m_vehicleSize = 1.0; if ( m_defaultMiniIcon ) { if ( a1->m_isBall ) { v9 = GameManager::sharedState(); random = v9->m_playerBall.random; seed = v9->m_playerBall.seed; a1 = v5; v6 = random - seed; goto LABEL_17; } if ( a1->m_isRobot || a1->m_isDart ) goto LABEL_22; m_isDart = a1->m_maybeSavedPlayerFrame; LABEL_21: PlayerObject::updatePlayerFrame(a1, m_isDart); } LABEL_22: v12 = *p_m_vehicleSize; m_landParticles0 = v5->m_landParticles0; v5->m_spriteWidthScale = *p_m_vehicleSize; v5->m_spriteHeightScale = v12; cocos2d::CCParticleSystem::loadScaledDefaults(m_landParticles0, v12); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_landParticles1, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_playerGroundParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_vehicleGroundParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_trailingParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_shipClickParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_ufoClickParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_robotBurstParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_dashParticles, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_swingBurstParticles1, *p_m_vehicleSize); cocos2d::CCParticleSystem::loadScaledDefaults(v5->m_swingBurstParticles2, *p_m_vehicleSize); v14 = 1.0; if ( v5->m_isDart ) v14 = 0.8; cocos2d::CCMotionStreak::setStroke(v5->m_regularTrail, (float)(v5->m_streakStrokeWidth * *p_m_vehicleSize) * v14); if ( v5->m_playEffects || v5->m_isDart ) v5->m_waveTrail->m_waveSize = *p_m_vehicleSize; m_ghostTrail = v5->m_ghostTrail; if ( m_ghostTrail ) m_ghostTrail->m_playerScale = *p_m_vehicleSize; m_shipStreak = v5->m_shipStreak; if ( m_shipStreak ) updateStreakSettings(m_shipStreak, v5->m_shipStreakType, (int)v5); GJActionManager::stopInternalAction(v5->m_actionManager, 6); v17 = *p_m_vehicleSize; if ( !v5->m_playEffects || v5->m_maybeReducedEffects || GameManager::sharedState()->m_playLayer->m_skipArtReload ) { v5->setScaleX(v5, COERCE_FLOAT(LODWORD(v17))); v5->setScaleY(v5, COERCE_FLOAT(LODWORD(v17))); } else { v18 = cocos2d::CCScaleTo::create(0.5, v17); v19 = cocos2d::CCEaseElasticOut::create(v18); v19->setTag(v19, 6); GJActionManager::runInternalAction(v5->m_actionManager, v19, v5); if ( *p_m_vehicleSize == 1.0 ) LOWORD(v23) = -256; else LOWORD(v23) = 255; BYTE2(v23) = -106; if ( !v4 ) { m_playLayer = GameManager::sharedState()->m_playLayer; cocos2d::CCPoint::CCPoint(&v24, &v5->m_lastPortalPos); LODWORD(v21.x) = &v24; v21.y = v23; GJBaseGameLayer::lightningFlash(m_playLayer, v21, v22); PlayerObject::spawnPortalCircle(v5, *(cocos2d::ccColor3B *)&v23, 45.0); PlayerObject::spawnScaleCircle(v5); } } if ( v5->m_isBall && v5->m_isRotating ) PlayerObject::runRotateAction(v5, 0, 8); PlayerObject::placeStreakPoint(v5); PlayerObject::updateRobotAnimationSpeed(v5); }
GD Web Decomp Icon

GD Web Decomp

Raw Source