{"type": "func", "start": 8134932, "end": 8135376, "name": "EditorUI::playSoundForCreatedObject", "pseudocode": "// \n// EditorUI::playSoundForCreatedObject from 0x7c2114 to 0x7c22d0 (444 bytes)\n// \n// 2 xrefs:\n// > EditorUI::onCreate @ 0x7ca858\n// > <???> @ 0x58468\n// \n// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 12:54:07 +0000\n// \n\n__int64 __fastcall EditorUI::playSoundForCreatedObject(EditorUI *this, GameObject *a2)\n{\n  int v2; // w19\n  int v3; // w20\n  unsigned int v4; // w21\n  int v5; // w22\n  EditorSFXManager *v6; // x0\n  EditorSFXManager *hasSoundsForAction; // x0\n  EditorSFXManager *v8; // x0\n  int v9; // w1\n\n  v2 = 263;\n  if ( !a2 )\n    goto LABEL_11;\n  v3 = *((_DWORD *)a2 + 257);\n  v4 = (*(__int64 (__fastcall **)(GameObject *))(*(_QWORD *)a2 + 1800LL))(a2);\n  v5 = *((_DWORD *)a2 + 312);\n  this = (EditorUI *)(*(unsigned __int8 (__fastcall **)(GameObject *))(*(_QWORD *)a2 + 1736LL))(a2);\n  if ( v3 == 1334 )\n    goto LABEL_21;\n  if ( v3 <= 1334 )\n  {\n    if ( v3 == 914 )\n      goto LABEL_17;\n    if ( v3 > 914 )\n    {\n      if ( v3 == 918 || v3 >= 918 && (unsigned int)(v3 - 1327) <= 1 )\n        goto LABEL_33;\n      goto LABEL_9;\n    }\n    if ( (unsigned int)(v3 - 200) > 3 )\n      goto LABEL_9;\nLABEL_21:\n    v2 = 265;\n    goto LABEL_11;\n  }\n  if ( v3 == 1700 )\n    goto LABEL_22;\n  if ( v3 > 1700 )\n  {\n    v2 = 260;\n    if ( v3 == 2063 )\n      goto LABEL_11;\n    if ( v3 != 2065 )\n    {\n      if ( v3 != 2012 )\n        goto LABEL_9;\nLABEL_33:\n      v2 = 264;\n      goto LABEL_11;\n    }\nLABEL_22:\n    v2 = 251;\n    goto LABEL_11;\n  }\n  switch ( v3 )\n  {\n    case 1586:\n      goto LABEL_22;\n    case 1615:\nLABEL_17:\n      v2 = 252;\n      goto LABEL_11;\n    case 1584:\n      goto LABEL_33;\n  }\nLABEL_9:\n  if ( v4 <= 0x2F )\n  {\n    v2 = word_1142210[v4];\n    if ( (_BYTE)this )\n    {\n      if ( v2 == 256 )\n      {\n        v2 = 255;\n        goto LABEL_11;\n      }\n      if ( v2 == 263 )\n      {\n        v2 = 254;\n        goto LABEL_11;\n      }\n    }\n    if ( v2 != 263 )\n      goto LABEL_11;\n  }\n  else\n  {\n    v2 = 254;\n    if ( (_BYTE)this )\n      goto LABEL_11;\n  }\n  if ( v5 == 2\n    || (this = (EditorUI *)(*(unsigned __int8 (__fastcall **)(GameObject *))(*(_QWORD *)a2 + 1728LL))(a2), (_BYTE)this) )\n  {\n    v2 = 253;\n  }\n  else\n  {\n    this = (EditorUI *)(off_F8 + 2);\n    if ( v5 == 1 )\n      v2 = 250;\n    else\n      v2 = 263;\n  }\nLABEL_11:\n  v6 = (EditorSFXManager *)EditorSFXManager::sharedState(this);\n  hasSoundsForAction = (EditorSFXManager *)(unsigned __int8)EditorSFXManager::hasSoundsForAction(v6, v2);\n  if ( (_BYTE)hasSoundsForAction )\n  {\n    v8 = (EditorSFXManager *)EditorSFXManager::sharedState(hasSoundsForAction);\n    v9 = v2;\n  }\n  else\n  {\n    v8 = (EditorSFXManager *)EditorSFXManager::sharedState(hasSoundsForAction);\n    v9 = 100;\n  }\n  return EditorSFXManager::playAction(v8, v9);\n}", "assembly": "; \n; EditorUI::playSoundForCreatedObject from 0x7c2114 to 0x7c22d0 (444 bytes)\n; \n; 2 xrefs:\n; > EditorUI::onCreate @ 0x7ca858\n; > <???> @ 0x58468\n; \n; This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 12:54:07 +0000\n; \nSTP             X29, X30, [SP,#var_40]!                                ; +0x0, 0x7c2114\nMOV             X29, SP                                                ; +0x4, 0x7c2118\nSTP             X19, X20, [SP,#0x40+var_30]                            ; +0x8, 0x7c211c\nSTP             X21, X22, [SP,#0x40+var_20]                            ; +0xc, 0x7c2120\nMOV             W19, #0x107                                            ; +0x10, 0x7c2124\nCBZ             X1, loc_7C21AC                                         ; +0x14, 0x7c2128\nLDR             X2, [X1]                                               ; +0x18, 0x7c212c\nMOV             X0, X1                                                 ; +0x1c, 0x7c2130\nSTR             X1, [X29,#0x40+var_8]                                  ; +0x20, 0x7c2134\nLDR             W20, [X1,#0x404]                                       ; +0x24, 0x7c2138\nLDR             X2, [X2,#0x708]                                        ; +0x28, 0x7c213c\nBLR             X2                                                     ; +0x2c, 0x7c2140\nMOV             W21, W0                                                ; +0x30, 0x7c2144\nLDR             X1, [X29,#0x40+var_8]                                  ; +0x34, 0x7c2148\nMOV             X0, X1                                                 ; +0x38, 0x7c214c\nLDR             X2, [X1]                                               ; +0x3c, 0x7c2150\nLDR             W22, [X1,#0x4E0]                                       ; +0x40, 0x7c2154\nLDR             X2, [X2,#0x6C8]                                        ; +0x44, 0x7c2158\nBLR             X2                                                     ; +0x48, 0x7c215c\nUXTB            W0, W0; this                                           ; +0x4c, 0x7c2160\nCMP             W20, #0x536                                            ; +0x50, 0x7c2164\nB.EQ            loc_7C2220                                             ; +0x54, 0x7c2168\nLDR             X1, [X29,#0x40+var_8]                                  ; +0x58, 0x7c216c\nB.LE            loc_7C2208                                             ; +0x5c, 0x7c2170\nCMP             W20, #0x6A4                                            ; +0x60, 0x7c2174\nB.EQ            loc_7C2228                                             ; +0x64, 0x7c2178\nB.LE            loc_7C21F0                                             ; +0x68, 0x7c217c\nCMP             W20, #0x80F                                            ; +0x6c, 0x7c2180\nMOV             W19, #0x104                                            ; +0x70, 0x7c2184\nB.EQ            loc_7C21AC                                             ; +0x74, 0x7c2188\nCMP             W20, #0x811                                            ; +0x78, 0x7c218c\nB.EQ            loc_7C2228                                             ; +0x7c, 0x7c2190\nCMP             W20, #0x7DC                                            ; +0x80, 0x7c2194\nB.EQ            loc_7C2294                                             ; +0x84, 0x7c2198\nCMP             W21, #0x2F ; '/'                                       ; +0x88, 0x7c219c\nB.LS            loc_7C2230                                             ; +0x8c, 0x7c21a0\nMOV             W19, #0xFE                                             ; +0x90, 0x7c21a4\nCBZ             W0, loc_7C2248                                         ; +0x94, 0x7c21a8\nBL              _ZN16EditorSFXManager11sharedStateEv; EditorSFXManager::sharedState(void) ; +0x98, 0x7c21ac\nMOV             W1, W19; int                                           ; +0x9c, 0x7c21b0\nBL              _ZNK16EditorSFXManager18hasSoundsForActionEi; EditorSFXManager::hasSoundsForAction(int) ; +0xa0, 0x7c21b4\nUXTB            W0, W0; this                                           ; +0xa4, 0x7c21b8\nCBNZ            W0, loc_7C21D8                                         ; +0xa8, 0x7c21bc\nBL              _ZN16EditorSFXManager11sharedStateEv; EditorSFXManager::sharedState(void) ; +0xac, 0x7c21c0\nLDP             X19, X20, [SP,#0x40+var_30]                            ; +0xb0, 0x7c21c4\nLDP             X21, X22, [SP,#0x40+var_20]                            ; +0xb4, 0x7c21c8\nLDP             X29, X30, [SP+0x40+var_40],#0x40                       ; +0xb8, 0x7c21cc\nMOV             W1, #0x64 ; 'd'; int                                   ; +0xbc, 0x7c21d0\nB               _ZN16EditorSFXManager10playActionEi; EditorSFXManager::playAction(int) ; +0xc0, 0x7c21d4\nBL              _ZN16EditorSFXManager11sharedStateEv; EditorSFXManager::sharedState(void) ; +0xc4, 0x7c21d8\nMOV             W1, W19; int                                           ; +0xc8, 0x7c21dc\nLDP             X21, X22, [SP,#0x40+var_20]                            ; +0xcc, 0x7c21e0\nLDP             X19, X20, [SP,#0x40+var_30]                            ; +0xd0, 0x7c21e4\nLDP             X29, X30, [SP+0x40+var_40],#0x40                       ; +0xd4, 0x7c21e8\nB               _ZN16EditorSFXManager10playActionEi; EditorSFXManager::playAction(int) ; +0xd8, 0x7c21ec\nCMP             W20, #0x632                                            ; +0xdc, 0x7c21f0\nB.EQ            loc_7C2228                                             ; +0xe0, 0x7c21f4\nCMP             W20, #0x64F                                            ; +0xe4, 0x7c21f8\nB.NE            loc_7C22B4                                             ; +0xe8, 0x7c21fc\nMOV             W19, #0xFC                                             ; +0xec, 0x7c2200\nB               loc_7C21AC                                             ; +0xf0, 0x7c2204\nCMP             W20, #0x392                                            ; +0xf4, 0x7c2208\nB.EQ            loc_7C2200                                             ; +0xf8, 0x7c220c\nB.GT            loc_7C227C                                             ; +0xfc, 0x7c2210\nSUB             W20, W20, #0xC8                                        ; +0x100, 0x7c2214\nCMP             W20, #3                                                ; +0x104, 0x7c2218\nB.HI            loc_7C219C                                             ; +0x108, 0x7c221c\nMOV             W19, #0x109                                            ; +0x10c, 0x7c2220\nB               loc_7C21AC                                             ; +0x110, 0x7c2224\nMOV             W19, #0xFB                                             ; +0x114, 0x7c2228\nB               loc_7C21AC                                             ; +0x118, 0x7c222c\nADRL            X2, word_1142210                                       ; +0x11c, 0x7c2230\nLDRSH           W19, [X2,W21,UXTW#1]                                   ; +0x124, 0x7c2238\nCBNZ            W0, loc_7C229C                                         ; +0x128, 0x7c223c\nCMP             W19, #0x107                                            ; +0x12c, 0x7c2240\nB.NE            loc_7C21AC                                             ; +0x130, 0x7c2244\nCMP             W22, #2                                                ; +0x134, 0x7c2248\nB.EQ            loc_7C22C0                                             ; +0x138, 0x7c224c\nLDR             X2, [X1]                                               ; +0x13c, 0x7c2250\nMOV             X0, X1                                                 ; +0x140, 0x7c2254\nLDR             X1, [X2,#0x6C0]                                        ; +0x144, 0x7c2258\nBLR             X1                                                     ; +0x148, 0x7c225c\nUXTB            W0, W0                                                 ; +0x14c, 0x7c2260\nCBNZ            W0, loc_7C22C0                                         ; +0x150, 0x7c2264\nCMP             W22, #1                                                ; +0x154, 0x7c2268\nMOV             W19, #0x107                                            ; +0x158, 0x7c226c\nMOV             W0, #0xFA                                              ; +0x15c, 0x7c2270\nCSEL            W19, W0, W19, EQ                                       ; +0x160, 0x7c2274\nB               loc_7C21AC                                             ; +0x164, 0x7c2278\nCMP             W20, #0x396                                            ; +0x168, 0x7c227c\nB.EQ            loc_7C2294                                             ; +0x16c, 0x7c2280\nB.LT            loc_7C219C                                             ; +0x170, 0x7c2284\nSUB             W20, W20, #0x52F                                       ; +0x174, 0x7c2288\nCMP             W20, #1                                                ; +0x178, 0x7c228c\nB.HI            loc_7C219C                                             ; +0x17c, 0x7c2290\nMOV             W19, #0x108                                            ; +0x180, 0x7c2294\nB               loc_7C21AC                                             ; +0x184, 0x7c2298\nCMP             W19, #0x100                                            ; +0x188, 0x7c229c\nB.EQ            loc_7C22C8                                             ; +0x18c, 0x7c22a0\nCMP             W19, #0x107                                            ; +0x190, 0x7c22a4\nB.NE            loc_7C2240                                             ; +0x194, 0x7c22a8\nMOV             W19, #0xFE                                             ; +0x198, 0x7c22ac\nB               loc_7C21AC                                             ; +0x19c, 0x7c22b0\nCMP             W20, #0x630                                            ; +0x1a0, 0x7c22b4\nB.NE            loc_7C219C                                             ; +0x1a4, 0x7c22b8\nB               loc_7C2294                                             ; +0x1a8, 0x7c22bc\nMOV             W19, #0xFD                                             ; +0x1ac, 0x7c22c0\nB               loc_7C21AC                                             ; +0x1b0, 0x7c22c4\nMOV             W19, #0xFF                                             ; +0x1b4, 0x7c22c8\nB               loc_7C21AC                                             ; +0x1b8, 0x7c22cc", "xrefs": ["EditorUI::onCreate @ 0x7ca858", "<???> @ 0x58468"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}