Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 15:44

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



KDMemory (AutoIt 32 & 64 Bit)

Discussion on KDMemory (AutoIt 32 & 64 Bit) within the AutoIt forum part of the Coders Den category.

Reply
 
Old 07/06/2014, 15:42   #46
 
elite*gold: 0
Join Date: Mar 2009
Posts: 7,260
Received Thanks: 33,149
Quote:
Originally Posted by Chemist.Service View Post
Edit: Wichtige Frage, funktioniert das überhaupt wenn ich den StaticCast (0x025BDB80) zu den Offsets hinzufüge. Im Grunde wird diese Adresse ja genau wie die andere auch auf die BaseAddress addiert....
Nein und nein. Die $weightOffsets werden immer auf den ausgelesenen Wert addiert, das "StaticOffset" wird allerdings vor dem Lesen addiert. Das ist auch schon dein erster Fehler. Dein zweiter Fehler ist, dass du dein Coding an der falschen Stelle hinzugefügt hast. Angesichts der Tatsache, dass mein Beispielscript bereits ein "StaticOffset" verwendet, welches du nur anpassen hättest müssen, sollte ein allgemeines Verständnis vorhanden sein.

Ich habe mein Beispielscript an deinen Daten entsprechend angepasst:

Da dein Zielprozess ein 64 Bit Prozess ist kannst du keine 32 Bit Anwendung erstellen. Mit dieser könntest du nicht auf den gesamten Speicher zugreifen. Den entsprechenden Fehlercode gibt meine UDF auch aus ().
KDeluxe is offline  
Old 11/16/2016, 14:01   #47
 
elite*gold: 0
Join Date: Jan 2014
Posts: 43
Received Thanks: 1
Hi

I have problem with value of memory, i tryed to compile 64 bit 32 bit, run as admin nothing works, but this works only with _KDMemory_ReadProcessString(), if i put _KDMemory_ReadProcessMemory() i get error 15, extended 1. So i dont know if problem is in UDF or something else.

Code is in Spoiler



LiveLong23 is offline  
Old 02/02/2017, 13:26   #48
 
elite*gold: 0
Join Date: Apr 2013
Posts: 21
Received Thanks: 2
Any error documentation?
Getting error 12, extended 5
_KDMemory_GetModuleBaseAddress
sitapea1337 is offline  
Old 02/02/2017, 23:46   #49
 
elite*gold: 39
Join Date: Jun 2016
Posts: 269
Received Thanks: 805
Quote:
Originally Posted by sitapea1337 View Post
Any error documentation?
Getting error 12, extended 5
_KDMemory_GetModuleBaseAddress
says the following:
Code:
ERROR_ACCESS_DENIED
    5 (0x5)
    Access is denied.
By looking at the UDF (line 385-391) the error is set when the call of returns an invalid handle.

Easiest solution would be to add '#RequireAdmin' at the start of your script, I guess?
(depending on the needed rights to access the process like that)
gοd is offline  
Old 02/03/2017, 10:45   #50
 
elite*gold: 0
Join Date: Apr 2013
Posts: 21
Received Thanks: 2
Already done that, this is my script

Getting error when trying to read module base address.

The interesting part is - when I check with disassembler, addresses are 8-bytes, not 4-bytes and Gw2-64.exe base (checked with CE) is also 8-bytes long.

Code:
;~ #AutoIt3Wrapper_UseX64=n ; 32 Bit application
#AutoIt3Wrapper_UseX64=y ; 64 Bit application

#RequireAdmin
#include "KDMemory.au3"
#include <MsgBoxConstants.au3>
Global $windowname = "Guild Wars 2"
Global $process = "Gw2-64.exe"
Global $lootkey = "f"
Global $pbO1 = 0x01D4CD00 ; Player base offset 1 (process + offset)
Global $pbO2 = 0x28 ; Player base offset 2 (pbO1 + offset)
Global $lootO = 0x1D49EFB ; Loot info offset

If @AutoItX64 == 0 Then
    MsgBox(0, "Error", "AutoIt isn't running as x64!")
    Exit
EndIf

If not IsAdmin() Then
    MsgBox(0, "Error", "AutoIt doesn't have administrator rights!")
    Exit 0
EndIf

$pID = ProcessExists($process)
If $pID == 0 Then
    MsgBox(0,"Error","Process '" & $process &"' not running!",0)
    Exit 0
EndIf

$handle = _KDMemory_OpenProcess($pID)
If @error Then
    MsgBox(0,"Error","Error opening process!" & @CRLF & "@error: " & @error & ", @extended: " & @extended,0)
    Exit 0
EndIf

$pBase = _KDMemory_GetModuleBaseAddress($handle, $process)
If @error Then
    MsgBox(0,"Error","Error getting process base!" & @CRLF & "@error: " & @error & ", @extended: " & @extended,0)
    Exit 0
EndIf
sitapea1337 is offline  
Old 02/03/2017, 14:07   #51
 
elite*gold: 39
Join Date: Jun 2016
Posts: 269
Received Thanks: 805
Quote:
Originally Posted by sitapea1337 View Post
Already done that, this is my script

Getting error when trying to read module base address.

The interesting part is - when I check with disassembler, addresses are 8-bytes, not 4-bytes and Gw2-64.exe base (checked with CE) is also 8-bytes long.
[..]
Nothing unusual for a x64 process which is using QWORDs.
--
As far as I can see there are no erros regarding your code. Is anything blocking the access, e.g. an antivirus? Does your process have any protection like by an anticheat?
gοd is offline  
Old 02/03/2017, 15:20   #52
 
elite*gold: 0
Join Date: Apr 2013
Posts: 21
Received Thanks: 2
Guild Wars 2 shouldn't have anti-cheat system, at least nothing block memory reading.
I can easily RPM with C++, also get modules with C++, but I really want to use AutoIt and this library

Anyways, I'll check it out, debug it a bit and I'll see what's blocking it.
Quote:
Originally Posted by Zyntex View Post
Nothing unusual for a x64 process which is using QWORDs.
--
As far as I can see there are no erros regarding your code. Is anything blocking the access, e.g. an antivirus? Does your process have any protection like by an anticheat?
sitapea1337 is offline  
Thanks
1 User
Old 04/02/2017, 21:17   #53
 
elite*gold: 0
Join Date: Mar 2017
Posts: 4
Received Thanks: 0
Question

Hey KDeluxe, funktioniert das immernoch mit einem Windows 10 x64 (alle Updates) und aktuellem AutoIt?
Immer wenn ich Offsets nutzen möchte, schlägt das Lesen fehl. In AutoIt lese ich, dass sich etwas mit Arrays verändert hat...

Auch Dein Beispiel für das CE Tutorial funktioniert nicht mehr... "Can't read memory!"
Crowmer is offline  
Reply

Tags
baseaddress, kd, kdeluxe, memory, pointer




All times are GMT +1. The time now is 15:45.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.