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 


Asm to C++

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
back3o
How do I cheat?
Reputation: 0

Joined: 05 Sep 2010
Posts: 2

PostPosted: Sun Sep 05, 2010 3:30 pm    Post subject: Asm to C++ Reply with quote

How do i actually convert asm to c++?
i dont want to just do it inline code...is it possible to do as i wish?
if not how would i convert this to c?

Code:
 
[enable]
alloc(mscrc,100)
alloc(hscrc,100)
alloc(copy,1024)
alloc(dump,10482664)
createthread(copy)
label(exitmscrc)
label(mscrcret)
label(hscrcret)
label(llop)
label(getoutahere)
 
mscrc:
cmp ecx,00401000
jl exitmscrc
cmp ecx,00E00000
jg exitmscrc
sub ecx,00401000
push eax
lea eax,[dump]
add ecx,eax
pop eax
exitmscrc:
movzx ecx,byte ptr [ecx]
mov edx,[ebp+14]
jmp mscrcret
 
copy:
mov eax,00401000
lea ecx,[dump]
llop:
xor ebx,ebx
movzx ebx,byte ptr [eax]
mov byte ptr [ecx],bl
inc eax
inc ecx
cmp eax,00E00000
jg getoutahere
jmp llop
getoutahere:
lea ebx,[dump]
add ebx,749cdb//B4ACDB - 401000
xor eax,eax              
mov al,0F
mov byte ptr [ebx],al
inc ebx
mov al,B6
mov byte ptr [ebx],al
inc ebx
mov al,09
mov byte ptr [ebx],al
inc ebx
mov al,8B
mov byte ptr [ebx],al
inc ebx
mov al,55
mov byte ptr [ebx],al
ret
 
hscrc:
mov eax,fs:[20]
cmp eax,[esp+0c]
jne hscrcret
mov fs:[34],57
xor eax,eax
ret 000c
 
hscrcret:
mov edi,edi
push ebp
mov ebp,esp
jmp OpenProcess+05
 
00B4ACDB:
jmp mscrc
db 14
mscrcret:
 
OpenProcess:
jmp hscrc
 
[disable]
00B4ACDB:
db 0F B6 09 8B 55 14
OpenProcess:
db 8B FF 55 8B EC
 
dealloc(mscrc)
dealloc(hscrc)
dealloc(dump)
dealloc(copy)
 
Back to top
View user's profile Send private message
justa_dude
Grandmaster Cheater
Reputation: 23

Joined: 29 Jun 2010
Posts: 893

PostPosted: Sun Sep 05, 2010 6:26 pm    Post subject: Reply with quote

It is possible to write your hook proc and logger in C++, but the trampolines will need to be written (and possibly read) as machine code.
Back to top
View user's profile Send private message
back3o
How do I cheat?
Reputation: 0

Joined: 05 Sep 2010
Posts: 2

PostPosted: Sun Sep 05, 2010 8:25 pm    Post subject: Reply with quote

Thank you very much.
I looked around the forums a bit. It seems nice here
* i guess you can tell i am new *
haha
:]
thanks again dude
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 programming 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