//
// CCTextInputNode::setAllowedChars from 0x3e2d14 to 0x3e2d98 (132 bytes)
//
// 78 xrefs:
// > CreateGuidelinesLayer::init @ 0x3f87c2
// > MoreSearchLayer::init @ 0x497cb4
// > LevelSearchLayer::init @ 0x4987dc
// > EditLevelLayer::init @ 0x4a1400
// > ColorSelectPopup::init @ 0x4dfe9a
// > ColorSelectPopup::init @ 0x4e0c42
// > ColorSelectPopup::init @ 0x4e1076
// > ColorSelectPopup::init @ 0x4e1586
// > GJGarageLayer::init @ 0x51023c
// > MoreOptionsLayer::init @ 0x5338be
// > ShareCommentLayer::init @ 0x541cd4
// > CustomSongLayer::init @ 0x57c9ac
// > SongOptionsLayer::init @ 0x57d518
// > CustomizeObjectLayer::init @ 0x580282
// > CustomizeObjectLayer::init @ 0x580960
// > AccountRegisterLayer::init @ 0x586d8e
// > AccountRegisterLayer::init @ 0x586f6c
// > AccountRegisterLayer::init @ 0x58705a
// > AccountRegisterLayer::init @ 0x587152
// > AccountRegisterLayer::init @ 0x587234
// > AccountLoginLayer::init @ 0x5876f6
// > AccountLoginLayer::init @ 0x58783a
// > KeybindingsLayer::init @ 0x58aadc
// > SetIDPopup::init @ 0x5da9f4
// > SetTextPopup::init @ 0x5de71a
// > GJWriteMessagePopup::init @ 0x5dfb8e
// > GJWriteMessagePopup::init @ 0x5dfe12
// > SocialLinksPopup::init @ 0x5e2c8e
// > ConfigureHSVWidget::createTextInputNode @ 0x5e5186
// > SetupOpacityPopup::init @ 0x5e9c40
// > SetupPulsePopup::init @ 0x5ed41e
// > SetupPulsePopup::init @ 0x5ed6f8
// > SetupPulsePopup::init @ 0x5ed9d0
// > SetupPulsePopup::init @ 0x5eeb90
// > SetupPulsePopup::init @ 0x5eee6e
// > SecretLayer::init @ 0x5ff00c
// > ConfigureValuePopup::init @ 0x603060
// > ConfigureValuePopup::init @ 0x603074
// > SecretLayer2::init @ 0x61f74a
// > SecretLayer4::init @ 0x623016
// > SetupAnimationPopup::init @ 0x624c2a
// > SetupInstantCountPopup::init @ 0x628088
// > SetupShakePopup::init @ 0x62a104
// > SetupCameraOffsetTrigger::init @ 0x6331a4
// > SetupCameraOffsetTrigger::init @ 0x633816
// > SetupRandTriggerPopup::init @ 0x636322
// > SetGroupIDLayer::createTextInput @ 0x63ce64
// > SetGroupIDLayer::createTextInput @ 0x63ce78
// > SetupCameraRotatePopup::init @ 0x65a984
// > SetupCameraRotatePopup::init @ 0x65afb4
// > SetupRandAdvTriggerPopup::init @ 0x65c576
// > CreateParticlePopup::createParticleSlider @ 0x666f18
// > SetupTriggerPopup::createValueControlAdvanced @ 0x67a788
// > SetupTriggerPopup::createValueControlAdvanced @ 0x67a79c
// > SetupTriggerPopup::createValueControlAdvanced @ 0x67a7b0
// > SetupTriggerPopup::createValueControlAdvanced @ 0x67a7f2
// > SetupMGTrigger::init @ 0x69af00
// > SetupMGTrigger::init @ 0x69b53c
// > LevelSettingsLayer::init @ 0x6ac61e
// > LevelSettingsLayer::init @ 0x6ac846
// > SecretLayer5::init @ 0x6e5ee2
// > GJScaleControl::createScaleInput @ 0x6ee7f8
// > GJRotationControl::init @ 0x6ef2e6
// > SFXFolderPickerPopup::init @ 0x730722
// > AdminActionConfirmPopup::init @ 0x731762
// > ReviewChoiceSheet::init @ 0x7335b8
// > RenameThreadPopup::init @ 0x74de4c
// > ThreadSearchPopup::init @ 0x74e6a2
// > NewThreadPopup::init @ 0x756a6e
// > DeathStatsPopup::init @ 0x76f528
// > DeathStatsPopup::init @ 0x76f76c
// > EditorSoundBrowserLayer::onSelectMode @ 0x783508
// > EditorSoundConfigInfoLayer::init @ 0x7874a2
// > EditorSoundsLayer::init @ 0x78ae4a
// > IDNameBrowserPopup::init @ 0x792818
// > IDNameBrowserPopup::init @ 0x792c4e
// > IDNameBrowserPopup::init @ 0x792f7e
// > IDNameInput::initCore @ 0x79413e
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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 11:47:02 +0000
//
unsigned __int8 *__fastcall CCTextInputNode::setAllowedChars(int a1, unsigned __int8 *a2)
{
unsigned __int8 *result; // r0
unsigned int v5; // r3
int v6; // r2
int v7; // r7
int v8; // r6
int v9; // lr
unsigned int v10; // r2
unsigned __int8 *v11; // r1
int v12; // r1
int v13; // r3
result = std::string::operator=((unsigned __int8 *)(a1 + 356), a2);
v5 = *(_DWORD *)(a1 + 504);
if ( v5 )
return result;
v6 = *a2;
v7 = 0;
v8 = 0;
result = nullptr;
v9 = v6 & 1;
v10 = v6 >> 1;
while ( v9 )
{
if ( v5 >= *((_DWORD *)a2 + 1) )
goto LABEL_15;
v11 = *((unsigned __int8 **)a2 + 2);
LABEL_8:
v12 = v11[v5];
if ( (unsigned int)(v12 - 48) <= 9 )
{
result = (_BYTE *)(&dword_0 + 1);
}
else if ( v12 == 45 )
{
v8 = 1;
}
else
{
if ( v12 != 46 )
return result;
v7 = 1;
}
++v5;
}
if ( v5 < v10 )
{
v11 = a2 + 1;
goto LABEL_8;
}
LABEL_15:
if ( result )
{
if ( v7 )
{
*(_DWORD *)(a1 + 504) = 1;
if ( *(int *)(a1 + 508) <= 0 )
*(_DWORD *)(a1 + 508) = 2;
}
else
{
if ( v8 )
v13 = 2;
else
v13 = 3;
*(_DWORD *)(a1 + 504) = v13;
}
}
return result;
}