Results 1 to 5 of 5
  1. #1
    sekaidown's Avatar
    Join Date
    Feb 2017
    Gender
    female
    Location
    Fortaleza - Brazil
    Posts
    5
    Reputation
    10
    Thanks
    0

    Question ReadProcessMemory C++

    I'm trying to read the memory of a game based on Tibia, but I'm not having good results.

    I was able to find the static address and the offset.
    I can go on the Cheat Engine and manually write it as it reads the address.

    Can someone help me ?
    It can be C #, C ++ or VB.



  2. #2
    alissons's Avatar
    Join Date
    Apr 2019
    Gender
    male
    Posts
    4
    Reputation
    10
    Thanks
    0
    Watch the tutorials on youtube for do it.

  3. #3
    aimer1337's Avatar
    Join Date
    Apr 2019
    Gender
    male
    Posts
    4
    Reputation
    10
    Thanks
    1
    Code:
    using handle = std::unique_ptr<std::remove_pointer_t<HANDLE>, decltype(&CloseHandle)>;
    
    handle h_game(OpenProcess(game's pid, false, PROCESS_ALL_ACCESS), &CloseHandle);
    
    std::uintptr_t& deref_address = 0;
    ReadProcessMemory(h_game.get(), reinterpret_cast<void*>(0x00FBAAC0), &deref_address, sizeof(std::uintptr_t), nullptr);
    
    double& health = 0;
    ReadProcessMemory(h_game.get(), reinterpret_cast<void*>(deref_address + 0x388), &health, sizeof(double), nullptr);
    
    std::printf("health: %d\n", health);

  4. #4
    Elpiero86's Avatar
    Join Date
    Apr 2019
    Gender
    male
    Posts
    20
    Reputation
    10
    Thanks
    9
    Youtube has really good C++ tutorials

  5. #5
    kraneq's Avatar
    Join Date
    May 2019
    Gender
    male
    Posts
    4
    Reputation
    10
    Thanks
    0
    You basicly need to read the module + base addres, and then for every single offset you need to read it into a variable and then read that variable + the next offset into a new variable and so on.

Similar Threads

  1. [Tutorial] ReadProcessMemory
    By aanthonyz in forum C++/C Programming
    Replies: 27
    Last Post: 07-30-2016, 06:05 AM
  2. [Source Code] C# WriteProcessMemory/ReadProcessMemory
    By Kantanomo in forum C# Programming
    Replies: 10
    Last Post: 09-03-2012, 04:21 PM
  3. [Help] ReadProcessMemory - Read 8 byte [solved]
    By pyton789 in forum Visual Basic Programming
    Replies: 7
    Last Post: 09-18-2011, 07:49 AM
  4. ReadProcessMemory
    By Void in forum C++/C Programming
    Replies: 17
    Last Post: 04-03-2010, 07:12 AM
  5. Write/ReadProcessMemory errors
    By Dragonion in forum General Game Hacking
    Replies: 0
    Last Post: 09-23-2008, 08:11 AM