{"type": "func", "start": 4295058180, "end": 4295058252, "name": "GJEffectManager::timeForItem", "pseudocode": "// \n// GJEffectManager::timeForItem from 0x100016304 to 0x10001634c (72 bytes)\n// \n// 2 xrefs:\n// > GJBaseGameLayer::getItemValue @ 0x1001fba38\n// > GJBaseGameLayer::updateTimerLabels @ 0x1001fc4cc\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\ndouble __fastcall GJEffectManager::timeForItem(GJEffectManager *a1, int a2)\n{\n  int v2; // w8\n  __int64 v3; // x0\n  int v5; // [xsp+Ch] [xbp-4h] BYREF\n\n  v2 = a2 & ~(a2 >> 31);\n  if ( v2 >= 9999 )\n    v2 = 9999;\n  v5 = v2;\n  v3 = sub_100018814(&a1->m_timerItemMap, &v5);\n  if ( v3 )\n    return *(double *)(v3 + 32);\n  else\n    return 0.0;\n}", "assembly": "; \n; GJEffectManager::timeForItem from 0x100016304 to 0x10001634c (72 bytes)\n; \n; 2 xrefs:\n; > GJBaseGameLayer::getItemValue @ 0x1001fba38\n; > GJBaseGameLayer::updateTimerLabels @ 0x1001fc4cc\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\nSUB             SP, SP, #0x20                                          ; +0x0, 0x100016304\nSTP             X29, X30, [SP,#0x10+var_s0]                            ; +0x4, 0x100016308\nADD             X29, SP, #0x10                                         ; +0x8, 0x10001630c\nBIC             W8, W1, W1,ASR#31                                      ; +0xc, 0x100016310\nMOV             W9, #0x270F                                            ; +0x10, 0x100016314\nCMP             W8, W9                                                 ; +0x14, 0x100016318\nCSEL            W8, W8, W9, LT                                         ; +0x18, 0x10001631c\nSTUR            W8, [X29,#var_4]                                       ; +0x1c, 0x100016320\nADD             X0, X0, #0x390                                         ; +0x20, 0x100016324\nSUB             X1, X29, #-var_4                                       ; +0x24, 0x100016328\nBL              sub_100018814                                          ; +0x28, 0x10001632c\nCBZ             X0, loc_10001633C                                      ; +0x2c, 0x100016330\nLDR             D0, [X0,#0x20]                                         ; +0x30, 0x100016334\nB               loc_100016340                                          ; +0x34, 0x100016338\nFMOV            D0, XZR                                                ; +0x38, 0x10001633c\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x3c, 0x100016340\nADD             SP, SP, #0x20 ; ' '                                    ; +0x40, 0x100016344\nRET                                                                    ; +0x44, 0x100016348", "xrefs": ["GJBaseGameLayer::getItemValue @ 0x1001fba38", "GJBaseGameLayer::updateTimerLabels @ 0x1001fc4cc"], "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"}