//
// LevelEditorLayer::applyGroupState from 0x4624ac to 0x462502 (86 bytes)
//
// 3 xrefs:
// > LevelEditorLayer::pasteGroupState @ 0x462516
// > LevelEditorLayer::pasteGroupState @ 0x462542
// > LevelEditorLayer::copyObjectState @ 0x4663be
//
// 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:48:53 +0000
//
int __fastcall LevelEditorLayer::applyGroupState(LevelEditorLayer *this, GameObject *a2, GameObject *a3)
{
int result; // r0
signed int i; // r5
int GroupID; // r8
GJBaseGameLayer::removeFromGroups(this, a2);
GameObject::resetGroups((int)a2);
result = GameObject::resetGroupDisabled((int)a2);
for ( i = 0; i < *((__int16 *)a3 + 510); ++i )
{
GroupID = GameObject::getGroupID(a3, i);
result = (*(int (__fastcall **)(GameObject *, int))(*(_DWORD *)a2 + 800))(a2, GroupID);
if ( result == 1 )
result = (*(int (__fastcall **)(LevelEditorLayer *, GameObject *, int))(*(_DWORD *)this + 676))(this, a2, GroupID);
}
return result;
}