Post Reply Home » Forums » MMO Forums » Age of Conan » Age of Conan Discussions

current Position ? : Age of Conan Discussions

Posted: May 29th, 2008
Total Posts:154 Joined:2006
Maybe I'm doing something wrong or do not understand this.

If I add a message box in the following should it not show a value it always = 0

MsgBox(0,"X Pos ",$playerX)

Code: Register to unlock hidden link

Global $playerdma, $playerX, $playerY, $playerZ, $playerSpeed, $playerSJ, $playerNFD 

$Process = 'ageofconan.exe' 
$PID = ProcessExists($Process) 
$OpenProcess = MemOpen(0x38, False, $PID) 

$playerdma = MemRead($OpenProcess, 0x0132894,'int', 4) 
$playerX = MemRead($OpenProcess, $playerdma + 0x2C,'float', 4) 
$playerY = MemRead($OpenProcess, $playerdma + 0x34,'float', 4) 
$playerZ = MemRead($OpenProcess, $playerdma+ 0x30,'float', 4)
$playerSpeed = MemRead($OpenProcess, $playerdma+ 0x150,'float', 4)

$playerSJ = MemRead($OpenProcess, $playerdma+ 0x17C,'int', 4)

$playerNFD = MemRead($OpenProcess, $playerdma+ 0x184,'int', 4) 

Sleep(4000)
MsgBox(0,"X Pos ",$playerX)


Func MemRead($i_hProcess, $i_lpBaseAddress, $s_Type ,$i_nSize) 
Local $hDll = DllOpen("kernel32.dll") 
If @error Then 
SetError(1) 
Return 0 
EndIf 
Local $v_Struct = DllStructCreate ($s_Type&'[' & $i_nSize & ']') 
Local $v_lpNumberOfBytesRead = '' 
DllCall($hDll, 'int', 'ReadProcessMemory', 'int', $i_hProcess, 'int', $i_lpBaseAddress, 'int', DllStructGetPtr ($v_Struct, 1), 'int', $i_nSize, 'int', $v_lpNumberOfBytesRead) 
If @error Then 
SetError(1) 
Return 0 
EndIf 
Local $v_Return = DllStructGetData ($v_Struct, 1) 
$v_Struct=0 
DllClose($hDll) 
Return $v_Return 
EndFunc 

Func MemOpen($i_dwDesiredAccess, $i_bInheritHandle, $i_dwProcessId) 

$ai_Handle = DllCall("kernel32.dll", 'int', 'OpenProcess', 'int', $i_dwDesiredAccess, 'int', $i_bInheritHandle, 'int', $i_dwProcessId) 
If @error Then 
SetError(1) 
Return 0 
EndIf 

Return $ai_Handle[0] 
EndFunc 

Func MemClose($i_hProcess) 

$av_CloseHandle = DllCall('kernel32.dll', 'int', 'CloseHandle', 'int', $i_hProcess) 
Return $av_CloseHandle[0] 

EndFunc 

Func MemWrite($i_hProcess, $i_lpBaseAddress, $s_Type ,$v_Inject, $i_nSize)
Local $hDll = DllOpen("kernel32.dll")
If @error Then
SetError(1)
Return 0
EndIf
$v_lpNumberOfBytesRead = ''
Local $v_Struct = DllStructCreate ($s_Type&'[' & $i_nSize & ']')
DllStructSetData ($v_Struct, 1, $v_Inject)

$i_Call = DllCall($hDll, 'int', 'WriteProcessMemory', 'int', $i_hProcess, 'int', $i_lpBaseAddress, 'int', DllStructGetPtr ($v_Struct, 1), 'int', $i_nSize, 'int', $v_lpNumberOfBytesRead)
If @error Then
SetError(1)
Return 0
EndIf
$v_Struct=0
DllClose($hDll)
Return $i_Call[0]
EndFunc
Posted: May 29th, 2008
Total Posts:67 Joined:2007
check my previous post, i included an aoc.au3 sample

[quote="binafus"]Maybe I'm doing something wrong or do not understand this.
Posted: June 27th, 2008
User avatar
Total Posts:9 Joined:2004
Don't suppose you guys can maybe put up a lil guide of how you got the offsets? I used to have a link to how you did it but have lost it :(
Posted: July 17th, 2008
Total Posts:77 Joined:2007
Code2007, I used your example (unmodified) and it is returning values of zero. I looked all over the web and these seem to be the same offsets that were posted in beta. Is it possible the mem locs have changed? If so do you know the current pointers.

Also, if you or anyone else has the time, could you post a guide on finding the more difficult offsets. I've found offests using CE only to find they change on restart. I am also having trouble with multi level pointers.
Ready to join the community? Click here and see all of the benefits!
blue large dotWho is online
Users browsing this forum: No registered users and 6 guests
Post Reply