{"type": "func", "start": 5369139536, "end": 5369139946, "name": "GameToolbox::intToShortString", "pseudocode": "// \n// GameToolbox::intToShortString from 0x140069150 to 0x1400692ea (410 bytes)\n// \n// 8 xrefs:\n// > LevelCell::loadCustomLevelCell @ 0x1400b031c\n// > LevelCell::loadCustomLevelCell @ 0x1400b04ae\n// > LevelListCell::loadFromList @ 0x1400bf954\n// > LevelListCell::loadFromList @ 0x1400bfacf\n// > LevelListLayer::updateStatsArt @ 0x1403057ac\n// > LevelListLayer::updateStatsArt @ 0x14030592f\n// > LevelListLayer::updateStatsArt @ 0x140305fb4\n// > <???> @ 0x1406c5e68\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\n// Hidden C++ exception states: #wind=1\n_QWORD *__fastcall GameToolbox::intToShortString(_QWORD *a1, int a2)\n{\n  float v4; // xmm0_4\n  void *v5; // rax\n  _BYTE *v6; // rax\n  size_t v7; // r8\n  _OWORD v9[2]; // [rsp+20h] [rbp-248h] BYREF\n  _BYTE v10[528]; // [rsp+40h] [rbp-228h] BYREF\n\n  *(_QWORD *)&v9[0] = a1;\n  fmt::BasicWriter<char>::BasicWriter<char>(v10);\n  if ( a2 < 0 )\n  {\n    a2 = -a2;\n    *(_QWORD *)&v9[0] = &word_140533640;\n    *((_QWORD *)&v9[0] + 1) = 0;\n    fmt::BasicWriter<char>::operator<<(v10, v9);\n  }\n  if ( a2 >= 1000 )\n  {\n    v4 = (float)a2;\n    if ( a2 >= 10000 )\n    {\n      if ( a2 >= 1000000 )\n      {\n        floorf(v4 / 100000.0);\n        fmt::BasicWriter<char>::operator<<(v10);\n        v5 = &unk_14053363C;\n        goto LABEL_11;\n      }\n      floorf(v4 / 1000.0);\n    }\n    else\n    {\n      floorf(v4 / 100.0);\n    }\n    fmt::BasicWriter<char>::operator<<(v10);\n    v5 = &unk_140533638;\nLABEL_11:\n    v9[0] = (unsigned __int64)v5;\n    fmt::BasicWriter<char>::operator<<(v10, v9);\n    goto LABEL_12;\n  }\n  fmt::BasicWriter<char>::operator<<(v10, (unsigned int)a2);\nLABEL_12:\n  v6 = (_BYTE *)fmt::BasicWriter<char>::c_str(v10);\n  *(_OWORD *)a1 = 0;\n  a1[2] = 0;\n  a1[3] = 0;\n  v7 = -1;\n  do\n    ++v7;\n  while ( v6[v7] );\n  sub_14003A930(a1, v6, v7);\n  fmt::BasicWriter<char>::~BasicWriter<char>(v10);\n  return a1;\n}", "assembly": "; \n; GameToolbox::intToShortString from 0x140069150 to 0x1400692ea (410 bytes)\n; \n; 8 xrefs:\n; > LevelCell::loadCustomLevelCell @ 0x1400b031c\n; > LevelCell::loadCustomLevelCell @ 0x1400b04ae\n; > LevelListCell::loadFromList @ 0x1400bf954\n; > LevelListCell::loadFromList @ 0x1400bfacf\n; > LevelListLayer::updateStatsArt @ 0x1403057ac\n; > LevelListLayer::updateStatsArt @ 0x14030592f\n; > LevelListLayer::updateStatsArt @ 0x140305fb4\n; > <???> @ 0x1406c5e68\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\nmov     [rsp+arg_10], rbx                                              ; +0x0, 0x140069150\nmov     [rsp+arg_18], rsi                                              ; +0x5, 0x140069155\npush    rdi                                                            ; +0xa, 0x14006915a\nsub     rsp, 260h                                                      ; +0xb, 0x14006915b\nmov     rax, cs:__security_cookie                                      ; +0x12, 0x140069162\nxor     rax, rsp                                                       ; +0x19, 0x140069169\nmov     [rsp+268h+var_18], rax                                         ; +0x1c, 0x14006916c\nmov     ebx, edx                                                       ; +0x24, 0x140069174\nmov     rdi, rcx                                                       ; +0x26, 0x140069176\nmov     qword ptr [rsp+268h+var_248], rcx                              ; +0x29, 0x140069179\nxor     esi, esi                                                       ; +0x2e, 0x14006917e\nlea     rcx, [rsp+268h+var_228]                                        ; +0x30, 0x140069180\ncall    cs:??0?$BasicWriter@D@fmt@@QEAA@XZ; fmt::BasicWriter<char>::BasicWriter<char>(void) ; +0x35, 0x140069185\nnop                                                                    ; +0x3b, 0x14006918b\ntest    ebx, ebx                                                       ; +0x3c, 0x14006918c\njns     short loc_1400691BE                                            ; +0x3e, 0x14006918e\nneg     ebx                                                            ; +0x40, 0x140069190\nlea     rax, word_140533640                                            ; +0x42, 0x140069192\nmov     qword ptr [rsp+268h+var_248], rax                              ; +0x49, 0x140069199\nmov     qword ptr [rsp+268h+var_248+8], rsi                            ; +0x4e, 0x14006919e\nmovaps  xmm0, [rsp+268h+var_248]                                       ; +0x53, 0x1400691a3\nmovdqa  [rsp+268h+var_248], xmm0                                       ; +0x58, 0x1400691a8\nlea     rdx, [rsp+268h+var_248]                                        ; +0x5e, 0x1400691ae\nlea     rcx, [rsp+268h+var_228]                                        ; +0x63, 0x1400691b3\ncall    cs:??6?$BasicWriter@D@fmt@@QEAAAEAV01@V?$BasicStringRef@D@1@@Z; fmt::BasicWriter<char>::operator<<(fmt::BasicStringRef<char>) ; +0x68, 0x1400691b8\ncmp     ebx, 3E8h                                                      ; +0x6e, 0x1400691be\njge     short loc_1400691D8                                            ; +0x74, 0x1400691c4\nmov     edx, ebx                                                       ; +0x76, 0x1400691c6\nlea     rcx, [rsp+268h+var_228]                                        ; +0x78, 0x1400691c8\ncall    cs:??6?$BasicWriter@D@fmt@@QEAAAEAV01@H@Z; fmt::BasicWriter<char>::operator<<(int) ; +0x7d, 0x1400691cd\njmp     loc_140069281                                                  ; +0x83, 0x1400691d3\nmovd    xmm0, ebx                                                      ; +0x88, 0x1400691d8\ncvtdq2ps xmm0, xmm0                                                    ; +0x8c, 0x1400691dc\ncmp     ebx, 2710h                                                     ; +0x8f, 0x1400691df\njge     short loc_140069217                                            ; +0x95, 0x1400691e5\ndivss   xmm0, cs:dword_1406232BC; X                                    ; +0x97, 0x1400691e7\ncall    floorf                                                         ; +0x9f, 0x1400691ef\ndivss   xmm0, cs:flt_14062307C                                         ; +0xa4, 0x1400691f4\nxorps   xmm1, xmm1                                                     ; +0xac, 0x1400691fc\ncvtss2sd xmm1, xmm0                                                    ; +0xaf, 0x1400691ff\nlea     rcx, [rsp+268h+var_228]                                        ; +0xb3, 0x140069203\ncall    cs:??6?$BasicWriter@D@fmt@@QEAAAEAV01@N@Z; fmt::BasicWriter<char>::operator<<(double) ; +0xb8, 0x140069208\nlea     rax, unk_140533638                                             ; +0xbe, 0x14006920e\njmp     short loc_14006925C                                            ; +0xc5, 0x140069215\ncmp     ebx, 0F4240h                                                   ; +0xc7, 0x140069217\njge     short loc_14006922E                                            ; +0xcd, 0x14006921d\ndivss   xmm0, cs:dword_14062350C; X                                    ; +0xcf, 0x14006921f\ncall    floorf                                                         ; +0xd7, 0x140069227\njmp     short loc_1400691FC                                            ; +0xdc, 0x14006922c\ndivss   xmm0, cs:dword_140623660; X                                    ; +0xde, 0x14006922e\ncall    floorf                                                         ; +0xe6, 0x140069236\ndivss   xmm0, cs:flt_14062307C                                         ; +0xeb, 0x14006923b\nxorps   xmm1, xmm1                                                     ; +0xf3, 0x140069243\ncvtss2sd xmm1, xmm0                                                    ; +0xf6, 0x140069246\nlea     rcx, [rsp+268h+var_228]                                        ; +0xfa, 0x14006924a\ncall    cs:??6?$BasicWriter@D@fmt@@QEAAAEAV01@N@Z; fmt::BasicWriter<char>::operator<<(double) ; +0xff, 0x14006924f\nlea     rax, unk_14053363C                                             ; +0x105, 0x140069255\nmov     qword ptr [rsp+268h+var_248], rax                              ; +0x10c, 0x14006925c\nmov     qword ptr [rsp+268h+var_248+8], rsi                            ; +0x111, 0x140069261\nmovaps  xmm0, [rsp+268h+var_248]                                       ; +0x116, 0x140069266\nmovdqa  [rsp+268h+var_248], xmm0                                       ; +0x11b, 0x14006926b\nlea     rdx, [rsp+268h+var_248]                                        ; +0x121, 0x140069271\nlea     rcx, [rsp+268h+var_228]                                        ; +0x126, 0x140069276\ncall    cs:??6?$BasicWriter@D@fmt@@QEAAAEAV01@V?$BasicStringRef@D@1@@Z; fmt::BasicWriter<char>::operator<<(fmt::BasicStringRef<char>) ; +0x12b, 0x14006927b\nlea     rcx, [rsp+268h+var_228]                                        ; +0x131, 0x140069281\ncall    cs:?c_str@?$BasicWriter@D@fmt@@QEBAPEBDXZ; fmt::BasicWriter<char>::c_str(void) ; +0x136, 0x140069286\nxorps   xmm0, xmm0                                                     ; +0x13c, 0x14006928c\nmovups  xmmword ptr [rdi], xmm0                                        ; +0x13f, 0x14006928f\nmov     [rdi+10h], rsi                                                 ; +0x142, 0x140069292\nmov     [rdi+18h], rsi                                                 ; +0x146, 0x140069296\nmov     r8, 0FFFFFFFFFFFFFFFFh                                         ; +0x14a, 0x14006929a\ninc     r8                                                             ; +0x151, 0x1400692a1\ncmp     byte ptr [rax+r8], 0                                           ; +0x154, 0x1400692a4\njnz     short loc_1400692A1                                            ; +0x159, 0x1400692a9\nmov     rdx, rax                                                       ; +0x15b, 0x1400692ab\nmov     rcx, rdi                                                       ; +0x15e, 0x1400692ae\ncall    sub_14003A930                                                  ; +0x161, 0x1400692b1\nnop                                                                    ; +0x166, 0x1400692b6\nlea     rcx, [rsp+268h+var_228]                                        ; +0x167, 0x1400692b7\ncall    cs:__imp_??1?$BasicWriter@D@fmt@@QEAA@XZ; fmt::BasicWriter<char>::~BasicWriter<char>(void) ; +0x16c, 0x1400692bc\nmov     rax, rdi                                                       ; +0x172, 0x1400692c2\nmov     rcx, [rsp+268h+var_18]                                         ; +0x175, 0x1400692c5\nxor     rcx, rsp; StackCookie                                          ; +0x17d, 0x1400692cd\ncall    __security_check_cookie                                        ; +0x180, 0x1400692d0\nlea     r11, [rsp+268h+var_8]                                          ; +0x185, 0x1400692d5\nmov     rbx, [r11+20h]                                                 ; +0x18d, 0x1400692dd\nmov     rsi, [r11+28h]                                                 ; +0x191, 0x1400692e1\nmov     rsp, r11                                                       ; +0x195, 0x1400692e5\npop     rdi                                                            ; +0x198, 0x1400692e8\nretn                                                                   ; +0x199, 0x1400692e9", "xrefs": ["LevelCell::loadCustomLevelCell @ 0x1400b031c", "LevelCell::loadCustomLevelCell @ 0x1400b04ae", "LevelListCell::loadFromList @ 0x1400bf954", "LevelListCell::loadFromList @ 0x1400bfacf", "LevelListLayer::updateStatsArt @ 0x1403057ac", "LevelListLayer::updateStatsArt @ 0x14030592f", "LevelListLayer::updateStatsArt @ 0x140305fb4", "<???> @ 0x1406c5e68"], "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"}