Auto IT to Micromacro
Forum rules
This is a sub-forum for things specific to MicroMacro.
This is not the place to ask questions about the RoM bot, which uses MicroMacro. There is a difference.
This is a sub-forum for things specific to MicroMacro.
This is not the place to ask questions about the RoM bot, which uses MicroMacro. There is a difference.
Auto IT to Micromacro
I want to translate auto it script to micromacro
In Auto IT:
Local $TAR_TEMP = memread(memread(memread($staticbase_ptr) + 0x20) + 0x38c)
Local $POINTER = memread(memread(memread(memread($staticbase_ptr) + 0x8) + 0x24) + 0x18)
For $I=0 To 768
Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
If $TAR = memread($cur_base + 0x11C) Then
$TAR_BASE = $CURBASE;
ExitLoop
EndIf
Next
$TARMAXHP = memread($TAR_BASE+ $OFFSET_TARMAXHP)
I try to coding it in micromacro
tartempptr_addr = memoryReadInt(proc, staticbase_ptr) + 0x20 + 0x38c;
pointer = memoryReadInt(proc, staticbase_ptr) + 0x8 + 0x24 + 0x18;
for i = 0, 768 do
curbase = memoryReadInt(proc, pointer) + i*0x4 + 0x4;
if (tar == memoryReadInt(proc, curbase) + 0x11C) then
tarbase = curbase;
coroutine.yield();
end
end
MaxHPtar = memoryReadIntPtr(proc, tarbase, MaxHPtar_offset);
Error: memoryReadIntPtr ((null)) on line "MaxHPtar = memoryReadIntPtr(proc, tarbase, MaxHPtar_offset);"
Is there something wrong with my translation?
Thanks
In Auto IT:
Local $TAR_TEMP = memread(memread(memread($staticbase_ptr) + 0x20) + 0x38c)
Local $POINTER = memread(memread(memread(memread($staticbase_ptr) + 0x8) + 0x24) + 0x18)
For $I=0 To 768
Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
If $TAR = memread($cur_base + 0x11C) Then
$TAR_BASE = $CURBASE;
ExitLoop
EndIf
Next
$TARMAXHP = memread($TAR_BASE+ $OFFSET_TARMAXHP)
I try to coding it in micromacro
tartempptr_addr = memoryReadInt(proc, staticbase_ptr) + 0x20 + 0x38c;
pointer = memoryReadInt(proc, staticbase_ptr) + 0x8 + 0x24 + 0x18;
for i = 0, 768 do
curbase = memoryReadInt(proc, pointer) + i*0x4 + 0x4;
if (tar == memoryReadInt(proc, curbase) + 0x11C) then
tarbase = curbase;
coroutine.yield();
end
end
MaxHPtar = memoryReadIntPtr(proc, tarbase, MaxHPtar_offset);
Error: memoryReadIntPtr ((null)) on line "MaxHPtar = memoryReadIntPtr(proc, tarbase, MaxHPtar_offset);"
Is there something wrong with my translation?
Thanks
Re: Auto IT to Micromacro
I got some clue.
pointer = memoryReadInt(proc, staticbase_ptr) + 0x8 + 0x24 + 0x18;
become
pointer_offset = {0x8, 0x24, 0x18};
pointer = memoryReadIntPtr(proc, staticbase_ptr, pointer_offset);
Now the problem is
1. Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
2. If $TAR = memread($cur_base + 0x11C) Then
Thanks.
pointer = memoryReadInt(proc, staticbase_ptr) + 0x8 + 0x24 + 0x18;
become
pointer_offset = {0x8, 0x24, 0x18};
pointer = memoryReadIntPtr(proc, staticbase_ptr, pointer_offset);
Now the problem is
1. Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
2. If $TAR = memread($cur_base + 0x11C) Then
Thanks.
- Administrator
- Site Admin
- Posts: 5312
- Joined: Sat Jan 05, 2008 4:21 pm
Re: Auto IT to Micromacro
el_dios85 wrote: 1. Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
Code: Select all
local CUR_BASE = memoryReadInt(proc, memoryReadInt(proc, POINTER + I * 0x4) + 0x4);
2. If $TAR = memread($cur_base + 0x11C) Then
Code: Select all
TAR = memoryReadInt(proc, CUR_BASE + 0x11C);
if( TAR ~= 0 ) then
Re: Auto IT to Micromacro
Thanks...
"WARNING: Failure reading memory from 0x1DFDC0 at 0x4 in memoryReadInt(). Error code 299 (Only part of a ReadProcessMemory or WriteProcessMemory request was completed.)"
This error always occured. I'm confuse. What should I check?
actually I want to recode auto it script to micromacro.
This is the result:
"WARNING: Failure reading memory from 0x1DFDC0 at 0x4 in memoryReadInt(). Error code 299 (Only part of a ReadProcessMemory or WriteProcessMemory request was completed.)"
This error always occured. I'm confuse. What should I check?
actually I want to recode auto it script to micromacro.
Code: Select all
Func GetSelected()
If Not $PROCESS_ID Then Return 0
Local $TAR_TEMP = memread(memread(memread($APP_BASE_ADDRESS) + 0x20) + $OFFSET_AT)
Local $TARID_TEMP = memread(memread(memread($APP_BASE_ADDRESS) + 0x20) + $OFFSET_AT)
If $TAR_TEMP = 0 Then
$TAR = 0
$TAR_BASE = 0
ElseIf $TAR_TEMP <> $TAR Then
$TAR = $TAR_TEMP
Local $POINTER = memread(memread(memread(memread($APP_BASE_ADDRESS) + 0x8) + 0x24) + 0x18)
For $I=0 To 768
Local $CUR_BASE = memread(memread($POINTER + $I*0x4) + 0x4)
If $TAR = memread($cur_base + 0x11C) Then
$TAR_BASE = $CUR_BASE
$TARID = $TAR_TEMP
ExitLoop
EndIf
Next
EndIf
EndFunc
Code: Select all
tartempptr_addr = memoryReadUIntPtr(proc, charptr_addr, targetid_offset);
printf("tartempptr_addr [%x].\n", tartempptr_addr);
taridtempptr_addr = memoryReadUIntPtr(proc, charptr_addr, targetid_offset);
printf("taridtempptr_addr [%x].\n", taridtempptr_addr);
if(tartemptptr_addr == 0) then
tarptr_addr = 0;
tarbaseptr_addr = 0;
elseif(tartempptr_addr ~= tarptr_addr) then
tarptr_addr = tartempptr_addr;
pointer_offset = {0x8, 0x24, 0x18};
local pointer = memoryReadIntPtr(proc, staticbase_ptr, pointer_offset);
printf("pointer [%x].\n", pointer);
for i = 1, 768 do
local curbaseptr_addr = memoryReadInt(proc, memoryReadInt(proc, pointer + i * 4) + 0x4);
printf("curbaseptr_addr [%x].\n", curbaseptr_addr);
tarptr_addr = memoryReadInt(proc, curbaseptr_addr + 0x11C);
if( tarptr_addr ~= 0 ) then
tarbaseptr_addr = curbaseptr_addr;
taridptr_addr = tartempptr_addr;
coroutine.yield();
end
end
end
HPtar = memoryReadIntPtr(proc, tarbaseptr_addr, TarHP_offset);
MaxHPtar = memoryReadIntPtr(proc, tarbaseptr_addr, TarMaxHP_offset);
- Administrator
- Site Admin
- Posts: 5312
- Joined: Sat Jan 05, 2008 4:21 pm
Re: Auto IT to Micromacro
Specifically, which line is generating that warning?
Re: Auto IT to Micromacro
Code: Select all
local curbaseptr_addr = memoryReadInt(proc, memoryReadInt(proc, pointer + i * 4) + 0x4);
- Administrator
- Site Admin
- Posts: 5312
- Joined: Sat Jan 05, 2008 4:21 pm
Re: Auto IT to Micromacro
First, split it into two lines like so:
That way we know specifically which call to memoryReadInt is failing.
Code: Select all
local tmp = memoryReadInt(proc, pointer + i * 4);
local curbaseptr_addr = memoryReadInt(proc, tmp + 0x4);
Re: Auto IT to Micromacro
I'm sorry Admin, it didn't work. I try many ways and it get warning...
is there any problem with the memread function (Auto IT)
Thanks...
is there any problem with the memread function (Auto IT)
The Auto IT Script is from http://www.elitepvpers.de/forum/pw-hack ... coded.htmlFunc memread($adress, $type = 'dword')
Local $struct = DllStructCreate($type)
DllCall($kernel32, 'int', 'ReadProcessMemory', 'int', $mid, 'int', $adress, 'ptr', DllStructGetPtr($struct), 'int', DllStructGetSize($struct), 'int', '')
Return DllStructGetData($struct, 1)
EndFunc
Thanks...
Who is online
Users browsing this forum: No registered users and 2 guests