Jump to content

Recommended Posts

Posted

i should really doccument my functions more :D

I'm used to one of the first memfunctions written for autoit but when i look at this one i just get confused... could you please write simple instructions for your function with examples?

Syntax of use would be very helpfull... and i presume that mem.au should be included in the script i want to read/write with?

Thanx in advance

Posted (edited)

@D.M.

reading:

just read the number of bytes and then combine then into the value you want :D

The problem I have when trying to use your reading function is this:

I have to read an address to get a pointer to another address, plus I have to add an offset to the pointer to get the correct address. The pointer address is usually something like, 0x4FBC000. Well, anytime the "byte" value of the address being read is 00, the function automatically exits, and it reads from right to left. So I always get a value of 0 instead of the value 0x4FBC000.

I've revised your functions to suit my needs, but I thought I would point this out so if you wanted to try and resolve this problem, you could. Here is a sample script I did and it shows your modified functions if you would like to take a look at it:

http://www.autoitscript.com/forum/index.ph...f=9&t=27111

Great work none the less, it gave me a great starting point in understanding this concept, :P

Nomad :D

Edited by Nomad
  • 3 months later...
Posted

Could any1 help me with this?

Func GetSong(); Adresse: 0012ADF5
    If ProcessExists("WinAmp.exe") Then
        $pid = ProcessExists("WinAmp.exe")
;~      msgbox(0, "", $pid)
        $open = _MemOpen($pid)
        $song = _MemRead($open, 0x0012ADF5)
        msgbox(0, "Song", $song)
        _MemClose($pid)
    EndIf
EndFunc;~~>Songname

it should only get the played song out of winamp :lmao:

[font="Verdana"]In work:[list=1][*]InstallIt[*]New version of SpaceWar[/list] [/font]

Posted

I can't help you with this specific example, but you might want to take a look at Auto3Lib. It has an external memory manager that you can use to do this sort of thing. It is well documented, easy to use and has examples included.

Auto3Lib: A library of over 1200 functions for AutoIt
Posted

Could any1 help me with this?

Func GetSong(); Adresse: 0012ADF5
    If ProcessExists("WinAmp.exe") Then
        $pid = ProcessExists("WinAmp.exe")
;~      msgbox(0, "", $pid)
        $open = _MemOpen($pid)
        $song = _MemRead($open, 0x0012ADF5)
        msgbox(0, "Song", $song)
        _MemClose($pid)
    EndIf
EndFunc;~~>Songname

it should only get the played song out of winamp :lmao:

ideas?

[font="Verdana"]In work:[list=1][*]InstallIt[*]New version of SpaceWar[/list] [/font]

  • 3 months later...
Posted (edited)

ideas?

Func GetSong(); Adresse: 0012ADF5
    If ProcessExists("WinAmp.exe") Then
        $pid = ProcessExists("WinAmp.exe")
;~         msgbox(0, "", $pid)
        If $pid Then
            $open = _MemOpen( $pid )
            $song = _MemRead( $open, 0x00469380, 256 )
            $file = _MemRead( $open, 0x00469840, 256 )
            _MemClose( $open )
            $Msg = ""
            $Msg2 = ""
            For $i = 0 to 255
                $Msg = $Msg & chr( $song[$i] )
                $Msg2 = $Msg2 & chr( $file[$i] )
            Next
            msgbox( 0, $Msg, $Msg2 )
        EndIf
    EndIf
EndFunc;~~>Songname
Edited by A. Percy

Só o que posso lhe dizer, bom é quando faz mal!My work:Au3Irrlicht - Irrlicht for AutoItMsAgentLib - An UDF for MSAgentAu3GlPlugin T2 - A 3D plugin for AutoIt...OpenGl Plugin - The old version of Au3GlPlugin.MAC Address Changer - Changes the MAC AddressItCopter - A dragonfly R/C helicopter simulator

VW Bug user

Pinheiral (Pinewood) city:

http://pt.wikipedia.org/wiki/Pinheiral

  • 2 weeks later...
Posted

Using Cheat Engine 5.2 i can determin the health of a selected mob is 872

Cheat Engine Details of this data are:

Address = 0CB425D0 Type = 4 Bytes Value = 872

Reading through the forum i have used the following script to read this in AutoIt

#include <mem.au3>

$Process = 'test.exe' ;-> Target process
$PID = ProcessExists($Process) ;-> Get Process ID
$Address = 0x0CB425D0 ;-> Read/write address


$OpenProcess = _MemOpen(0x38, False, $PID) ;-> Enable reading/writing to the process and get the handle

    $v_Read = _MemRead($OpenProcess, $Address, 1) ;-> Read a 1 byte value from the defined address
    MsgBox(0,"Info", "The value of address "&HEX($Address, 8)&" is now: "&$v_Read)

_MemClose($OpenProcess) ;-> Disable reading/writing to the processoÝ÷ Øíz¸º)]x(­Ê&¦)^¶nÞ±Êâ¦Ö§vØ^»§Ø­+Þ²Ø^~e£§­¦ëSåZç¨|]­ë,Ð xÛôÉèÃ]8!ø©àzØ^r^¶®¶­sbb33c·eõ&VBÒôÖVÕ&VBb33c´÷Vå&ö6W72Âb33c´FG&W72ÂB
as the value in Cheat engine is 4 Bytes

I then get:

The Value of Address 0CB425D0 is now: h

The output i expected and what it should be is -- The Value of Address 0CB425D0 is now: 872

What am i doing wrong ? :whistle:

  • 2 weeks later...
Posted (edited)

Has anyone seen the memory address change from one computer to another computer. I have checked and the address is the same every time on my pc, but it appears to be a different address on a different computer.

Does this mean the static address is different on every computer for the same program? Lets say from a laptop to desktop computer are their differences in the memory use....? Weird I have never seen this problem.

Any help would be great!

Thx

Mad

Edited by madmax
  • 4 weeks later...
Posted

Hi chaps,

Well I'm allwais trying to get my problems sorted out by my self. But this time i have to ask you guys.

I trying to make anti cheting engine for Warcrft II FT and I stuck with first step :whistle: I have alocated whre in memory are stored loged user name and i nead to read it. For finding corect address I was using ArtMonkey. And address loks like this: 01323100. Value at this address is text "Slaughter" starting from first byte. So i wirted my script but i always give me a zero.....

I cheked my script few times.... Maybe its posible that memory isnt accesible for some seciuryti reasons? Because even some mem editors dosent find war3 proces.

First i thaugt taht addres is wrong I tried 01323100, 0x01323100, 0x1323100 and so on.... no results...

#include <mem_fnc.au3>
#include <array.au3>
$Process = "war3.exe"
$Pid = ProcessExists($Process)
$h_open = _MemOpen($pid)
$Read = _MemRead($h_open,0x1323100,8)
If IsArray($Read) Then
    _ArrayDisplay($Read, "Read Var" )
EndIf
_MemClose($h_open)
Posted

can you include ";"s so I can understand what is going on. I understand as a whole that it is basically a few functions for reading writing allocating memory and opening processes (dunno if I missed any but meh), but I'd like you to explain more clearly please.

Posted

can you include ";"s so I can understand what is going on. I understand as a whole that it is basically a few functions for reading writing allocating memory and opening processes (dunno if I missed any but meh), but I'd like you to explain more clearly please.

http://www.autoitscript.com/forum/index.php?showtopic=19329

here is all what im including

All post moved out to

http://www.autoitscript.com/forum/index.ph...mp;#entry319289

  • 2 weeks later...

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...