//
// ShaderLayer::triggerChromaticGlitch from 0x10027125c to 0x1002713d8 (380 bytes)
//
// 1 xrefs:
// > GJBaseGameLayer::triggerShaderCommand @ 0x1001f0ea8
//
// 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 ShaderLayer::triggerChromaticGlitch(
ShaderLayer *a1,
bool a2,
float a3,
float a4,
float a5,
float a6,
float a7,
float a8,
float a9,
int a10,
float a11,
bool a12,
bool a13)
{
double m_time; // d0
float m_cGStartTime; // s4
float m_cGTime; // s3
float v27; // s2
float v28; // s0
float v29; // s0
m_time = a1->m_state.m_time;
if ( a1->m_state.m_cGEnable )
{
m_cGStartTime = a1->m_state.m_cGStartTime;
m_cGTime = a1->m_state.m_cGTime;
v27 = m_time;
}
else
{
v27 = m_time;
m_cGTime = v27;
m_cGStartTime = v27;
}
a1->m_state.m_cGEnable = a2;
v28 = m_time - m_cGStartTime;
a1->m_state.m_cGTime = m_cGTime + (float)(v28 * a1->m_state.m_cGSpeed);
a1->m_state.m_cGStartTime = v27;
ShaderLayer::tweenValueAuto(a1, a4, 8, a3, a10, a11);
v29 = 0.1;
if ( a9 >= 0.1 )
v29 = a9;
ShaderLayer::tweenValueAuto(a1, 1.0 / v29, 7, a3, a10, a11);
ShaderLayer::tweenValueAuto(a1, a5, 4, a3, a10, a11);
ShaderLayer::tweenValueAuto(a1, a7, 5, a3, a10, a11);
ShaderLayer::tweenValueAuto(a1, a8, 6, a3, a10, a11);
ShaderLayer::tweenValueAuto(a1, a6, 3, a3, a10, a11);
a1->m_state.m_cGRelative = a12;
a1->m_state.m_cGRelativePos = a13;
}