{"type": "func", "start": 4295146316, "end": 4295146592, "name": "LevelInfoLayer::onRateStars", "pseudocode": "// \n// LevelInfoLayer::onRateStars from 0x10002bb4c to 0x10002bc60 (276 bytes)\n// \n// 2 xrefs:\n// > LevelInfoLayer::FLAlert_Clicked @ 0x10002e5f0\n// > LevelInfoLayer::init @ 0x1000288c0\n// \n// This function is hookable on this platform (idp: arm, 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:57:28 +0000\n// \n\n__int64 __fastcall LevelInfoLayer::onRateStars(__int64 result)\n{\n  __int64 v1; // x19\n  __int64 updated; // x0\n  __int64 v3; // x0\n  __int64 v4; // x0\n  __int64 v5; // x0\n  __int64 v6; // x20\n  __int64 isPlatformer; // x0\n  _QWORD *v8; // x0\n  __int64 v9; // x19\n  void *__p[2]; // [xsp+8h] [xbp-28h] BYREF\n  char v11; // [xsp+1Fh] [xbp-11h]\n\n  if ( (*(_BYTE *)(result + 488) & 1) == 0 )\n  {\n    v1 = result;\n    updated = GameManager::sharedState(result);\n    if ( *(_DWORD *)(updated + 660) == *(_DWORD *)(updated + 664) )\n    {\n      v3 = GameLevelManager::sharedState(updated);\n      updated = GameLevelManager::updateUserScore(v3);\n    }\n    v4 = GameManager::sharedState(updated);\n    if ( (*(_BYTE *)(v4 + 933) & 1) != 0 )\n    {\n      v5 = *(_QWORD *)(v1 + 504);\n      v6 = (unsigned int)(*(_DWORD *)(v5 + 328) - *(_DWORD *)(v5 + 332));\n      isPlatformer = GJGameLevel::isPlatformer(v5);\n      v8 = (_QWORD *)RateStarsLayer::create(v6, isPlatformer, 0);\n      v8[94] = v1 + 424;\n      return (*(__int64 (__fastcall **)(_QWORD *))(*v8 + 1312LL))(v8);\n    }\n    else\n    {\n      *(_BYTE *)(GameManager::sharedState(v4) + 933) = 1;\n      sub_100009900(\n        __p,\n        \"<co>Auto:</c> 1 Star or Moon\\n\"\n        \"<cl>Easy:</c> 2 Stars or Moons\\n\"\n        \"<cg>Normal:</c> 3 Stars or Moons\\n\"\n        \"<cy>Hard:</c> 4 to 5 Stars or Moons\\n\"\n        \"<cr>Harder:</c> 6 to 7 Stars or Moons\\n\"\n        \"<ca>Insane:</c> 8 to 9 Stars or Moons\\n\"\n        \"<cp>Demon:</c> 10 Stars or Moons\\n\"\n        \"(These values are not assigned before a rating is manually given by RobTop.)\");\n      v9 = FLAlertLayer::create_1(v1 + 440, \"Rating guide\", __p, \"OK\", 0, 300.0);\n      if ( v11 < 0 )\n        operator delete(__p[0]);\n      (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v9 + 72LL))(v9, 8);\n      return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v9 + 1312LL))(v9);\n    }\n  }\n  return result;\n}", "assembly": "; \n; LevelInfoLayer::onRateStars from 0x10002bb4c to 0x10002bc60 (276 bytes)\n; \n; 2 xrefs:\n; > LevelInfoLayer::FLAlert_Clicked @ 0x10002e5f0\n; > LevelInfoLayer::init @ 0x1000288c0\n; \n; This function is hookable on this platform (idp: arm, 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:57:28 +0000\n; \nSUB             SP, SP, #0x40                                          ; +0x0, 0x10002bb4c\nSTP             X20, X19, [SP,#0x30+var_10]                            ; +0x4, 0x10002bb50\nSTP             X29, X30, [SP,#0x30+var_s0]                            ; +0x8, 0x10002bb54\nADD             X29, SP, #0x30                                         ; +0xc, 0x10002bb58\nLDRB            W8, [X0,#0x1E8]                                        ; +0x10, 0x10002bb5c\nTBNZ            W8, #0, loc_10002BC50                                  ; +0x14, 0x10002bb60\nMOV             X19, X0                                                ; +0x18, 0x10002bb64\nBL              GameManager__sharedState                               ; +0x1c, 0x10002bb68\nLDR             W8, [X0,#0x294]                                        ; +0x20, 0x10002bb6c\nLDR             W9, [X0,#0x298]                                        ; +0x24, 0x10002bb70\nCMP             W8, W9                                                 ; +0x28, 0x10002bb74\nB.NE            loc_10002BB84                                          ; +0x2c, 0x10002bb78\nBL              GameLevelManager__sharedState                          ; +0x30, 0x10002bb7c\nBL              GameLevelManager__updateUserScore                      ; +0x34, 0x10002bb80\nBL              GameManager__sharedState                               ; +0x38, 0x10002bb84\nLDRB            W8, [X0,#0x3A5]                                        ; +0x3c, 0x10002bb88\nTBZ             W8, #0, loc_10002BBD4                                  ; +0x40, 0x10002bb8c\nLDR             X0, [X19,#0x1F8]                                       ; +0x44, 0x10002bb90\nLDR             W8, [X0,#0x148]                                        ; +0x48, 0x10002bb94\nLDR             W9, [X0,#0x14C]                                        ; +0x4c, 0x10002bb98\nSUB             W20, W8, W9                                            ; +0x50, 0x10002bb9c\nBL              GJGameLevel__isPlatformer                              ; +0x54, 0x10002bba0\nMOV             X1, X0                                                 ; +0x58, 0x10002bba4\nMOV             X0, X20                                                ; +0x5c, 0x10002bba8\nMOV             W2, #0                                                 ; +0x60, 0x10002bbac\nBL              RateStarsLayer__create                                 ; +0x64, 0x10002bbb0\nADD             X8, X19, #0x1A8                                        ; +0x68, 0x10002bbb4\nSTR             X8, [X0,#0x2F0]                                        ; +0x6c, 0x10002bbb8\nLDR             X8, [X0]                                               ; +0x70, 0x10002bbbc\nLDR             X1, [X8,#0x520]                                        ; +0x74, 0x10002bbc0\nLDP             X29, X30, [SP,#0x30+var_s0]                            ; +0x78, 0x10002bbc4\nLDP             X20, X19, [SP,#0x30+var_10]                            ; +0x7c, 0x10002bbc8\nADD             SP, SP, #0x40 ; '@'                                    ; +0x80, 0x10002bbcc\nBR              X1                                                     ; +0x84, 0x10002bbd0\nBL              GameManager__sharedState                               ; +0x88, 0x10002bbd4\nMOV             W8, #1                                                 ; +0x8c, 0x10002bbd8\nSTRB            W8, [X0,#0x3A5]                                        ; +0x90, 0x10002bbdc\nADRL            X1, aCoAutoC1StarOr; \"<co>Auto:</c> 1 Star or Moon\\n<cl>Easy:\"... ; +0x94, 0x10002bbe0\nADD             X0, SP, #0x30+__p; int                                 ; +0x9c, 0x10002bbe8\nBL              sub_100009900                                          ; +0xa0, 0x10002bbec\nADRL            X1, aRatingGuide; \"Rating guide\"                       ; +0xa4, 0x10002bbf0\nADRL            X3, aOk; \"OK\"                                          ; +0xac, 0x10002bbf8\nMOV             W8, #0x43960000                                        ; +0xb4, 0x10002bc00\nFMOV            S0, W8                                                 ; +0xb8, 0x10002bc04\nADD             X0, X19, #0x1B8                                        ; +0xbc, 0x10002bc08\nADD             X2, SP, #0x30+__p                                      ; +0xc0, 0x10002bc0c\nMOV             X4, #0                                                 ; +0xc4, 0x10002bc10\nBL              FLAlertLayer__create_1                                 ; +0xc8, 0x10002bc14\nMOV             X19, X0                                                ; +0xcc, 0x10002bc18\nLDRSB           W8, [SP,#0x30+var_11]                                  ; +0xd0, 0x10002bc1c\nTBZ             W8, #0x1F, loc_10002BC2C                               ; +0xd4, 0x10002bc20\nLDR             X0, [SP,#0x30+__p]; __p                                ; +0xd8, 0x10002bc24\nBL              __ZdlPv; operator delete(void *)                       ; +0xdc, 0x10002bc28\nLDR             X8, [X19]                                              ; +0xe0, 0x10002bc2c\nLDR             X8, [X8,#0x48]                                         ; +0xe4, 0x10002bc30\nMOV             X0, X19                                                ; +0xe8, 0x10002bc34\nMOV             W1, #8                                                 ; +0xec, 0x10002bc38\nBLR             X8                                                     ; +0xf0, 0x10002bc3c\nLDR             X8, [X19]                                              ; +0xf4, 0x10002bc40\nLDR             X8, [X8,#0x520]                                        ; +0xf8, 0x10002bc44\nMOV             X0, X19                                                ; +0xfc, 0x10002bc48\nBLR             X8                                                     ; +0x100, 0x10002bc4c\nLDP             X29, X30, [SP,#0x30+var_s0]                            ; +0x104, 0x10002bc50\nLDP             X20, X19, [SP,#0x30+var_10]                            ; +0x108, 0x10002bc54\nADD             SP, SP, #0x40 ; '@'                                    ; +0x10c, 0x10002bc58\nRET                                                                    ; +0x110, 0x10002bc5c", "xrefs": ["LevelInfoLayer::FLAlert_Clicked @ 0x10002e5f0", "LevelInfoLayer::init @ 0x1000288c0"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "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"}