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 


Firstscan, nextscan in ce Lua?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
Dr.Disrespect
Master Cheater
Reputation: 2

Joined: 17 Feb 2016
Posts: 497

PostPosted: Thu Jul 27, 2017 7:45 am    Post subject: Firstscan, nextscan in ce Lua? Reply with quote

Say I want the following to happen:
1. The starting address is 0x10000000, the ending address is 0x20000000.

2. I want to find "AE 45" and "89 12" within those addresses. Moreover, I know that "AE 45" comes before "89 12", and they are not next to each other.

3. If the search words in step 2 do exist, return true.

I suppose I should use firstscan and nextscan, but I can't get it to work.

Thanks in advance.

_________________
**************

A simple example is better then ten links. Very Happy
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 344

Joined: 09 May 2003
Posts: 20103
Location: The netherlands

PostPosted: Thu Jul 27, 2017 8:04 am    Post subject: Reply with quote

what is the max amount of bytes that AE 45 and 89 12 can be apart ?

because you could do a groupscan like "BA:1 BS:128 OOO:U 2:0x45a0 2:0x1289" (max distance is 128 bytes in this example) and then check in the results which one starts with ae 45

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.
Back to top
View user's profile Send private message MSN Messenger
Dr.Disrespect
Master Cheater
Reputation: 2

Joined: 17 Feb 2016
Posts: 497

PostPosted: Thu Jul 27, 2017 8:11 am    Post subject: Reply with quote

Dark Byte wrote:
what is the max amount of bytes that AE 45 and 89 12 can be apart ?

because you could do a groupscan like "BA:1 BS:128 OOO:U 2:0x45a0 2:0x1289" (max distance is 128 bytes in this example) and then check in the results which one starts with ae 45


Thanks for the reply.

1. The maximum distance between the two key words is unknown. Does it affect the search speed if I set the distance too large?

2. How to do a groupscan in Lua? I can't find the function.

_________________
**************

A simple example is better then ten links. Very Happy
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 Lua Scripting 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