// // SecretLayer4::getErrorMessage from 0x4f0e54 to 0x4f1060 (524 bytes) // // 1 xrefs: // > SecretLayer4::onSubmit @ 0x4f14fa // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // SecretLayer4 *__fastcall SecretLayer4::getErrorMessage(SecretLayer4 *this, int a2, char *a3, char *a4) { int v6; // r3 SecretLayer4 *v7; // r0 char *v8; // r1 cocos2d::CCString *v9; // r0 char *CString; // r0 cocos2d::CCString *v11; // r0 char *v12; // r0 cocos2d::CCString *v13; // r0 char *v14; // r0 char *v16[2]; // [sp+8h] [bp-8h] BYREF v16[0] = a3; v16[1] = a4; v6 = *(_DWORD *)(a2 + 348); if ( v6 >= 0 ) { *(_DWORD *)(a2 + 348) = v6 + 1; } else { rand(); *(_DWORD *)(a2 + 348) = lroundf(); } if ( *(int *)(a2 + 348) > 29 ) *(_DWORD *)(a2 + 348) = 0; switch ( *(_DWORD *)(a2 + 348) ) { case 0: v7 = this; v8 = "No, just no"; goto LABEL_40; case 1: v7 = this; v8 = "Swing and a miss!"; goto LABEL_40; case 2: v7 = this; v8 = "I told you, it wont work..."; goto LABEL_40; case 3: v7 = this; v8 = "Door is now open. Oh wait, no it's not."; goto LABEL_40; case 4: v7 = this; v8 = "Is that actually your guess?"; goto LABEL_40; case 5: GameManager::sharedState(); sub_775C20(v16); v9 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"Go home %s.", v16[0]); CString = (char *)cocos2d::CCString::getCString(v9); sub_776584((int)this, CString); goto LABEL_37; case 6: v7 = this; v8 = "Nope"; goto LABEL_40; case 7: v7 = this; v8 = "Give up, please"; goto LABEL_40; case 8: v7 = this; v8 = "Door is still locked"; goto LABEL_40; case 9: v7 = this; v8 = "That tickles!"; goto LABEL_40; case 0xA: v7 = this; v8 = "Try harder please"; goto LABEL_40; case 0xB: v7 = this; v8 = "Don't make me angry"; goto LABEL_40; case 0xC: v7 = this; v8 = "You won't like me when im angry..."; goto LABEL_40; case 0xD: v7 = this; v8 = "Oh no, you just unlocked... NOTHING"; goto LABEL_40; case 0xE: v7 = this; v8 = "Only 3 attempts left!"; goto LABEL_40; case 0xF: v7 = this; v8 = "Only 2 attempts left!"; goto LABEL_40; case 0x10: v7 = this; v8 = "LAST ATTEMPT!"; goto LABEL_40; case 0x11: v7 = this; v8 = "Just kidding, unlimited attempts"; goto LABEL_40; case 0x12: v7 = this; v8 = "Maybe you should do something else?"; goto LABEL_40; case 0x13: v7 = this; v8 = "This is getting ridiculus..."; goto LABEL_40; case 0x14: v7 = this; v8 = "Go collect some stars"; goto LABEL_40; case 0x15: v7 = this; v8 = "How about no?"; goto LABEL_40; case 0x16: GameManager::sharedState(); sub_775C20(v16); v11 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%s, please give up...", v16[0]); v12 = (char *)cocos2d::CCString::getCString(v11); sub_776584((int)this, v12); goto LABEL_37; case 0x17: v7 = this; v8 = "Error, error. Bad answers."; goto LABEL_40; case 0x18: v7 = this; v8 = "Failure"; goto LABEL_40; case 0x19: v7 = this; v8 = "May I suggest thinking?"; goto LABEL_40; case 0x1A: v7 = this; v8 = "WRONG"; goto LABEL_40; case 0x1B: v7 = this; v8 = "You're hopeless..."; goto LABEL_40; case 0x1C: v7 = this; v8 = "Really, still here?"; goto LABEL_40; case 0x1D: GameManager::sharedState(); sub_775C20(v16); v13 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"What kind of name is %s anyway?", v16[0]); v14 = (char *)cocos2d::CCString::getCString(v13); sub_776584((int)this, v14); LABEL_37: sub_774008(v16); return this; case 0x1E: v7 = this; v8 = "Not gonna work."; goto LABEL_40; default: v7 = this; v8 = "Don't touch that!"; LABEL_40: sub_776584((int)v7, v8); return this; } }
GD Web Decomp Icon

GD Web Decomp

Raw Source