{"type": "func", "start": 6443745500, "end": 6443745687, "name": "sub_18013C0DC", "pseudocode": "// \n// sub_18013C0DC from 0x18013c0dc to 0x18013c197 (187 bytes)\n// \n// 3 xrefs:\n// > _wcsicmp_l @ 0x180134e1d\n// > _wcsicmp_l @ 0x180134e58\n// > <???> @ 0x1802039b0\n// \n// This function is hookable on this platform (idp: pc, 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 10:55:02 +0000\n// \n\n__int64 __fastcall sub_18013C0DC(unsigned __int16 a1, struct __crt_locale_pointers *a2)\n{\n  __int64 result; // rax\n  unsigned __int16 v3; // dx\n  __int64 v4; // rcx\n  int v5; // eax\n  __int64 v6; // [rsp+30h] [rbp-28h] BYREF\n  __int64 v7; // [rsp+38h] [rbp-20h]\n  char v8; // [rsp+48h] [rbp-10h]\n  unsigned __int16 v9; // [rsp+60h] [rbp+8h] BYREF\n  unsigned __int16 v10; // [rsp+70h] [rbp+18h] BYREF\n\n  v9 = a1;\n  result = 0xFFFF;\n  if ( a1 != 0xFFFF )\n  {\n    _LocaleUpdate::_LocaleUpdate((_LocaleUpdate *)&v6, a2);\n    v3 = v9;\n    if ( v9 >= 0x100u )\n    {\n      v4 = *(_QWORD *)(v7 + 312);\n      if ( v4 )\n      {\n        v5 = _crtLCMapStringW(v4, 256, &v9, 1, &v10, 1);\n        v3 = v9;\n        if ( v5 )\n          v3 = v10;\n      }\n    }\n    else if ( (wctype[(unsigned __int8)v9 + 1] & 1) != 0 )\n    {\n      v3 = *(unsigned __int8 *)(*(_QWORD *)(v7 + 272) + (unsigned __int8)v9);\n    }\n    else\n    {\n      v3 = (unsigned __int8)v9;\n    }\n    if ( v8 )\n      *(_DWORD *)(v6 + 936) &= ~2u;\n    return v3;\n  }\n  return result;\n}", "assembly": "; \n; sub_18013C0DC from 0x18013c0dc to 0x18013c197 (187 bytes)\n; \n; 3 xrefs:\n; > _wcsicmp_l @ 0x180134e1d\n; > _wcsicmp_l @ 0x180134e58\n; > <???> @ 0x1802039b0\n; \n; This function is hookable on this platform (idp: pc, 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 10:55:02 +0000\n; \nmov     [rsp+arg_0], cx                                                ; +0x0, 0x18013c0dc\nsub     rsp, 58h                                                       ; +0x5, 0x18013c0e1\nmov     eax, 0FFFFh                                                    ; +0x9, 0x18013c0e5\ncmp     cx, ax                                                         ; +0xe, 0x18013c0ea\njz      loc_18013C192                                                  ; +0x11, 0x18013c0ed\nlea     rcx, [rsp+58h+var_28]; this                                    ; +0x17, 0x18013c0f3\ncall    ??0_LocaleUpdate@@QEAA@QEAU__crt_locale_pointers@@@Z; _LocaleUpdate::_LocaleUpdate(__crt_locale_pointers * const) ; +0x1c, 0x18013c0f8\nmovzx   edx, [rsp+58h+arg_0]                                           ; +0x21, 0x18013c0fd\nmov     r10d, 100h                                                     ; +0x26, 0x18013c102\ncmp     dx, r10w                                                       ; +0x2c, 0x18013c108\njnb     short loc_18013C138                                            ; +0x30, 0x18013c10c\nmovzx   eax, dl                                                        ; +0x32, 0x18013c10e\nlea     rcx, _wctype+2                                                 ; +0x35, 0x18013c111\ntest    byte ptr [rcx+rax*2], 1                                        ; +0x3c, 0x18013c118\njz      short loc_18013C133                                            ; +0x40, 0x18013c11c\nmov     rax, [rsp+58h+var_20]                                          ; +0x42, 0x18013c11e\nmovzx   edx, dl                                                        ; +0x47, 0x18013c123\nmov     rcx, [rax+110h]                                                ; +0x4a, 0x18013c126\nmovzx   edx, byte ptr [rcx+rdx]                                        ; +0x51, 0x18013c12d\njmp     short loc_18013C17C                                            ; +0x55, 0x18013c131\nmovzx   edx, dl                                                        ; +0x57, 0x18013c133\njmp     short loc_18013C17C                                            ; +0x5a, 0x18013c136\nmov     rax, [rsp+58h+var_20]                                          ; +0x5c, 0x18013c138\nmov     rcx, [rax+138h]                                                ; +0x61, 0x18013c13d\ntest    rcx, rcx                                                       ; +0x68, 0x18013c144\njz      short loc_18013C17C                                            ; +0x6b, 0x18013c147\nlea     rax, [rsp+58h+arg_10]                                          ; +0x6d, 0x18013c149\nmov     [rsp+58h+var_30], 1                                            ; +0x72, 0x18013c14e\nmov     r9d, 1                                                         ; +0x7a, 0x18013c156\nmov     [rsp+58h+var_38], rax                                          ; +0x80, 0x18013c15c\nlea     r8, [rsp+58h+arg_0]                                            ; +0x85, 0x18013c161\nmov     edx, r10d                                                      ; +0x8a, 0x18013c166\ncall    __crtLCMapStringW                                              ; +0x8d, 0x18013c169\nmovzx   edx, [rsp+58h+arg_0]                                           ; +0x92, 0x18013c16e\ntest    eax, eax                                                       ; +0x97, 0x18013c173\njz      short loc_18013C17C                                            ; +0x99, 0x18013c175\nmovzx   edx, [rsp+58h+arg_10]                                          ; +0x9b, 0x18013c177\ncmp     [rsp+58h+var_10], 0                                            ; +0xa0, 0x18013c17c\njz      short loc_18013C18F                                            ; +0xa5, 0x18013c181\nmov     rcx, [rsp+58h+var_28]                                          ; +0xa7, 0x18013c183\nand     dword ptr [rcx+3A8h], 0FFFFFFFDh                               ; +0xac, 0x18013c188\nmovzx   eax, dx                                                        ; +0xb3, 0x18013c18f\nadd     rsp, 58h                                                       ; +0xb6, 0x18013c192\nretn                                                                   ; +0xba, 0x18013c196", "xrefs": ["_wcsicmp_l @ 0x180134e1d", "_wcsicmp_l @ 0x180134e58", "<???> @ 0x1802039b0"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "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"}