{"type": "func", "start": 5371543296, "end": 5371543541, "name": "GJSmartTemplate::rotateBlockType", "pseudocode": "// \n// GJSmartTemplate::rotateBlockType from 0x1402b3f00 to 0x1402b3ff5 (245 bytes)\n// \n// 9 xrefs:\n// > GJSmartTemplate::rotateKey @ 0x1402b4559\n// > GJSmartTemplate::rotateKey @ 0x1402b4566\n// > GJSmartTemplate::rotateKey @ 0x1402b4573\n// > GJSmartTemplate::rotateKey @ 0x1402b457f\n// > GJSmartTemplate::rotateKey @ 0x1402b458b\n// > GJSmartTemplate::rotateKey @ 0x1402b4596\n// > GJSmartTemplate::rotateKey @ 0x1402b45a9\n// > GJSmartTemplate::rotateKey @ 0x1402b45b7\n// > GJSmartTemplate::rotateKey @ 0x1402b45c5\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\nSmartBlockType GJSmartTemplate::rotateBlockType(SmartBlockType a1, int a2)\n{\n  __int64 v2; // r9\n\n  if ( (unsigned int)(a1 - 48) > 1 && a2 > 0 )\n  {\n    v2 = (a2 - 1) / 0x5Au + 1;\n    do\n    {\n      switch ( a1 )\n      {\n        case NormalSlope1:\n          a1 = NormalSlope2;\n          break;\n        case NormalSlope2:\n          a1 = NormalSlope4;\n          break;\n        case NormalSlope3:\n          a1 = NormalSlope1;\n          break;\n        case NormalSlope4:\n          a1 = NormalSlope3;\n          break;\n        case WideSlope1:\n          a1 = WideSlope11;\n          break;\n        case WideSlope2:\n          a1 = WideSlope12;\n          break;\n        case WideSlope3:\n          a1 = WideSlope15;\n          break;\n        case WideSlope4:\n          a1 = WideSlope16;\n          break;\n        case WideSlope5:\n          a1 = WideSlope9;\n          break;\n        case WideSlope6:\n          a1 = WideSlope10;\n          break;\n        case WideSlope7:\n          a1 = WideSlope13;\n          break;\n        case WideSlope8:\n          a1 = WideSlope14;\n          break;\n        case WideSlope9:\n          a1 = WideSlope3;\n          break;\n        case WideSlope10:\n          a1 = WideSlope4;\n          break;\n        case WideSlope11:\n          a1 = WideSlope7;\n          break;\n        case WideSlope12:\n          a1 = WideSlope8;\n          break;\n        case WideSlope13:\n          a1 = WideSlope1;\n          break;\n        case WideSlope14:\n          a1 = WideSlope2;\n          break;\n        case WideSlope15:\n          a1 = WideSlope5;\n          break;\n        case WideSlope16:\n          a1 = WideSlope6;\n          break;\n        default:\n          break;\n      }\n      --v2;\n    }\n    while ( v2 );\n  }\n  return a1;\n}", "assembly": "; \n; GJSmartTemplate::rotateBlockType from 0x1402b3f00 to 0x1402b3ff5 (245 bytes)\n; \n; 9 xrefs:\n; > GJSmartTemplate::rotateKey @ 0x1402b4559\n; > GJSmartTemplate::rotateKey @ 0x1402b4566\n; > GJSmartTemplate::rotateKey @ 0x1402b4573\n; > GJSmartTemplate::rotateKey @ 0x1402b457f\n; > GJSmartTemplate::rotateKey @ 0x1402b458b\n; > GJSmartTemplate::rotateKey @ 0x1402b4596\n; > GJSmartTemplate::rotateKey @ 0x1402b45a9\n; > GJSmartTemplate::rotateKey @ 0x1402b45b7\n; > GJSmartTemplate::rotateKey @ 0x1402b45c5\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\nlea     eax, [rcx-30h]                                                 ; +0x0, 0x1402b3f00\ncmp     eax, 1                                                         ; +0x3, 0x1402b3f03\njbe     loc_1402B3FF2                                                  ; +0x6, 0x1402b3f06\ntest    edx, edx                                                       ; +0xc, 0x1402b3f0c\njle     loc_1402B3FF2                                                  ; +0xe, 0x1402b3f0e\nlea     r8d, [rdx-1]                                                   ; +0x14, 0x1402b3f14\nmov     eax, 6C16C16Dh                                                 ; +0x18, 0x1402b3f18\nmul     r8d                                                            ; +0x1d, 0x1402b3f1d\nsub     r8d, edx                                                       ; +0x20, 0x1402b3f20\nshr     r8d, 1                                                         ; +0x23, 0x1402b3f23\nlea     r9d, [rdx+r8]                                                  ; +0x26, 0x1402b3f26\nshr     r9d, 6                                                         ; +0x2a, 0x1402b3f2a\nlea     r8, cs:140000000h                                              ; +0x2e, 0x1402b3f2e\ninc     r9d                                                            ; +0x35, 0x1402b3f35\nnop     dword ptr [rax+rax+00000000h]                                  ; +0x38, 0x1402b3f38\nlea     eax, [rcx-32h]; switch 27 cases                                ; +0x40, 0x1402b3f40\ncmp     eax, 1Ah                                                       ; +0x43, 0x1402b3f43\nja      def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x46, 0x1402b3f46\ncdqe                                                                   ; +0x4c, 0x1402b3f4c\nmov     edx, ds:(jpt_1402B3F59 - 140000000h)[r8+rax*4]                 ; +0x4e, 0x1402b3f4e\nadd     rdx, r8                                                        ; +0x56, 0x1402b3f56\njmp     rdx; switch jump                                               ; +0x59, 0x1402b3f59\nmov     ecx, 33h ; '3'; jumptable 00000001402B3F59 case 50             ; +0x5b, 0x1402b3f5b\njmp     def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x60, 0x1402b3f60\nmov     ecx, 35h ; '5'; jumptable 00000001402B3F59 case 51             ; +0x65, 0x1402b3f65\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x6a, 0x1402b3f6a\nmov     ecx, 32h ; '2'; jumptable 00000001402B3F59 case 52             ; +0x6c, 0x1402b3f6c\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x71, 0x1402b3f71\nmov     ecx, 34h ; '4'; jumptable 00000001402B3F59 case 53             ; +0x73, 0x1402b3f73\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x78, 0x1402b3f78\nmov     ecx, 47h ; 'G'; jumptable 00000001402B3F59 case 54             ; +0x7a, 0x1402b3f7a\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x7f, 0x1402b3f7f\nmov     ecx, 4Bh ; 'K'; jumptable 00000001402B3F59 case 56             ; +0x81, 0x1402b3f81\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x86, 0x1402b3f86\nmov     ecx, 45h ; 'E'; jumptable 00000001402B3F59 case 65             ; +0x88, 0x1402b3f88\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x8d, 0x1402b3f8d\nmov     ecx, 49h ; 'I'; jumptable 00000001402B3F59 case 67             ; +0x8f, 0x1402b3f8f\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x94, 0x1402b3f94\nmov     ecx, 48h ; 'H'; jumptable 00000001402B3F59 case 55             ; +0x96, 0x1402b3f96\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0x9b, 0x1402b3f9b\nmov     ecx, 4Ch ; 'L'; jumptable 00000001402B3F59 case 57             ; +0x9d, 0x1402b3f9d\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xa2, 0x1402b3fa2\nmov     ecx, 46h ; 'F'; jumptable 00000001402B3F59 case 66             ; +0xa4, 0x1402b3fa4\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xa9, 0x1402b3fa9\nmov     ecx, 4Ah ; 'J'; jumptable 00000001402B3F59 case 68             ; +0xab, 0x1402b3fab\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xb0, 0x1402b3fb0\nmov     ecx, 38h ; '8'; jumptable 00000001402B3F59 case 69             ; +0xb2, 0x1402b3fb2\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xb7, 0x1402b3fb7\nmov     ecx, 43h ; 'C'; jumptable 00000001402B3F59 case 71             ; +0xb9, 0x1402b3fb9\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xbe, 0x1402b3fbe\nmov     ecx, 36h ; '6'; jumptable 00000001402B3F59 case 73             ; +0xc0, 0x1402b3fc0\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xc5, 0x1402b3fc5\nmov     ecx, 41h ; 'A'; jumptable 00000001402B3F59 case 75             ; +0xc7, 0x1402b3fc7\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xcc, 0x1402b3fcc\nmov     ecx, 39h ; '9'; jumptable 00000001402B3F59 case 70             ; +0xce, 0x1402b3fce\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xd3, 0x1402b3fd3\nmov     ecx, 44h ; 'D'; jumptable 00000001402B3F59 case 72             ; +0xd5, 0x1402b3fd5\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xda, 0x1402b3fda\nmov     ecx, 37h ; '7'; jumptable 00000001402B3F59 case 74             ; +0xdc, 0x1402b3fdc\njmp     short def_1402B3F59; jumptable 00000001402B3F59 default case, cases 58-64 ; +0xe1, 0x1402b3fe1\nmov     ecx, 42h ; 'B'; jumptable 00000001402B3F59 case 76             ; +0xe3, 0x1402b3fe3\nsub     r9, 1; jumptable 00000001402B3F59 default case, cases 58-64    ; +0xe8, 0x1402b3fe8\njnz     loc_1402B3F40                                                  ; +0xec, 0x1402b3fec\nmov     eax, ecx                                                       ; +0xf2, 0x1402b3ff2\nretn                                                                   ; +0xf4, 0x1402b3ff4", "xrefs": ["GJSmartTemplate::rotateKey @ 0x1402b4559", "GJSmartTemplate::rotateKey @ 0x1402b4566", "GJSmartTemplate::rotateKey @ 0x1402b4573", "GJSmartTemplate::rotateKey @ 0x1402b457f", "GJSmartTemplate::rotateKey @ 0x1402b458b", "GJSmartTemplate::rotateKey @ 0x1402b4596", "GJSmartTemplate::rotateKey @ 0x1402b45a9", "GJSmartTemplate::rotateKey @ 0x1402b45b7", "GJSmartTemplate::rotateKey @ 0x1402b45c5"], "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"}