// // sub_EC4970 from 0xec4970 to 0xec4a8c (284 bytes) // // 4 xrefs: // > sub_EC4A8C @ 0xec4b00 // > sub_EC4D34 @ 0xec4e80 // > sub_EC51E8 @ 0xec5278 // > sub_EC5510 @ 0xec565c // // This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True! // // 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 13:11:34 +0000 // __int64 __fastcall sub_EC4970(unsigned __int16 a1, __int16 *a2) { int v2; // w2 __int64 result; // x0 int v4; // w1 __int16 v5; // w2 int v6; // w1 __int16 v7; // w2 int v8; // w1 __int16 v9; // w2 int v10; // w1 v2 = a1 - 1; result = 0; switch ( v2 ) { case 0: case 4: v9 = *a2; result = 2; v10 = *a2 & 0xFFFB; if ( v10 != 2 ) { result = 3; if ( v10 != 3 ) result = ((v9 - 4) & 0xFFFB) == 0; } break; case 1: case 5: v7 = *a2; result = 2; v8 = *a2 & 0xFFFB; if ( v8 != 1 ) { result = 1; if ( v8 != 3 ) { if ( ((v7 - 4) & 0xFFFB) != 0 ) result = 0; else result = 3; } } break; case 2: case 6: v5 = *a2; result = 3; v6 = *a2 & 0xFFFB; if ( v6 != 1 ) { result = 1; if ( v6 != 2 ) { if ( ((v5 - 4) & 0xFFFB) != 0 ) result = 0; else result = 2; } } break; case 3: case 7: result = 1; v4 = *a2 & 0xFFFB; if ( v4 != 1 ) { result = 3; if ( v4 != 2 ) { if ( v4 == 3 ) result = 2; else result = 0; } } break; default: return result; } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source