Jump to content
Gooby

NomadMemory problem :)

Recommended Posts

Gooby

Hello! Im new to autoit memory, using NomadMemory.au3, the problem is it doesn't read from addresses like "3CCC6B63640", the value im getting is '0'. But, it works for adresses with less strings like "076BB5FC" or similar as shown on screens. Any idea what I'm doing wrong? I would like to use it with pointers later on, but need to get correct result first :/ Screenshoots and scripts:

Screenshots of cheat engine + script:

screens.jpg

My script:

#include <NomadMemory.au3>
#include <WindowsConstants.au3>
#include <MsgBoxConstants.au3>
#include <String.au3>
test()

Func test()
    GUISetState(@SW_HIDE)
    $PID = "6644"
    $MemoryOpen = _MemoryOpen($PID)
    Sleep(500)
    $a = _MemoryRead ('0x' & '00050000', $MemoryOpen, 'double')
    $b = _MemoryRead ('0x' & '3CCC6B63640', $MemoryOpen, 'double')
    ConsoleWrite('a = ' & $a & @CRLF)
    ConsoleWrite('b = ' & $b & @CRLF)
    Exit
 EndFunc

 

_MemoryRead:

Func _MemoryRead($iv_Address, $ah_Handle, $sv_Type = 'dword')
    
    If Not IsArray($ah_Handle) Then
        SetError(1)
        Return 0
    EndIf
    
    Local $v_Buffer = DllStructCreate($sv_Type)
    
    If @Error Then
        SetError(@Error + 1)
        Return 0
    EndIf
    
    DllCall($ah_Handle[0], 'int', 'ReadProcessMemory', 'int', $ah_Handle[1], 'int', $iv_Address, 'ptr', DllStructGetPtr($v_Buffer), 'int', DllStructGetSize($v_Buffer), 'int', '')
    
    If Not @Error Then
        Local $v_Value = DllStructGetData($v_Buffer, 1)
        Return $v_Value
    Else
        SetError(6)
        Return 0
    EndIf
    
EndFunc

 

Share this post


Link to post
Share on other sites
Earthshine

did you read the forum rules?


My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Gooby
16 minutes ago, Earthshine said:

did you read the forum rules?

Yes, so what?

Share this post


Link to post
Share on other sites
Earthshine

the part about game automation and stuff? bots? yeah?


My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Gooby

Yes, also I'm reading the forum for years from time to time, just my first post. Still, decided to ask more experienced users for help, as I can't find solution myself. If you know the answer, I would be happy to get any tips, so I can get into memory, pointers and stuff deeper. 

Share this post


Link to post
Share on other sites
Earthshine

if you want to get into memory and pointers then C and C++ are your tools. good luck.

  • Thanks 1

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Melba23

Earthshine, and several other rather over-eager wannabee Mods,

Stop fishing for reasons to get the thread closed. Unless there is prima facie evidence of gaming we prefer to give the benefit of the doubt. Just do not respond - or report the thread as was done in this case.

M23


Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Gooby

Thanks, I will study that if I find more time to get familiar with it. Back to the question, can I solve the problem using autoit and NomadMemory // other udfs? A warm hug for any tips :D

Share this post


Link to post
Share on other sites
Earthshine
Posted (edited)

so it's cool?

hint, use google or your favorite search engine

type in: autoit memory udf

click on first link. i think that might help you, or just click link below and read through

 

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine
  • Thanks 1

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Gooby

Thanks, I will use Memory udf and try to get the values ;) 

Share this post


Link to post
Share on other sites
Gooby

So, I started writing in c++ and met the same problem. It is compiler, compiling for 32bits, not 64, that's why I couldn't get values from that adressess, downloaded one for x64 and its all okay. Will be the same for autoit, if it uses 32 bits - you may select an option during installation between 32/64, not sure if NomadMemory supports x64. C seems more friendly for my needs, gonna stick with it for my project, thanks for the tips!

  • Like 1

Share this post


Link to post
Share on other sites
Earthshine
Posted (edited)

Glad to be of any service! C is AWESOME mate. Oh, I've loved her so long (a Neil Young Song but I feel that way about it)

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×