//
// AudioEffectsLayer::triggerEffect from 0x8b84f4 to 0x8b8630 (316 bytes)
//
// 2 xrefs:
// > AudioEffectsLayer::audioStep @ 0x8b86fc
// > ??> @ 0x71ff8
//
// This function is hookable on this platform (idp: arm, 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 12:56:26 +0000
//
__int64 __fastcall AudioEffectsLayer::triggerEffect(__int64 this, float a2)
{
float v2; // s8
float v3; // s8
float *v4; // x19
const char *v5; // x1
cocos2d::CCSequence *v6; // x21
const char *v7; // x1
__int64 v8; // x20
cocos2d::CCFiniteTimeAction *v9; // x0
cocos2d::CCAction *v10; // x20
if ( a2 == 1.0 )
{
v2 = 0.8;
}
else if ( a2 == 0.9 )
{
v2 = 0.6;
}
else if ( a2 == 0.8 )
{
v2 = 0.5;
}
else
{
v2 = a2 * 0.2;
}
v3 = v2 + *(float *)(this + 580);
if ( v3 >= 1.1 )
v3 = 1.1;
if ( *(_BYTE *)(this + 576) || v3 >= *(float *)(this + 572) )
{
v4 = (float *)this;
*(float *)(this + 572) = v3;
*(_BYTE *)(this + 576) = 0;
cocos2d::CCNode::stopActionByTag((cocos2d::CCNode *)this, 0);
v6 = (cocos2d::CCSequence *)cocos2d::CCActionTween::create(
(cocos2d::CCActionTween *)"audioScale",
0.05,
v5,
v4[145],
v3);
v8 = cocos2d::CCActionTween::create((cocos2d::CCActionTween *)"audioScale", 0.2, v7, v3, 0.1);
v9 = (cocos2d::CCFiniteTimeAction *)cocos2d::CCCallFunc::create(v4, AudioEffectsLayer::goingDown, 0);
v10 = (cocos2d::CCAction *)cocos2d::CCSequence::create(v6, v9, v8, 0);
(*(void (__fastcall **)(cocos2d::CCAction *, _QWORD))(*(_QWORD *)v10 + 72LL))(v10, 0);
return cocos2d::CCNode::runAction((cocos2d::CCNode *)v4, v10);
}
return this;
}