Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[Help]Changing pointers values into another pointer

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Fri May 18, 2007 2:44 am    Post subject: [Help]Changing pointers values into another pointer Reply with quote

Trying to change Walls (Left, Right, Top, Bottom) to Mouse Coordinate.
(Trying to change Left, Right to MouseX and Top, Bottom to MouseY)

Code:

[Enable]
Alloc(SetToMouse,64)
Alloc(SetWalls,32)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)


SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
mov ecx,[eax+C] //Left Wall Offset
mov [LeftWall],ecx
mov ebx,[eax+14] //Right Wall Offset
mov [RightWall],ebx
mov ecx,[eax+10] //Top Wall Offset
mov [TopWall],ecx
mov ebx,[eax+18] //Bottom Wall Offset
mov [BottomWall],ebx
popad

SetToMouse:
pushad
mov edx, [7d8370]  //Mouse Address
mov ebx, [edx+80] //MouseX Offset
mov ecx, [edx+84] //MouseY Offset \\ mov eax,[7D8224]  //Walls Pointer Address

mov [LeftWall],ebx //Left Wall
mov [RightWall],ebx //Right Wall
mov [TopWall],ecx //Top Wall
mov [BottomWall],ecx //Bottom Wall
popad
jmp SetToMouse

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA0F: //Floating Monsters
db 0f 84


[Disable]
Dealloc(SetToMouse)
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA0F:
db 0f 85 


why doesnt it work?
i tried also:
Code:

[enable]
Alloc(Mouse,128)
Alloc(MouseX,4)
Alloc(MouseY,4)

Mouse:
pushad
mov edx, [7d8370] //Mouse Address
mov ebx, [edx+80] //MouseX Offset
mov [MouseX],ebx
mov ecx, [edx+84] //MouseY Offset
mov [MouseY],ecx
mov eax,[7D8224]  //Walls Address
mov ecx,[eax+C] //Left Wall Offset
mov ecx,[MouseX]
mov ebx,[eax+10] //Top Wall Offset
mov ebx,[MouseY]
mov ecx,[eax+14] //Right Wall Offset
mov ecx,[MouseX]
mov ebx,[eax+18] //Bottom Wall Offset
mov ebx,[MouseY]
popad
jmp Mouse

[disable]
Dealloc(Mouse)
Dealloc(MouseX)
Dealloc(MouseY)
Back to top
View user's profile Send private message
XxScaRxX
Master Cheater
Reputation: 0

Joined: 22 Jan 2007
Posts: 456

PostPosted: Fri May 18, 2007 9:22 am    Post subject: Reply with quote

umm
try this
Code:

[Enable]
Alloc(SetToMouse,64)
Alloc(SetWalls,32)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)


SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
mov ecx,[eax+C] //Left Wall Offset
mov [LeftWall],ecx
mov ecx,[eax+14] //Right Wall Offset
mov [RightWall],ecx
mov ebx,[eax+10] //Top Wall Offset
mov [TopWall],ebx
mov ebx,[eax+18] //Bottom Wall Offset
mov [BottomWall],ebx
popad

SetToMouse:
pushad
mov eax, [7d8370]  //Mouse Address
mov ecx, [edx+80] //MouseX Offset
mov ebx, [edx+84] //MouseY Offset \\ mov eax,[7D8224]  //Walls Pointer Address

mov [LeftWall],ecx //Left Wall
mov [RightWall],ecx //Right Wall
mov [TopWall],ebx //Top Wall
mov [BottomWall],ebx //Bottom Wall
popad
jmp SetToMouse

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA0F: //Floating Monsters
db 0f 84


[Disable]
Dealloc(SetToMouse)
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA0F:
db 0f 85


_________________
You wake to suffer through the day
Trade a dream for the pay
Well here's the fact, I hope it sticks
You're just alive out of habit

x0r wrote:
[OFFTOPIC] tags/posts = 16 day ban


Back to top
View user's profile Send private message Visit poster's website
Gthuggin
Grandmaster Cheater
Reputation: 0

Joined: 17 Nov 2006
Posts: 862

PostPosted: Fri May 18, 2007 10:35 am    Post subject: Reply with quote

OMG, how can you not SEE WHAT IS WRONG WITH IT!!

ITS SO OBVIOUS!

Code:

[Enable]
Alloc(SetToMouse,64)
Alloc(SetWalls,32)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)

YOU AREN'T JUMPING TO YOUR CODECAVE FROM ANY PART OF THE GAME... HOW DO YOU EXPECT THE CODE TO RUN? YOU MUST HOOK AN ADDRESS THAT THE GAME CONSTANTLY ACCESSES SO YOUR CODE IS CONSTANTLY RUN...


SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
mov ecx,[eax+C] //Left Wall Offset
mov [LeftWall],ecx
mov ecx,[eax+14] //Right Wall Offset
mov [RightWall],ecx
mov ebx,[eax+10] //Top Wall Offset
mov [TopWall],ebx
mov ebx,[eax+18] //Bottom Wall Offset
mov [BottomWall],ebx
popad

SetToMouse:
pushad
mov eax, [7d8370]  //Mouse Address // whered EDX come from? Copy and paste much? and you even deleted something important
mov ecx, [edx+80] //MouseX Offset // should be EAX+80 and EAX+84
mov ebx, [edx+84] //MouseY Offset //mov eax,[7D8224]  //Walls Pointer Address

mov [LeftWall],ecx //Left Wall // WRONG!
mov [RightWall],ecx //Right Wall
mov [TopWall],ebx //Top Wall
mov [BottomWall],ebx //Bottom Wall
popad
jmp SetToMouse // THIS WOULD CAUSE AN INFINITE LOOP!
                       // SUCH A THING IS NEVER ALLOWED!!

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA0F: //Floating Monsters
db 0f 84


[Disable]
Dealloc(SetToMouse)
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA0F:
db 0f 85




TRY THIS ONE:

Code:


[Enable]
Alloc(SetWalls,100)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)
label(BackToBusiness)

SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
push [eax+C] //Left Wall Offset
pop [LeftWall]
push [eax+14] //Right Wall Offset
pop [RightWall]
push [eax+10] //Top Wall Offset
pop [TopWall]
push [eax+18] //Bottom Wall Offset
pop [BottomWall]
// then set to mouse
mov eax, [7d8370]  //Mouse Address
mov eax, [eax+978] // they are level 2 pointers!! u need this
mov ecx, [eax+80] //MouseX Offset
mov ebx, [eax+84] //MouseY Offset
mov eax,[7D8224]  //Walls Pointer
mov [eax+C],ecx
mov [eax+14],ecx
mov [eax+10],ebx
mov [eax+18],ebx
popad
push [ebx+00000548] // restore original overwritten codes
push [ebx+00000544]
jmp BackToBusiness // See no more infinite loop!!

004339EA:
jmp SetWalls // long jump = 5 bytes
db 90 90 90 90 90 90 90 // +7 NOP's = 12 bytes
BackToBusiness:
                       

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA10: //Floating Monsters
db 84


[Disable]
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA10:
db 85

004339EA:
push [ebx+00000548] // 6 bytes
push [ebx+00000544]// +6 bytes = 12 bytes


But I don't know what your trying to store the wall values for?

since your script isnt doing anything with them!!

_________________
Back to top
View user's profile Send private message
XxScaRxX
Master Cheater
Reputation: 0

Joined: 22 Jan 2007
Posts: 456

PostPosted: Fri May 18, 2007 2:04 pm    Post subject: Reply with quote

Gthuggin wrote:
OMG, how can you not SEE WHAT IS WRONG WITH IT!!

ITS SO OBVIOUS!

Code:

[Enable]
Alloc(SetToMouse,64)
Alloc(SetWalls,32)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)

YOU AREN'T JUMPING TO YOUR CODECAVE FROM ANY PART OF THE GAME... HOW DO YOU EXPECT THE CODE TO RUN? YOU MUST HOOK AN ADDRESS THAT THE GAME CONSTANTLY ACCESSES SO YOUR CODE IS CONSTANTLY RUN...


SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
mov ecx,[eax+C] //Left Wall Offset
mov [LeftWall],ecx
mov ecx,[eax+14] //Right Wall Offset
mov [RightWall],ecx
mov ebx,[eax+10] //Top Wall Offset
mov [TopWall],ebx
mov ebx,[eax+18] //Bottom Wall Offset
mov [BottomWall],ebx
popad

SetToMouse:
pushad
mov eax, [7d8370]  //Mouse Address // whered EDX come from? Copy and paste much? and you even deleted something important
mov ecx, [edx+80] //MouseX Offset // should be EAX+80 and EAX+84
mov ebx, [edx+84] //MouseY Offset //mov eax,[7D8224]  //Walls Pointer Address

mov [LeftWall],ecx //Left Wall // WRONG!
mov [RightWall],ecx //Right Wall
mov [TopWall],ebx //Top Wall
mov [BottomWall],ebx //Bottom Wall
popad
jmp SetToMouse // THIS WOULD CAUSE AN INFINITE LOOP!
                       // SUCH A THING IS NEVER ALLOWED!!

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA0F: //Floating Monsters
db 0f 84


[Disable]
Dealloc(SetToMouse)
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA0F:
db 0f 85




TRY THIS ONE:

Code:


[Enable]
Alloc(SetWalls,100)
Alloc(LeftWall,4)
Alloc(RightWall,4)
Alloc(TopWall,4)
Alloc(BottomWall,4)
label(BackToBusiness)

SetWalls:
pushad
mov eax,[7D8224]  //Walls Address
push [eax+C] //Left Wall Offset
pop [LeftWall]
push [eax+14] //Right Wall Offset
pop [RightWall]
push [eax+10] //Top Wall Offset
pop [TopWall]
push [eax+18] //Bottom Wall Offset
pop [BottomWall]
// then set to mouse
mov eax, [7d8370]  //Mouse Address
mov eax, [eax+978] // they are level 2 pointers!! u need this
mov ecx, [eax+80] //MouseX Offset
mov ebx, [eax+84] //MouseY Offset
mov eax,[7D8224]  //Walls Pointer
mov [eax+C],ecx
mov [eax+14],ecx
mov [eax+10],ebx
mov [eax+18],ebx
popad
push [ebx+00000548] // restore original overwritten codes
push [ebx+00000544]
jmp BackToBusiness // See no more infinite loop!!

004339EA:
jmp SetWalls // long jump = 5 bytes
db 90 90 90 90 90 90 90 // +7 NOP's = 12 bytes
BackToBusiness:
                       

00535F8F: //Zero1
db 75
535FA4: //Zero2
db 74
006BBA10: //Floating Monsters
db 84


[Disable]
Dealloc(SetWalls)
Dealloc(LeftWall,4)
Dealloc(RightWall,4)
Dealloc(TopWall,4)
Dealloc(BottomWall,4)

00535F8F:
db 74
535FA4:
db 75
006BBA10:
db 85

004339EA:
push [ebx+00000548] // 6 bytes
push [ebx+00000544]// +6 bytes = 12 bytes


But I don't know what your trying to store the wall values for?

since your script isnt doing anything with them!!

yeah im pretti sure
he wants the wall values
to be stored and then
changed to the mouse values

_________________
You wake to suffer through the day
Trade a dream for the pay
Well here's the fact, I hope it sticks
You're just alive out of habit

x0r wrote:
[OFFTOPIC] tags/posts = 16 day ban


Back to top
View user's profile Send private message Visit poster's website
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Sat May 19, 2007 6:44 am    Post subject: Reply with quote

ok thx =D
but i didnt understand why did u do:
push [ebx+00000548] and [ebx+00000544]... why did u add 004339EA? so confused... O.o
umm lvl 2 pointer.. so how do i know that i put eax+978 and not eax+1000 or eax+2 or anything else? o.o
and what does it have to do with 12 bytes? Surprised
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites