//
// GJEffectManager::addCountToItem from 0xa12a68 to 0xa12ac8 (96 bytes)
//
// 4 xrefs:
// > GJBaseGameLayer::collectedObject @ 0x9ec978
// > GJBaseGameLayer::collectedObject @ 0x9ec9b0
// > GJBaseGameLayer::addPickupTrigger @ 0x9ec9fc
// > ??> @ 0x4cc60
//
// 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:59:31 +0000
//
__int64 __fastcall GJEffectManager::addCountToItem(GJEffectManager *this, int a2, int a3)
{
int v4; // w3
_DWORD *v5; // x0
int v8; // [xsp+2Ch] [xbp+2Ch] BYREF
v4 = 9999;
if ( a2 <= 9998 )
{
if ( a2 < 0 )
v4 = 0;
else
v4 = a2;
}
v8 = v4;
v5 = (_DWORD *)std::unordered_map::operator[]((__int64)this + 712, &v8);
return GJEffectManager::updateCountForItem(this, v8, a3 + *v5);
}