//
// PlayerObject::updatePlayerSpriteExtra from 0x14039ec10 to 0x14039ed19 (265 bytes)
//
// 6 xrefs:
// > PlayerObject::init @ 0x140386e43
// > PlayerObject::updatePlayerFrame @ 0x14039de64
// > PlayerObject::updatePlayerRollFrame @ 0x14039e78f
// > PlayerObject::updatePlayerSwingFrame @ 0x14039e9be
// > PlayerObject::updatePlayerDartFrame @ 0x14039ebee
// > ??> @ 0x1406d67ac
//
// 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
//
// Hidden C++ exception states: #wind=1
void __fastcall PlayerObject::updatePlayerSpriteExtra(__int64 a1, const char *a2)
{
const char *v4; // rbx
cocos2d::CCSpriteFrameCache *v5; // rax
struct cocos2d::CCSpriteFrame *v6; // rax
__int64 v7; // rcx
__int64 v8; // rdx
const struct cocos2d::CCSize *v9; // rax
double v10; // xmm0_8
__int64 v11; // rbx
__int64 v12; // rax
cocos2d::CCSize v13[3]; // [rsp+20h] [rbp-28h] BYREF
v13[2] = (cocos2d::CCSize)a2;
v4 = a2;
if ( *((_QWORD *)a2 + 3) > 0xFu )
v4 = *(const char **)a2;
v5 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(a1);
v6 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v5, v4);
v7 = *(_QWORD *)(a1 + 1864);
if ( v6 )
{
(*(void (__fastcall **)(__int64, struct cocos2d::CCSpriteFrame *))(*(_QWORD *)v7 + 992LL))(v7, v6);
LOBYTE(v8) = 1;
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 1864) + 320LL))(*(_QWORD *)(a1 + 1864), v8);
v9 = (const struct cocos2d::CCSize *)(*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1848) + 304LL))(*(_QWORD *)(a1 + 1848));
v10 = cocos2d::CCSize::CCSize(v13, v9);
v11 = **(_QWORD **)(a1 + 1864);
cocos2d::CCPoint::CCPoint(*(float *)&v10, v13[0].width * 0.5);
(*(void (__fastcall **)(_QWORD, __int64))(v11 + 184))(*(_QWORD *)(a1 + 1864), v12);
}
else
{
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v7 + 320LL))(v7, 0);
}
sub_14003A830((__int64)a2);
}