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 


Is it possible to generate a list of addresses?

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

Joined: 24 Aug 2014
Posts: 9

PostPosted: Mon Oct 26, 2015 12:21 pm    Post subject: Is it possible to generate a list of addresses? Reply with quote

There's hundred-ish of addresses I need to edit, each is bigger than the previous one by 24 (decimal). The first address changes each time the game is restarted, however the difference is always 24. Would it be possible to make a list that would automatically generate after specifying the starting address? Does CE have a built-in function for this or does it require scripting?
Thanks in advance.
Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8585
Location: 127.0.0.1

PostPosted: Mon Oct 26, 2015 12:23 pm    Post subject: Reply with quote

That would be something you can do with Lua pretty easily. You could also use the user defined symbols in Cheat Engine to build a table making use of a base address symbol then do the needed additions to each other entry. Then when you restart just update the one symbol and the rest will auto-adjust.
_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
ParkourPenguin
I post too much
Reputation: 152

Joined: 06 Jul 2014
Posts: 4697

PostPosted: Mon Oct 26, 2015 1:58 pm    Post subject: Reply with quote

Zanzer showed me a neat trick you can do. What you do is just make a header out of your base address, then set the addresses of the children to be "+number", where number is the offset from the header's address.

Here's a Lua script that'll make this for you automatically:
Code:
function addMoreAddresses(baseAddress, num, step)
  local al = getAddressList()

  local base = al.createMemoryRecord()
  base.setAddress(baseAddress)
  base.setDescription("Base Address")
  base.Type = vtString
  base.String.Size = 0

  for i=0, num-1 do
    local rec = al.createMemoryRecord()
    local str = string.format("+%X", i * step)
    rec.setAddress(str)
    rec.setDescription(str)
    rec.appendToEntry(base)
  end
end

addMoreAddresses("0040ACDC", 100, 24)

(credit to Zanzer, original post here)

With this, you don't even need to run the Lua script every time you start up CE, just save the cheat table once and change the base address yourself when you find it.

_________________
I don't know where I'm going, but I'll figure it out when I get there.
Back to top
View user's profile Send private message
epikus29
How do I cheat?
Reputation: 0

Joined: 24 Aug 2014
Posts: 9

PostPosted: Tue Oct 27, 2015 11:11 am    Post subject: Reply with quote

Thank you all so much, exactly what I was looking for.
Everything's working correctly.
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