#Recovery Mode

User Tag List

Results 1 to 3 of 3

FMA + Godmode Script

This is a discussion on FMA + Godmode Script within the Programming & Reversing General Discussion forums, part of the Programming & Reversing category; I've been trying to convert the FMA + Godmode script to c++ to use for a trainer but I'm having ...

  1. 07-26-2012, 11:01 PM
    #1

    The New Guy

    Expand


    • My Statistics

    Default FMA + Godmode Script

    I've been trying to convert the FMA + Godmode script to c++ to use for a trainer but I'm having difficulties with it and would appreciate if someone could tell me how exactly do I go about doing this. The script that I'm trying to convert is:

    Code:
    [enable]
    alloc(IntersectRectHook,128)
    label(intersectrect_return)
    label(return_true)
    label(return_false)
    
    
    IntersectRect:
    jmp IntersectRectHook
    intersectrect_return:
    
    
    IntersectRectHook:
    cmp [esp],0071E82E // dEM // 85 c0 75 0C 8B 5C ? ? 45
    je return_true
    cmp [esp],0071E076 // phsyical godmode // 85 C0 75 35 ? 4C ? ? ? 44
    je return_false
    mov edi,edi
    push ebp
    mov ebp,esp
    jmp intersectrect_return
    
    
    return_true:
    mov eax,1
    ret 0C
    
    
    return_false:
    mov eax,0
    ret 0C
    
    
    [disable]
    dealloc(IntersectRectHook)
    I believe that a codecave is used for this and I've been reading how to do codecaves through darkspace's tutorial but this script seems different from the codecaves/scripts he uses in his examples so I'm not sure how to go about doing this.
    I know that this script needs to be updated but I haven't had a chance to actually patch my game yet.

    Any help would be appreciated! Thanks in advance.

  2. 07-26-2012, 11:23 PM
    #2

    Mr. IDGAF

    Expand

    Disciple's Avatar
    • My Statistics

    Default Re: FMA + Godmode Script

    Code:
    unsigned long ulIntersectRect = (unsigned long)GetProcAddress(GetModuleHandle(L"user32.dll"), "IntersectRect");
    unsigned long ulIntersectRectRet = ulIntersectRect + 5;
    
    void __declspec(naked) FMA_ASM(){ 
        __asm { 
                cmp dword ptr [esp],0x0071ECEE // dEM
                je return_true
    			cmp [esp],0x00720916// phsyical godmode // 85 C0 75 35 ? 4C ? ? ? 44
    			je return_false
                mov edi,edi
                push ebp
                mov ebp,esp
                jmp dword ptr [ulIntersectRectRet]
    
                return_true:
                mov eax,1
                ret 0x0C
    
    			return_false:
    			mov eax,0
    			ret 0x0C
    
        } 
    }
    Make sure to update the addresses.
    Then here is the call:
    Code:
    void FMA(){
    		VirtualProtect((LPVOID)ulIntersectRect, 5, PAGE_EXECUTE_READWRITE, &dw_OldProtect);
    		Jump(ulIntersectRect, FMA_ASM, 0);
    		VirtualProtect((LPVOID)ulIntersectRect, 5, dw_OldProtect, &dw_OldProtect);
    }
    So then If checkbox is checked then call the FMA function.
    If you wanna add the other parts of the godmode you can.


    "To think, it's just little ol' me.
    Mr. Dont give a fuck, still won't leave"




  3. 07-31-2012, 03:15 PM
    #3

    MOFOS <3

    Expand

    moisiete's Avatar
    • My Statistics

    Default Re: FMA + Godmode Script

    Quote Originally Posted by Disciple
    [Dear Visitor, you're restricted from viewing links until you are registered & logged on.
    Click Here To Register Today
    Code:
    unsigned long ulIntersectRect = (unsigned long)GetProcAddress(GetModuleHandle(L"user32.dll"), "IntersectRect");
    unsigned long ulIntersectRectRet = ulIntersectRect + 5;
    
    void __declspec(naked) FMA_ASM(){ 
        __asm { 
                cmp dword ptr [esp],0x0071ECEE // dEM
                je return_true
    			cmp [esp],0x00720916// phsyical godmode // 85 C0 75 35 ? 4C ? ? ? 44
    			je return_false
                mov edi,edi
                push ebp
                mov ebp,esp
                jmp dword ptr [ulIntersectRectRet]
    
                return_true:
                mov eax,1
                ret 0x0C
    
    			return_false:
    			mov eax,0
    			ret 0x0C
    
        } 
    }
    Make sure to update the addresses.
    Then here is the call:
    Code:
    void FMA(){
    		VirtualProtect((LPVOID)ulIntersectRect, 5, PAGE_EXECUTE_READWRITE, &dw_OldProtect);
    		Jump(ulIntersectRect, FMA_ASM, 0);
    		VirtualProtect((LPVOID)ulIntersectRect, 5, dw_OldProtect, &dw_OldProtect);
    }
    So then If checkbox is checked then call the FMA function.
    If you wanna add the other parts of the godmode you can.
    asm hooks <3 detours gay

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •