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 


automatically change adresses value, please help

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

Joined: 09 Nov 2017
Posts: 2

PostPosted: Thu Nov 09, 2017 8:16 pm    Post subject: automatically change adresses value, please help Reply with quote

Hey guys - i need your help. I did manage to scan the right adress and show its value.

[b]Scancode:[/b]
[ENABLE]
aobscan(_piercing, 0? 00 00 00 00 00 00 00 01 B4 00 00 00 68 01 00 00 00 00 00 00 00 00 70 17 00 00 74 00 00 00 70 17 00 00 40 0C 00 00 6A 0E 00 00 00 00 00 00 00)
label(piercing)
registersymbol(_piercing)

piercing:
_piercing:

[DISABLE]
unregistersymbol(_piercing)



Result: Edit: NVM i can't post urls yet D:
(It shows the "scan"-script and that it works (i added an adress manually, the adress i added is _piercing which gives me the correct adress and its value)


That's very cool! Because now i can change the value to the value I need much more easily.


So why do i need help?

Can somebody tell me how to "automate" the valuechanging? I want it changed from 4 to 1 automatically.

Btw some info: I started with CE today - so im VERY inexperienced




Edit2: From what I've understood _piercing is a variable. Is it possible to read this variable with, for example AutoIt?
So that this variable = the adress and i can change the adresses value through autoit. (Just an idea, as you can see i am a noob)
Back to top
View user's profile Send private message
FreeER
Grandmaster Cheater Supreme
Reputation: 53

Joined: 09 Aug 2013
Posts: 1091

PostPosted: Thu Nov 09, 2017 8:43 pm    Post subject: Reply with quote

assuming that aobscan gives you the address of the value and not code accessing it

Code:
[ENABLE]
aobscan(piercing, 0? 00 00 00 00 00 00 00 01 B4 00 00 00 68 01 00 00 00 00 00 00 00 00 70 17 00 00 74 00 00 00 70 17 00 00 40 0C 00 00 6A 0E 00 00 00 00 00 00 00)
registersymbol(piercing)

piercing:
dd 4 // assuming it's a 4 byte value... most common

[DISABLE]
unregistersymbol(piercing)


Is all you need if you just need the value changed once. If you need it constantly changed then I'd suggest using a memory record and just freezing it. Same code as before, just add a memory record and instead of an address like 0xDEADBEEF or "game.exe"+53234 etc. use piercing, then enabling the script will associate that name with the proper address at which point you can freeze it (and possibly set the value if it's changed inbetween enabling the script and you freezing it)

A little bit more work and you can use lua to freeze it for you

Code:
[ENABLE]
aobscan(piercing, 0? 00 00 00 00 00 00 00 01 B4 00 00 00 68 01 00 00 00 00 00 00 00 00 70 17 00 00 74 00 00 00 70 17 00 00 40 0C 00 00 6A 0E 00 00 00 00 00 00 00)
registersymbol(piercing)

piercing:
dd 4

// note lua will run before the asm code
{$lua}
getAddressList().GetMemoryRecordByDescription('Piercing Memory Record').Active = true
{$asm}

[DISABLE]
// go ahead and unfreeze it when disabling the script
{$lua}
getAddressList().GetMemoryRecordByDescription('Piercing Memory Record').Active = false
{$asm}
unregistersymbol(piercing)


just replace Piercing Memory Record with whatever name you give the memory record with the address piercing.

Oh, and I'd recommend dragging and dropping the piercing memory record on top of the script then right clicking the script and going to group config and hiding children when it's disabled. That way the piercing memory record is hidden when the symbol it's using to get the address isn't set.
Back to top
View user's profile Send private message
eng4ge?
How do I cheat?
Reputation: 0

Joined: 09 Nov 2017
Posts: 2

PostPosted: Fri Nov 10, 2017 8:12 am    Post subject: Reply with quote

That worked really well, thank you very much.

I just found the "Create generic lua script from the table"- button.

What i wanna do: Have a GUI on which a user can click a button which then enables the CE auto assembly script.

Is that possible? Pretty much everything that i google confuses me alot.

Greetings
Back to top
View user's profile Send private message
FreeER
Grandmaster Cheater Supreme
Reputation: 53

Joined: 09 Aug 2013
Posts: 1091

PostPosted: Fri Nov 10, 2017 8:40 am    Post subject: Reply with quote

sure, when it's clicked set the Active property of the memory record to not memoryRecord.Active so that it toggles it, or simply true if you want it to always enable it, not disable it but that seems unlikely to be the desired goal Smile

something like:
Code:
local memrec = getAddressList().GetMemoryRecordByDescription('Get Piercing Address Script')
CEButton1Click = function(sender)
  memrec.Active = not memrec.Active -- toggle script state
end


Use the "Events" tab in the gui editor to create the ..Click function by clicking on the ... button (or create the function yourself and then type the name in the events tab if you don't like the generic _GuiName_EventType format)

Here's an example, click on "Raw" and then save it as a .ct file. It shows a button, a checkbox, and a togglebox (visual button, hidden checkbox state) which toggle a script (that just displays a message box) and freezes a value.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine 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