//
// EditorUI::showTextAlert from 0x10060d960 to 0x10060db0b (427 bytes)
//
// 21 xrefs:
// > EditorUI::showGridSizeAlert @ 0x10000e45b
// > EditorUI::createGradientFromSelection @ 0x10001734e
// > EditorUI::createGradientFromSelection @ 0x10001783d
// > sub_1000D5190 @ 0x1000d538d
// > sub_1000D5780 @ 0x1000d5a58
// > EditorUI::findObject @ 0x1005b99b2
// > EditorUI::handleEditorAction @ 0x10060bede
// > EditorUI::handleEditorAction @ 0x10060bf8f
// > EditorUI::handleEditorAction @ 0x10060c30a
// > EditorUI::handleEditorAction @ 0x10060c4f5
// > EditorUI::handleEditorAction @ 0x10060c80a
// > EditorUI::handleEditorAction @ 0x10060c90f
// > EditorUI::handleEditorAction @ 0x10060c9a4
// > EditorUI::handleEditorAction @ 0x10060ca9e
// > EditorUI::handleEditorAction @ 0x10060cb1b
// > EditorUI::handleEditorAction @ 0x10060cc13
// > EditorUI::handleEditorAction @ 0x10060cfeb
// > EditorUI::handleEditorAction @ 0x10060d05c
// > EditorUI::handleEditorAction @ 0x10060d0ab
// > EditorUI::showLockedLayerAlert @ 0x10060dc23
// > EditorUI::toggleViewOption @ 0x10063e686
//
// 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:34:33 +0000
//
__int64 __fastcall EditorUI::showTextAlert(__int64 a1, std::string *a2, char a3, int a4, unsigned int a5)
{
const std::string::value_type *v7; // rsi
const char *data; // r15
size_t v9; // rax
size_t v10; // r12
char *v11; // r13
size_t v12; // r14
char *v13; // r15
float v15; // [rsp+0h] [rbp-70h] BYREF
float v16; // [rsp+8h] [rbp-68h] BYREF
__int128 __dst; // [rsp+10h] [rbp-60h] BYREF
void *v18; // [rsp+20h] [rbp-50h]
__int128 v19; // [rsp+28h] [rbp-48h] BYREF
void *__p; // [rsp+38h] [rbp-38h]
unsigned int v21; // [rsp+44h] [rbp-2Ch]
if ( !a4 )
{
v7 = "Off";
if ( a3 )
v7 = "On";
std::string::append(a2, v7);
}
if ( (*(_BYTE *)&a2->__r_.__value_.__s.0 & 1) != 0 )
data = a2->__r_.__value_.__l.__data_;
else
data = a2->__r_.__value_.__s.__data_;
v9 = strlen(data);
if ( v9 >= 0xFFFFFFFFFFFFFFF8LL )
sub_100003630();
v10 = v9;
v21 = a5;
if ( v9 >= 0x17 )
{
v12 = 26;
if ( (v9 | 7) != 0x17 )
v12 = (v9 | 7) + 1;
v11 = (char *)operator new(v12);
v18 = v11;
*(_QWORD *)&__dst = v12 + 1;
*((_QWORD *)&__dst + 1) = v10;
goto LABEL_15;
}
LOBYTE(__dst) = 2 * v9;
v11 = (char *)&__dst + 1;
if ( v9 )
LABEL_15:
memmove(v11, data, v10);
v11[v10] = 0;
LOBYTE(v19) = 24;
strcpy((char *)&v19 + 1, "chatFont.fnt");
v13 = TextAlertPopup::create(&__dst, 0x64u, &v19, 0.60000002, 0.60000002);
if ( (v19 & 1) != 0 )
operator delete(__p);
if ( (__dst & 1) != 0 )
operator delete(v18);
TextAlertPopup::setLabelColor((__int64)v13, 65280);
sub_100278250(&v15, 0.0, 1.0);
sub_100278250(&v16, 20.0, -20.0);
TextAlertPopup::setAlertPosition((__int64)v13, &v15, &v16);
if ( v21 )
return TextAlertPopup::replaceIn(a1, v21, (__int64)v13, 0x64u);
else
return (*(__int64 (__fastcall **)(__int64, char *, __int64))(*(_QWORD *)a1 + 464LL))(a1, v13, 100);
}