{"type": "func", "start": 341940, "end": 341988, "name": "sub_537B4", "pseudocode": "// \n// sub_537B4 from 0x537b4 to 0x537e4 (48 bytes)\n// \n// 14 xrefs:\n// > sub_536F8 @ 0x53784\n// > sub_582D4 @ 0x5832e\n// > sub_58398 @ 0x58446\n// > sub_58CA8 @ 0x58f18\n// > sub_58CA8 @ 0x58f9e\n// > sub_58CA8 @ 0x59010\n// > sub_5B0B8 @ 0x5b1ec\n// > sub_613C4 @ 0x6147c\n// > sub_642EC @ 0x6432e\n// > sub_6806C @ 0x6813a\n// > sub_6846C @ 0x684d8\n// > sub_A7620 @ 0xa7646\n// > sub_A8916 @ 0xa8932\n// > sub_A8B34 @ 0xa8bb2\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nint __fastcall sub_537B4(int a1)\n{\n  int v1; // r2\n  int result; // r0\n\n  v1 = a1 - 2;\n  result = 1;\n  switch ( v1 )\n  {\n    case 0:\n      return result;\n    case 1:\n      goto LABEL_4;\n    case 2:\n    case 3:\n    case 4:\n      result = a1;\n      break;\n    case 5:\n      result = 8;\n      break;\n    case 6:\n      result = 12;\n      break;\n    default:\n      if ( a1 == 1000 )\nLABEL_4:\n        result = 2;\n      else\n        result = 0;\n      break;\n  }\n  return result;\n}", "assembly": "; \n; sub_537B4 from 0x537b4 to 0x537e4 (48 bytes)\n; \n; 14 xrefs:\n; > sub_536F8 @ 0x53784\n; > sub_582D4 @ 0x5832e\n; > sub_58398 @ 0x58446\n; > sub_58CA8 @ 0x58f18\n; > sub_58CA8 @ 0x58f9e\n; > sub_58CA8 @ 0x59010\n; > sub_5B0B8 @ 0x5b1ec\n; > sub_613C4 @ 0x6147c\n; > sub_642EC @ 0x6432e\n; > sub_6806C @ 0x6813a\n; > sub_6846C @ 0x684d8\n; > sub_A7620 @ 0xa7646\n; > sub_A8916 @ 0xa8932\n; > sub_A8B34 @ 0xa8bb2\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nSUBS            R2, R0, #2; switch 7 cases                             ; +0x0, 0x537b4\nMOV             R1, R0                                                 ; +0x2, 0x537b6\nCMP             R2, #6                                                 ; +0x4, 0x537b8\nBHI             def_537BE; jumptable 000537BE default case             ; +0x6, 0x537ba\nMOVS            R0, #1                                                 ; +0x8, 0x537bc\nTBB.W           [PC,R2]; switch jump                                   ; +0xa, 0x537be\nDCB 0x10; jump table for switch statement                              ; +0xe, 0x537c2\nDCB 9                                                                  ; +0xf, 0x537c3\nDCB 4                                                                  ; +0x10, 0x537c4\nDCB 4                                                                  ; +0x11, 0x537c5\nDCB 4                                                                  ; +0x12, 0x537c6\nDCB 0xB                                                                ; +0x13, 0x537c7\nDCB 0xD                                                                ; +0x14, 0x537c8\nALIGN 2                                                                ; +0x15, 0x537c9\nMOV             R0, R1; jumptable 000537BE cases 4-6                   ; +0x16, 0x537ca\nBX              LR                                                     ; +0x18, 0x537cc\nCMP.W           R1, #0x3E8; jumptable 000537BE default case            ; +0x1a, 0x537ce\nBNE             loc_537E0                                              ; +0x1e, 0x537d2\nMOVS            R0, #2; jumptable 000537BE case 3                      ; +0x20, 0x537d4\nBX              LR                                                     ; +0x22, 0x537d6\nMOVS            R0, #8; jumptable 000537BE case 7                      ; +0x24, 0x537d8\nBX              LR                                                     ; +0x26, 0x537da\nMOVS            R0, #0xC; jumptable 000537BE case 8                    ; +0x28, 0x537dc\nBX              LR                                                     ; +0x2a, 0x537de\nMOVS            R0, #0                                                 ; +0x2c, 0x537e0\nBX              LR; jumptable 000537BE case 2                          ; +0x2e, 0x537e2", "xrefs": ["sub_536F8 @ 0x53784", "sub_582D4 @ 0x5832e", "sub_58398 @ 0x58446", "sub_58CA8 @ 0x58f18", "sub_58CA8 @ 0x58f9e", "sub_58CA8 @ 0x59010", "sub_5B0B8 @ 0x5b1ec", "sub_613C4 @ 0x6147c", "sub_642EC @ 0x6432e", "sub_6806C @ 0x6813a", "sub_6846C @ 0x684d8", "sub_A7620 @ 0xa7646", "sub_A8916 @ 0xa8932", "sub_A8B34 @ 0xa8bb2"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}