{"type": "func", "start": 4295440080, "end": 4295440167, "name": "GJChallengeItem::incrementCount", "pseudocode": "// \n// GJChallengeItem::incrementCount from 0x1000736d0 to 0x100073727 (87 bytes)\n// \n// 0 xrefs:\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\nvoid __fastcall GJChallengeItem::incrementCount(GJChallengeItem *a1, int a2)\n{\n  int v2; // ebx\n  int v3; // eax\n  int v4; // eax\n\n  if ( !a1->m_canClaim )\n  {\n    v2 = a2 + a1->m_count.random - a1->m_count.seed;\n    v3 = a1->m_goal.random - a1->m_goal.seed;\n    if ( v2 >= v3 )\n    {\n      a1->m_canClaim = 1;\n      v2 = v3;\n    }\n    a1->m_count.value = v2;\n    v4 = (int)(float)((float)((float)rand() * 4.6566129e-10) * 1000.0);\n    a1->m_count.seed = v4;\n    a1->m_count.random = v4 + v2;\n  }\n}", "assembly": "; \n; GJChallengeItem::incrementCount from 0x1000736d0 to 0x100073727 (87 bytes)\n; \n; 0 xrefs:\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\ncmp     byte ptr [rdi+64h], 0                                          ; +0x0, 0x1000736d0\njnz     short locret_100073726                                         ; +0x4, 0x1000736d4\npush    rbp                                                            ; +0x6, 0x1000736d6\nmov     rbp, rsp                                                       ; +0x7, 0x1000736d7\npush    r14                                                            ; +0xa, 0x1000736da\npush    rbx                                                            ; +0xc, 0x1000736dc\nmov     ebx, [rdi+3Ch]                                                 ; +0xd, 0x1000736dd\nmov     eax, [rdi+54h]                                                 ; +0x10, 0x1000736e0\nsub     ebx, [rdi+40h]                                                 ; +0x13, 0x1000736e3\nadd     ebx, esi                                                       ; +0x16, 0x1000736e6\nsub     eax, [rdi+58h]                                                 ; +0x18, 0x1000736e8\ncmp     ebx, eax                                                       ; +0x1b, 0x1000736eb\njl      short loc_1000736F5                                            ; +0x1d, 0x1000736ed\nmov     byte ptr [rdi+64h], 1                                          ; +0x1f, 0x1000736ef\nmov     ebx, eax                                                       ; +0x23, 0x1000736f3\nmov     [rdi+44h], ebx                                                 ; +0x25, 0x1000736f5\nmov     r14, rdi                                                       ; +0x28, 0x1000736f8\ncall    _rand                                                          ; +0x2b, 0x1000736fb\ncvtsi2ss xmm0, eax                                                     ; +0x30, 0x100073700\nmulss   xmm0, cs:dword_100815710                                       ; +0x34, 0x100073704\nmulss   xmm0, cs:dword_1008152B8                                       ; +0x3c, 0x10007370c\ncvttss2si eax, xmm0                                                    ; +0x44, 0x100073714\nmov     [r14+40h], eax                                                 ; +0x48, 0x100073718\nadd     ebx, eax                                                       ; +0x4c, 0x10007371c\nmov     [r14+3Ch], ebx                                                 ; +0x4e, 0x10007371e\npop     rbx                                                            ; +0x52, 0x100073722\npop     r14                                                            ; +0x53, 0x100073723\npop     rbp                                                            ; +0x55, 0x100073725\nretn                                                                   ; +0x56, 0x100073726", "xrefs": [], "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"}