//
// sub_100494AC0 from 0x100494ac0 to 0x100494bdb (283 bytes)
//
// 3 xrefs:
// > EditLevelLayer::onPlay @ 0x1001de746
// > sub_1001E09D0 @ 0x1001e0af3
// > LevelInfoLayer::onPlay @ 0x1002ac82c
//
// This function is hookable on this platform (idp: pc, 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:30:48 +0000
//
void *__fastcall sub_100494AC0(__int64 a1, double a2)
{
__int64 v2; // rsi
char *v3; // r14
void *v4; // r14
__int64 v5; // rbx
double v7; // [rsp+8h] [rbp-38h] BYREF
unsigned int v8; // [rsp+10h] [rbp-30h] BYREF
__int64 v9; // [rsp+18h] [rbp-28h] BYREF
v2 = cocos2d::CCDirector::sharedDirector();
cocos2d::CCDirector::getWinSize(&v9, v2);
v3 = cocos2d::CCSprite::createWithSpriteFrameName((__int64)"GJ_closeBtn_001.png", a2);
(*(void (__fastcall **)(char *, float))(*(_QWORD *)v3 + 160LL))(v3, 0.69999999);
v4 = CCMenuItemSpriteExtra::create((__int64)v3, 0, a1, (__int64)FLAlertLayer::onButton, 0);
CCMenuItemSpriteExtra::setSizeMult((__int64)v4, 1.2);
(*(void (__fastcall **)(_QWORD, void *))(**(_QWORD **)(a1 + 552) + 456LL))(*(_QWORD *)(a1 + 552), v4);
v5 = *(_QWORD *)(a1 + 552);
sub_100278250(
(float *)&v8,
(float)((float)(*(float *)&v9 * 0.5) - (float)(*(float *)(a1 + 648) * 0.5)) + 5.0,
(float)((float)(0.5 * *(float *)(a1 + 652)) + (float)(*((float *)&v9 + 1) * 0.5)) + -5.0);
cocos2d::CCNode::convertToNodeSpace(&v7, v5, &v8);
(*(void (__fastcall **)(void *, double *))(*(_QWORD *)v4 + 184LL))(v4, &v7);
(*(void (__fastcall **)(void *, __int64))(*(_QWORD *)v4 + 72LL))(v4, 2);
return v4;
}