Results 1 to 2 of 2
  1. #1
    metin2zocker's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Posts
    35
    Reputation
    10
    Thanks
    2
    My Mood
    Yeehaw

    Hacks with delphi 7..[DE]

    Hello guys...
    is there a way to make hacks with delphi 7??
    if yes can you make a tutorial pls on howto make a button that changes a MW2 console command like : ju***eigh or whatelse From 400 to 800?
    PLS be awesome and help me....

    in this forum i only find c++/c#.. tutorials but i have delphhi 7 in the school and ive i start learning c++ ill forget delpgi..=(

    MY DREAM: MAKE A MW2 (soon other games) Trainer
    To do list/Zu erledigen Liste:

    10 Posts
    30 Posts
    50 Posts
    75 Posts
    100 Posts
    150 Posts
    200 Post
    275 Posts
    450 Posts
    Hack MW2
    Play Cage-Match with 18 players
    10th-Prestige without hacking
    Got you to read thos SHI* List

  2. #2
    0rbit's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Location
    Ireland.
    Posts
    212
    Reputation
    15
    Thanks
    724
    My Mood
    Amused
    Well the easiest way I've found is to find your addresses and such as usual in Cheat Engine or whatever program you use, then use the Read/WriteProcessMemory APIs.

    A MW2 trainer would be easy enough as the addresses tend to be static (so you won't need to deal with them changing every time). Anyway, here's a few easy examples to get you started:


    Code:
    // This code will disable the timer on Just Cause 2's demo
    // allowing you to play for however long you want.
    
    procedure TfrmMain.btnDisableClick(Sender: TObject);
    var
      hProcess,HandleWindow: THandle;
      ProcessID,temp:cardinal;
      i:integer;
    const
      addresses:array [0..2] of dword=($00538748,$00538749,$0053874A);
      patches:array [0..2] of byte=($90,$90,$90);
    begin
      HandleWindow :=FindWindow(nil,'Just Cause 2 Demo');
      GetWindowThreadProcessId(HandleWindow,@ProcessID);
      hProcess := OpenProcess(PROCESS_ALL_ACCESS,FALSE,ProcessID);
    
      for i:=0 to 2 do WriteProcessMemory(hProcess,ptr(addresses[i]),@patches[i],1,temp);
    
      if hProcess <> 0 then
        CloseHandle(hProcess);
      end;
    The above code is what you'd use if you were patching the program's code, ie. Cancelling an effect out.

    So step-by-step through that code, we define two arrays, which are constant. The "addresses" array contains the addresses we wish to write to, and the "patches" array contains the bytes we'll be inserting.
    Next, we find the Just Cause 2 Demo window, and hook the process.
    After this, we run a loop, using "i" as our counter. This will loop 3 times (0,1,2), and for each run of the loop, a different byte is written to a different address (these are read from the arrays we already defined).
    Lastly, we run a check to release the handle on the process.


    =


    Code:
    // This code will set the Drift Multiplier in (Race Driver) GRID v1.00 to x99
    
    procedure TfrmMain.Drift99Click(Sender: TObject);
    var
      hProcess,HandleWindow: THandle;
      DriftMul:integer;
      ProcessID,temp:cardinal;
      address:dword;
    begin
      DriftMul:=99;
      HandleWindow :=FindWindow(nil,'GRID');
      GetWindowThreadProcessId(HandleWindow,@ProcessID);
      hProcess := OpenProcess(PROCESS_ALL_ACCESS,FALSE,ProcessID);
    
      ReadProcessMemory(hProcess,ptr($343F77DC),@address,sizeOf(address),temp);
      address:=address+$18;
      
    WriteProcessMemory(hProcess,ptr(address),@DriftMul,sizeOf(DriftMul),temp);
      if hProcess <> 0 then
        CloseHandle(hProcess);
    end;
    Now this code is a small bit more complicated, as it deals with some DMA, but it is an example of writing a variable.

    With this kind of editing, you won't be patching addresses with hex bytes as before, but writing "normal" data to addresses. In this example we are setting an integer value to 99. As such, there is only one bit of data to write, and only one address, so we no longer need loops or arrays.

    As with the first snippet of code, we start out by finding and hooking the process, and setting up the data we'll need.
    We want to write our data (myInt) to a particular address in the game's memory, however this address changes each time the game is run due to DMA so we must first find the address.
    Its base is always stored at the address 343F77DC, so we use ReadProcessMemory to find the data it stores, and we put that data in the "address" variable. This is only the base to a larger structure however, and the value we want is stored at [address+18h], so we preform this calculation before we continue.

    Now that we have our address we can do as before and use WriteProcessMemory to write our value (myInt) to the address.
    Finally as before, we run a check to release the handle on the process.


    =


    Code:
    // This code will set the Prestige of the user according to their own choice in CoD:MW2 v1.0.184
    
    procedure TfrmMain.btnApplyPrestigeClick(Sender: TObject);
    var
      hProcess,HandleWindow: THandle;
      ProcessID,temp:cardinal;
      prestige:integer;
    const
      address:dword=$01B2B89C;
    begin
      prestige:=0;
      if StrToInt(editPrestige.Text)<=10 then prestige:=StrToInt(editPrestige.Text);
    
      HandleWindow :=FindWindow(nil,'Modern Warfare 2');
      GetWindowThreadProcessId(HandleWindow,@ProcessID);
      hProcess := OpenProcess(PROCESS_ALL_ACCESS,FALSE,ProcessID);
    
      WriteProcessMemory(hProcess,ptr(address),@prestige,sizeOf(Prestige),temp);
    
      if hProcess <> 0 then
        CloseHandle(hProcess);
      end;
    Okay, in our final example, we'll work with Call of Duty: Modern Warfare 2. In this game, the addresses are static and so we don't need to do much work like we did in the GRID example. This is once again setting the value of a variable.

    We set out by setting the prestige variable to 0. Then we check a TEdit and read its value, convert it to an integer, and use that instead. If the text entered is not a valid integer, we still have prestige set to 0, rather than a crazy value that could be automatically set. If it is a valid integer, we make sure it's a valid prestige by making sure it's less than or equal to 10.

    We then find the window as before, and write our value to the address containing the prestige, and do our final check and unhook.

    Now at a guess what I'd do for ju***eigh is to set that to a value (such as 100), open cheatengine, search the value, change again (to for example 150), search for the new value, and repeat until you've found it. Do note however that that is bannable by VAC so do be careful.

    I hope this helps! If you have any other questions or anything feel free to ask/pm me, I'd be glad to help.

    - 0rbit

    I read all PMs and VMs.
    If you add me on MSN, PM me here so I know who you are, or I will not accept.

    Free Trainer Template: Want this trainer template with your name on it? PM me. (I ain't using it)
    My Stuffs: IWIFix v1.11 | HLoad v1.00b | MW2Hack v1.0 Final | [Tut] Ingame Console/Textbox in DirectX
    Current status: Being awesome.. Duh

Similar Threads

  1. HL2 Hack With Aimbot|ESP| And much, Much more.
    By quin123 in forum CounterStrike (CS) 1.6 Hacks / Counter Strike: Source (CSS) Hacks
    Replies: 10
    Last Post: 04-03-2009, 12:57 PM
  2. Hack with rapid fire mp7k and wall hack
    By traggone in forum WarRock - International Hacks
    Replies: 4
    Last Post: 02-21-2007, 07:39 PM
  3. How To Get Hacks With Cheat Engine 5.3?
    By naomelembro14 in forum WarRock - International Hacks
    Replies: 1
    Last Post: 02-20-2007, 01:26 AM
  4. Godmode Hack with Ollydbg Tutorial
    By emisand in forum Gunz Hacks
    Replies: 46
    Last Post: 02-20-2006, 06:12 PM
  5. Can u use the gain experience hack with 1 player
    By mjt20mik in forum WarRock - International Hacks
    Replies: 7
    Last Post: 02-05-2006, 02:20 AM