//
// PlayerObject::updateShipSpriteExtra from 0x1003fbee0 to 0x1003fbfad (205 bytes)
//
// 4 xrefs:
// > PlayerObject::init @ 0x1003fafbd
// > PlayerObject::updatePlayerShipFrame @ 0x1004168a0
// > PlayerObject::updatePlayerJetpackFrame @ 0x100416aed
// > PlayerObject::updatePlayerBirdFrame @ 0x10041740b
//
// 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
//
__int64 __fastcall PlayerObject::updateShipSpriteExtra(__int64 a1, __int64 a2)
{
cocos2d::CCSpriteFrameCache *v3; // rax
const char *v4; // r14
cocos2d::CCSpriteFrame *v5; // rax
__int64 *v6; // rdi
__int64 v7; // rcx
_QWORD *v8; // rax
__int64 v9; // rbx
float v11; // [rsp+0h] [rbp-20h] BYREF
__int64 v12; // [rsp+8h] [rbp-18h] BYREF
v3 = cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache();
if ( (*(_BYTE *)a2 & 1) != 0 )
v4 = *(const char **)(a2 + 16);
else
v4 = (const char *)(a2 + 1);
v5 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v3, v4);
v6 = *(__int64 **)(a1 + 1848);
v7 = *v6;
if ( !v5 )
return (*(__int64 (__fastcall **)(__int64 *, _QWORD))(v7 + 328))(v6, 0);
(*(void (__fastcall **)(__int64 *, cocos2d::CCSpriteFrame *))(v7 + 1144))(v6, v5);
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 1848) + 328LL))(*(_QWORD *)(a1 + 1848), 1);
v8 = (_QWORD *)(*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1824) + 312LL))(*(_QWORD *)(a1 + 1824));
sub_10028CFC0(&v12, v8);
v9 = *(_QWORD *)(a1 + 1848);
sub_10028CBE0(&v11, *(float *)&v12 * 0.5, 0.5 * *((float *)&v12 + 1));
return (*(__int64 (__fastcall **)(__int64, float *))(*(_QWORD *)v9 + 184LL))(v9, &v11);
}