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 


Auto Assemble problem (conflict)

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Sun Dec 21, 2014 4:04 pm    Post subject: Auto Assemble problem (conflict) Reply with quote

Hello! First of I'm new when it comes to the auto assembler. Still trying to learn it all. But anyways, Just for fun i tried to make my own trainer for GTA Vice City, I have made scripts for: God Mode, 1 Hit Kills, Unlimited Stamina, Infinite Ammo, Infinite Car Health, Stop Timer, Never Wanted.

All of them are working fine except the God Mode and 1 hit kills. they work fine individually. But when i enable them both they conflict with each other and non of them are working. Here is the codes:
God Mode:

[ENABLE]
alloc(newmem,100)
label(returnhere)
label(originalcode)
label(health)
label(exit)

newmem:
cmp [ebx+0000037C],41700000
je health
jmp originalcode

health:
nop
nop
nop
nop
nop
nop
jmp exit

originalcode:
fstp dword ptr [ebx+00000354]
jmp exit

exit:
jmp returnhere

"gta-vc.exe"+1267E8:
jmp newmem
nop
returnhere:

[DISABLE]
"gta-vc.exe"+1267E8:
fstp dword ptr [ebx+00000354]
---------------------------------------------
One Hit Kills:
[ENABLE]
alloc(newmem,100)
label(returnhere)
label(originalcode)
label(onehit)
label(exit)

newmem:
cmp [ebx+0000037C],40F00000
je onehit
jmp originalcode

onehit:
mov [ebx+00000354],0

jmp exit

originalcode:
fstp dword ptr [ebx+00000354]
jmp exit

exit:
jmp returnhere

"gta-vc.exe"+1267E8:
jmp newmem
nop
returnhere:

[DISABLE]
"gta-vc.exe"+1267E8:
fstp dword ptr [ebx+00000354]




I don't know how to fix this conflict thing. Any tips? Thanks Smile
Back to top
View user's profile Send private message
kik4444
Expert Cheater
Reputation: 0

Joined: 07 Sep 2013
Posts: 120
Location: Bulgaria

PostPosted: Sun Dec 21, 2014 6:20 pm    Post subject: Reply with quote

I don't remember much about compares since I haven't used them in a while, but I think it might be because you're trying to do 2 different things in 2 different scripts with a single piece of code. I think it might work if you use the registersymbol() command and put both codes in 1 script and activate them separately from the cheat table. I don't remember much of the terminology so my explanation might be a little bad, but I can see that you're using this
Code:
fstp dword ptr [ebx+00000354]
for both codes, so could try posting the whole original script without any editing and I could try writing the code. In meantime, here's a ready-made cheat table of 2 compares running at once in assassin's creed black flag. You can inspect the script and the entries on the cheat table.


Example CT of 2 compares running at once.CT
 Description:

Download
 Filename:  Example CT of 2 compares running at once.CT
 Filesize:  3.25 KB
 Downloaded:  2593 Time(s)


_________________
Silence will fall when the question is asked...
Back to top
View user's profile Send private message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Sun Dec 21, 2014 7:01 pm    Post subject: Reply with quote

Thanks for your answer and for the cheat tables. I understand most of them. there still some stuff i need to figure out, for example the "je" and the "mov"

I don't know what je does. I just know that i need it sometimes lol. I know that "mov" means move, But i don't understand where it get's moved etc.

Here is the original code for the health:

alloc(newmem,2048)
label(returnhere)
label(originalcode)
label(exit)

newmem: //this is allocated memory, you have read,write,execute access
//place your code here

originalcode:
fstp dword ptr [ebx+00000354]

exit:
jmp returnhere

"gta-vc.exe"+1267E8:
jmp newmem
nop
returnhere:




I guess that's what you needed? If so do you need one hit kill too? Thanks.
Back to top
View user's profile Send private message
mgr.inz.Player
I post too much
Reputation: 222

Joined: 07 Nov 2008
Posts: 4438
Location: W kraju nad Wisla. UTC+01:00

PostPosted: Sun Dec 21, 2014 7:25 pm    Post subject: Reply with quote

Here, example for Vice City, based on informations from OP



about JE and MOV


MOV - http://www.jaist.ac.jp/iscenter-new/mpc/altix/altixdata/opt/intel/vtune/doc/users_guide/mergedProjects/analyzer_ec/mergedProjects/reference_olh/mergedProjects/instructions/instruct32_hh/vc177.htm

JE - http://www.jaist.ac.jp/iscenter-new/mpc/altix/altixdata/opt/intel/vtune/doc/users_guide/mergedProjects/analyzer_ec/mergedProjects/reference_olh/mergedProjects/instructions/instruct32_hh/vc144.htm



gta-vc.ct
 Description:

Download
 Filename:  gta-vc.ct
 Filesize:  3 KB
 Downloaded:  2630 Time(s)


_________________


Last edited by mgr.inz.Player on Sun Dec 21, 2014 7:27 pm; edited 1 time in total
Back to top
View user's profile Send private message MSN Messenger
kik4444
Expert Cheater
Reputation: 0

Joined: 07 Sep 2013
Posts: 120
Location: Bulgaria

PostPosted: Sun Dec 21, 2014 7:25 pm    Post subject: Reply with quote

je means "jump if equal", so if you put it after cmp (compare) it means that it will go to the specified place in the code if the thing you compared on top of it equals the specified number (in hex). mov [ebx+00000354],0 means that this line of code will move the specified number on the right into the ebx register with the offset of 354 on the left. I also forgot one thing - you need to know what you have to compare it to and to do that, you need to dissect the code structure. Can you do that for both groups of values? (the player and enemies group). In case you're having trouble understanding what I'm saying, you need to pass the 9th step in the CE tutorial - it teaches about separation of multiple values that one codes writes to. This video is a good tutorial about the 9th step. Once you watch it and then try to pass the 9th step on your own, I think you'll be able to understand separation and comparison. If not, at least do the structure dissection part and post a picture and I should be able to write a working script.
Code:
https://www.dropbox.com/s/wky5atdc0pgi330/dissect%20data.wmv?dl=1

_________________
Silence will fall when the question is asked...
Back to top
View user's profile Send private message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Sun Dec 21, 2014 9:45 pm    Post subject: Reply with quote

Thanks for the info mgr.inz.Player and kik4444. The cheat table, Your scripts are working fine. Except that some enemies (military/some cops) for example are not dying in one hit. But that's not your fault. I think that i didn't have enough enemies in the dissect data to compare it with. Will try to find a better one! Smile

I have done step 9 in the CH tutorial. Will continue to try it! i will also try to understand all you did in the script.

I have another problem with Unlimited Ammo also. The problem is that even tho i have unlimited ammo, (i have used the "inc" function to increase my ammo instead of "dec"=decrease it). The enemies also have unlimited also, which causes the game to crash in some missions.
here is the script for it:

[ENABLE]
alloc(newmem,100)
label(returnhere)
label(originalcode)
label(exit)

newmem:
inc [esi+0C]
cmp dword ptr [esi+04],00
jmp originalcode

originalcode:
dec [esi+0C]
cmp dword ptr [esi+04],00
jmp exit

exit:
jmp returnhere

"gta-vc.exe"+1D4AF5:
jmp newmem
nop
nop
returnhere:

[DISABLE]
"gta-vc.exe"+1D4AF5:
dec [esi+0C]
cmp dword ptr [esi+04],00


Thanks again!
Back to top
View user's profile Send private message
kik4444
Expert Cheater
Reputation: 0

Joined: 07 Sep 2013
Posts: 120
Location: Bulgaria

PostPosted: Mon Dec 22, 2014 3:13 am    Post subject: Reply with quote

Well here as far as I can see it's the same thing - both codes use this [esi+04],00. Find that code in the memory viewer, right click it and scan for other values which this code writes to. Make your enemies shoot a bit and you should get their value as well, then just compare it like you did with the health.
_________________
Silence will fall when the question is asked...
Back to top
View user's profile Send private message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Mon Dec 22, 2014 10:28 am    Post subject: Reply with quote

Thank you! I will try to use a similar/the same method then! Smile
Back to top
View user's profile Send private message
kik4444
Expert Cheater
Reputation: 0

Joined: 07 Sep 2013
Posts: 120
Location: Bulgaria

PostPosted: Mon Dec 22, 2014 12:46 pm    Post subject: Reply with quote

Sorry, I meant this dec [esi+0C] - that code decreases your amount of ammo each time you shoot. Just separate it from the enemy ammo using the same method as the one in the 9th step in the CE tutorial.
_________________
Silence will fall when the question is asked...
Back to top
View user's profile Send private message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Mon Dec 22, 2014 5:34 pm    Post subject: Reply with quote

Thank you very much for your help! Smile

Will try it later tonight!
Back to top
View user's profile Send private message
XaneXXXX
Expert Cheater
Reputation: 0

Joined: 29 Nov 2012
Posts: 212

PostPosted: Mon Dec 29, 2014 6:48 pm    Post subject: Reply with quote

Hello again. I could not get stuff to work. Getting confused about the hole registersymbol thing etc. Now i have another conflict with godmode and one hit kill in metal gear solid v. Don't really know how to write it like you guys showed me in gta vice city/assassins creed black flag.

Here is the originalcode i used for godmode:

[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
alloc(newmem,2048,"MgsGroundZeroes.exe"+2F35E5)
label(returnhere)
label(originalcode)
label(exit)

newmem: //this is allocated memory, you have read,write,execute access
//place your code here

originalcode:
add [rcx+28],eax
mov eax,[rcx+2C]

exit:
jmp returnhere

"MgsGroundZeroes.exe"+2F35E5:
jmp newmem
nop
returnhere:




[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem)
"MgsGroundZeroes.exe"+2F35E5:
add [rcx+28],eax
mov eax,[rcx+2C]
//Alt: db 01 41 28 8B 41 2C





here is my version of the code:

[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
alloc(newmem,100,"MgsGroundZeroes.exe"+2F35E5)
label(returnhere)
label(health)
label(exit)

newmem: //this is allocated memory, you have read,write,execute access
//place your code here
cmp [rcx+2C],00000FA0
je health
add [rcx+28],eax

health:
mov eax,[rcx+2C]
jmp exit

exit:
jmp returnhere

"MgsGroundZeroes.exe"+2F35E5:
jmp newmem
nop
returnhere:




[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem)
"MgsGroundZeroes.exe"+2F35E5:
add [rcx+28],eax
mov eax,[rcx+2C]

//Alt: db 01 41 28 8B 41 2C



Works just fine. Let's say that the offset for enemies i want to compare is
[rcx+3C] and the value to compare it with is F5FF2F20.

Since i want one hit kill, i need to set enemy health to 0.

Can anyone write me an example script and explain what each function does? i would really appreciate it.

I'm also wondering about the hole nop thing. In my version of the script, how do i nop it/un-nop the address? Let's say that there are 4 nops in total.

Thanks!!
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