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 


How to find a table of floats loaded by game?

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

Joined: 05 May 2016
Posts: 4

PostPosted: Thu May 05, 2016 6:51 am    Post subject: How to find a table of floats loaded by game? Reply with quote

Greetings, all.

As the title implies, I have been trying to find where a game stores a table of floats which it loads from a configuration file. The table can have between 200 and 400 values, each value with around 8 decimal places.

I tried floats initially as I thought the game would round the value to fit in a 7 digit precision figure.

I am sure it is stored as a double, but either it is encrypted (doubt it, it is not the most important table loaded, and others are not encrypted) or some mathematical operation is done on it, because I can't find any of the the values loaded.

Tried everything, unknown initials, changed vaues, increased, decreased. NADA. Watched memory viewer around seemingly contiguous [to the table name, a string] memory addresses.NADA.

If the code loaded the values onto a simple vector <double>, it should be simple to find it. [And the values would be stored contiguosly, thus easy notice.]

Anyone has good hints/ideas/speculations on how to go about this?

Thanks in advance, people.

M.
Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Thu May 05, 2016 7:17 am    Post subject: Reply with quote

It would be better if you just explain what it is that you are trying to do instead of trying to be so discreet. It's hard to say with the information that you have provided.

What are the values for? Do you know what the values are before they are loaded in to the game? Do the values change during game-play or at all? Do you know how/when the values change? How often do the values change? How do you know the values are being loaded from a 'configuration file'? Can you read the configuration file and see the values? Can you change the values in the configuration file? Does it have an effect in the game? etc...
Back to top
View user's profile Send private message
MikeSantis
How do I cheat?
Reputation: 0

Joined: 05 May 2016
Posts: 4

PostPosted: Thu May 05, 2016 7:49 am    Post subject: Reply with quote

++METHOS wrote:
It would be better if you just explain what it is that you are trying to do instead of trying to be so discreet. It's hard to say with the information that you have provided.

What are the values for? Do you know what the values are before they are loaded in to the game? Do the values change during game-play or at all? Do you know how/when the values change? How often do the values change? How do you know the values are being loaded from a 'configuration file'? Can you read the configuration file and see the values? Can you change the values in the configuration file? Does it have an effect in the game? etc...


Thank you for replying.

You are correct (the discreet part), I will try and give some more detail so that you and others can help out.

1-The values are to be used as the basis for a calculation, given a log10 or a cubic spline curve (the values in the table).

2- I do know what the value are, as they're in a configuration file filled with other values. They're pre-calculated curves (from real life data).

3- The physics engine within is supposed to operate on the curve: moving the peak, lowering/increasing the slopes (up and down slopes). Right off the bat, there should be an initial operation and then, as the "player" enters real time, a couple more operations should effect further changes.

But the initial table should be stored somewhere, as the "player" may leave real time and re-enter it any time, and all things are "reset".

4- The physics calculations can happen at a tick rate up to 430 Hz, and the calculations "accessing" the table/curve effect changes at that rate as well.

5- Changing the configuration file (any of the parameters, curves, etc) does have its effect on the game, ranging from minor to dramatic (depending on the calibration models - the config file values - used).

I know I have hit a tough wall, as I can't find some parameters (example: if I have param1, param2, param3, param4, I may have discovered param3 and param4 but not param1 and param2) and also can't find the individual values of the curve/table (though I can find the strings which, in the config file, are used to identify each table).

Again, my thanks.


M.
Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Thu May 05, 2016 8:00 am    Post subject: Reply with quote

You're still all over the place and not really describing what it is that you are wanting to accomplish.

That said, if you can change the values in the config file and it has an effect in the game, then change those values to something odd, load up the game, and search for those odd values. Usually, values like these are read-only and may only be loaded once. If that's the case, you may have to adjust your CE settings for your search. If the values are being read several times, it'll be even easier to find them since you may be able to change the values in the config file several times, instead of just once, and narrow in on them during your searches.
Back to top
View user's profile Send private message
MikeSantis
How do I cheat?
Reputation: 0

Joined: 05 May 2016
Posts: 4

PostPosted: Thu May 05, 2016 9:27 am    Post subject: Reply with quote

"still all over the place"

If that's your take on my request, all right.

--

Anyway, my difficulties come from not being able to locate ANY of the values in that table (and in some other parameters). For instance, say one such value is 0.172727389; I search for it as STRING, DOUBLE, FLOAT even ALL, and I get no findings.

So, those values per se are already "odd" enough, so to speak.

My objective ("what it is that you are wanting to accomplish") is as stated in the title of the topic:

to find those values.

Maybe someone has a strategy, a hint of some kind, that enables me to get there. Keeping my fingers crossed here.


Last edited by MikeSantis on Thu May 05, 2016 9:32 am; edited 1 time in total
Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Thu May 05, 2016 9:31 am    Post subject: Reply with quote

MikeSantis wrote:
"still all over the place"

If that's your take on my request...

--
-Sigh. Good luck.
Back to top
View user's profile Send private message
ParkourPenguin
I post too much
Reputation: 140

Joined: 06 Jul 2014
Posts: 4300

PostPosted: Thu May 05, 2016 10:13 am    Post subject: Reply with quote

Are you sure the game even keeps those values around? It could just read them from disk, maybe put them on the stack, do some calculation, and then throw the values out.

When searching for those values, make sure you select "Rounded (extreme)" for the rounding type. Only search for a few digits of precision to start off with, and work your way up from there (i.e. for 0.172727389, search for 0.172). Search through all memory (not just writable) by setting the checkboxes in the "Memory Scan Options" section to grey. Also try setting "Fast Scan" (Alignment) to 4.

You can try a group scan. Selecting "out of order" might help, but that will increase scan time dramatically with many values. Use wildcards / spacing for values you couldn't find and/or you think might be likely to change.

It might be better to find some other value in the game you think would use one of those values on disk and backtrace some instruction which accesses it. Of course, you'll need to have a decent knowledge of assembly to do this, and there's no guarantee you could find it in a reasonable amount of time.

_________________
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
MikeSantis
How do I cheat?
Reputation: 0

Joined: 05 May 2016
Posts: 4

PostPosted: Thu May 05, 2016 10:35 am    Post subject: Reply with quote

@ParkourPenguin,

thank you for your time and reply.

You raised good points.

Each vehicle has a config file, so 30 vehicles equals 30 config files.

That (read values from file, put them on the stack and discarding them) may just be what is happening.

On the other hand, it's still a fileopen and read sequence of operations, the game engine would have to do that every time the player gets out of real time, out to main menu, chooses a different vehicle, for which it has to load all config data...and then back again if he/she chooses the same aircraft. As far as my detection efforts go, I'd say there's only one file ops sequence.

Furthermore, the szString (at least that I was able to find) containing the name of the curve/table doesn't change if I change it in the file AFTER initial game load, vehicle choice and subsequent changes of vehicle - and that leads me to believe the table values are stored somewhere until game exit.

I will try what you suggest (good tips).

I knew this would take a bit of time (perhaps IDA Pro would cut time dramatically...but it's too expensive for me), so I am taking it patiently.

Thanks again.

M.
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