Magic Data Discussion

Posted by TomMK 
Re: Magic Data Tutorial
Date: May 18, 2013 08:57PM
Posted by: addie
schroeder Wrote:
-------------------------------------------------------

...

> for desc51 i found out, that if you set it on 0,
> the ai-cars will drive fast times from the
> beginnig of a session (training,quali).
> with higher values they will drive their fastest
> times towards the end of a session.
> so it raises the track grip or the skills of the
> ai´s
>
> matt

thanks for the info ! seems to confirm/extend the description in the cmagic.ini: "desc51=increase of grip during a session (cc-cars only??)"

matt, did you also experience grip differences while driving ? I mean, does it effect grip in general, or just for the cc-cars ? OK, I'm aware its a subtle thing ...

and, its just practice/qualy, but not the races ?

- - - - - - - - - - - -
please no PMs; but you're welcome at: [addie3 at waa63 dot ch] and [www.waa63.ch]
Re: Magic Data Tutorial
Date: May 18, 2013 09:49PM
Posted by: Atticus.
Meh, I'm not very good at this testing thing.

First of all, thanks for the quick replies addie and Lo2k, SDI and matt.

Indeed, its desc93, which determines garage car angle for both player and AI.

I tried to test 90-95, but can only confirm that desc91 is garage depth. 92 has something to do with this as well. At first I thought it was garage depth for AI, but it seems to be in some way interconnected to 91. So I'm confused. 91 has a minimum around -450. 94 and 95 seems to be some finetuning of 91 and 92.

Anyway, I set 93 to 16384 for cars parallel with the track in Monaco '67, for realism - although cars now have trouble exiting their 'garage' if their teammate parks right ahead of them. And I set 91 to be as close as possible to the track, practically between the walls of the two straights.

Also, desc90, or 'handbrake' as addie suggested, is a funny thing. At first I was confused what handbrake could mean, but soon I discovered I cannot leave my garage in FP. Oh well... I don't know why is that line necessary, or what is its purpose, so I welcome any more info on that.

And one final thing, this time on desc51: it is strange, because for 0, I experienced the same as matt, but still, at 30000 (the original is 64768), I experienced TomMK's info - which is AI spinning out because of braking too late. How is that?



Edited 1 time(s). Last edit at 05/18/2013 09:51PM by Atticus..
Re: Magic Data Tutorial
Date: May 18, 2013 11:09PM
Posted by: Atticus.
Two other minor things: desc94 and 95 actually does not seem to affect car position in garage. However, they could affect pit crew position. When I modified them, the crewmen were not positioned correctly in relation to my car when putting it down.

Also, when I modified desc91 without modifying desc92, my car ended up at a different place than the AI cars. When I did an FP run alone with the same version of magic data, it strangely began to slide in the garage without me doing anything.

As I said, I'm not really good at testing... It's a mess currently. I should probably test it on a more standard track than Monaco '67 though.
Re: Magic Data Tutorial
Date: May 18, 2013 11:55PM
Posted by: Atticus.
Sorry for the triple post, but this really deserves a separate one.

I just found this.

[gadareth.altervista.org]

I don't know if you guys are familiar with it, but it gives a lot of details, not just regarding some ?????s, but some of the known stuff as well. But - for now - sticking to our ?????s, this is what the above page suggests:

desc73=nr of segments before cars break rail-line at the starts
desc74=poletime (e. g. 70800 equals 1:10.800)
desc75=poletime finetune (+/-1000 equals +/- 1.0)

Desc74 and 75 obviously refers to the original tracks, if not modified since then. I tested desc73 and it could really cause issues at the start, if I lower it to, say, 1.

There are still some unknown values left, but we are edging closer. :-)
Re: Magic Data Tutorial
Date: May 19, 2013 09:05AM
Posted by: addie
Atticus. Wrote:
-------------------------------------------------------
> Sorry for the triple post, but this really
> deserves a separate one.
>

thanks for all three posts, more are welcome too :) very interesting link !

as for the "handbrake", I recall to have labeled it that way, when I was testing "monaco pits", having the "default" value in desc90 instead of the "monaco" value, the jacked cars "drifted away" (or maybe it was just the players car, or the car with the focus), not neccessarily forward or backward, but they moved. only as soon as I posted the "monaco-value", the cars stayed solid. but I did no further tests with other values then ...

- - - - - - - - - - - -
please no PMs; but you're welcome at: [addie3 at waa63 dot ch] and [www.waa63.ch]
Re: Magic Data Tutorial
Date: May 19, 2013 12:04PM
Posted by: Atticus.
Ah, I see. I also had that drifting or sliding effect on the player car in FP mode when I applied the default Monaco desc91, but left the desc92 value at its other track default. But only in that specific case. Leaving handbrake off (on 0), and modifying desc91-92 carefully in tandem offset this effect anyway.

The reason why the purpose of desc92 is still a mystery for me is that in other cases in FPs of race weekends modifying desc91 without adjusting desc92 resulted in different postion for player car and different for AI cars.

I also noticed that the also mysterious desc51 is set to 0 for the original Suzuka, but is on its default 64768 for most other tracks. Cars do get faster with 0, but do crash out with 30000. I don't understand.
Re: Magic Data Tutorial
Date: May 19, 2013 12:52PM
Posted by: addie
Atticus. Wrote:
-------------------------------------------------------

..

> I also noticed that the also mysterious desc51 is
> set to 0 for the original Suzuka, but is on its
> default 64768 for most other tracks. Cars do get
> faster with 0, but do crash out with 30000. I
> don't understand.


maybe the value has to be interpreted at as "integer" instead of "cardinal" to make more sense.
in computers there are just figures, 0 and 1 usually, combined to higher figuers starting at 0 incrementing up to whatever, eg 65535. this range 0..65535 is what is basically used in magic data, a so called "word" of data.

but this figure 0..65535 also could be interpreted as a so-called "integer", meaning a range of
-32768 .. 32767 (or so). point is, 0..32767 remains the same, but then the next increment, 32768, actually is interpreted as -32768, and from there the counting goes backwards, and you end up with 65535 actually meaning -1.

so if thats the case, the figure 64768 actually would mean -767.

starting at 0 up to 32767 we had possitive values
starting at 65535 down to 32768 we had negative values, starting at -1 for 65535 (so eg 65435 means -100).

so you may want to test with 0, 1000, 2000, 3000 .. for positive values, but then also 64535, 63535, 62535 .. for negative values (-1000, -2000, -3000 ..)

a value of 30000 may be quite far out for that value ..



(I hope this descriptions doesnt sound too weird :) however it sure could be more precise)

- - - - - - - - - - - -
please no PMs; but you're welcome at: [addie3 at waa63 dot ch] and [www.waa63.ch]
Re: Magic Data Tutorial
Date: May 19, 2013 01:03PM
Posted by: Atticus.
Well, I had to go for it two or three times, but it is completely clear now - although very strange as they could have simply chosen -32768-32768 for a range.

So, if I understand well, 0 and 64768 almost means the same, and they are nearly the two closest value to the theoretical centerpoint of the range (which is at 0 and 65536).



Edited 1 time(s). Last edit at 05/19/2013 01:31PM by Atticus..
Re: Magic Data Tutorial
Date: May 19, 2013 02:05PM
Posted by: aw2071
Atticus. Wrote:
-------------------------------------------------------

..

> So, if I understand well, 0 and 64768 almost means the same

if my guess is correct, yes. actually its 0 and -767 (or -766, or -768 ? it always twists my brain :)
btw to get those -767, all I did was subtracting 64768 from 65535.

the term "almost the same" depends on how the value is used in gp4. maybe -767 is the minimum possible, and +767 is maximum possible, maybe 0 is maximum possible. maybe 29999 is maximum possible. hard to tell. sure is, 0 is possible, and 64768 is possible, as they show up in original tracks, and it seems sure, as you mentioned, 30000 is TOO big, because gp4.exe crashes.
Re: Magic Data Tutorial
Date: May 19, 2013 02:19PM
Posted by: Atticus.
Well, actually, the cars crash into the barriers in-game, not the game itsself. So the game can handle 30000 as well, that's why I thought of that big range.

And they crash into barriers by braking too late, so the AI aggressiveness label fits the desc perfectly. As for what matt wrote that at 0 the AI is quicker at the beginning of the stints than at 64768 (-767 then), also makes sense as it is a higher value on the adjusted scale, so AI is slightly more aggressive in that case.

As for me, I will now turn my attention to the other unknown values - at some of which the existing descriptions do hint at the areas where to look for the solution, e. g. helps decide if a tyre set needs changing. I think I will look into this data and see if the AI makes its pit stops at the beginning, at the end or in the middle of its given pit windows predominantly.
Re: Magic Data Tutorial
Date: May 19, 2013 11:44PM
Posted by: Atticus.
I found an old thread from this forum discussing the last two lines of the magic file:

[www.grandprixgames.org]

However, as a result, my guess is that most of us were aware of what these values do except for me, so I won't present these findings as new info.

This leaves us just 13 unknown lines anyway:

desc49=????? - subtracted from diff between field_e2 of 2 cars and then compared to speed of first car
desc76=????? - helps decide if a tyre set needs changing? (dw)
desc77=????? - same as above (dw)
desc79=????? - segment nr (start of some range)
desc80=????? - segment nr (end of some range)
desc82=????? - unk (dw)
desc83=????? - unk (dw)
desc86=????? - unk (dw)
desc87=????? - unk (dw)
desc88=????? - new (dw)
desc89=????? - new (dw)
desc94=????? - pit crew garage pos for player?
desc95=????? - pit crew garage pos for AI?
Re: Magic Data Tutorial
Date: May 20, 2013 05:31PM
Posted by: Atticus.
Yet more old discussions from this forum.

[www.grandprixgames.org]

Don't let the topic title fool you; from p. 2 on, it gets immensely interesting.

It is for GP3, but I can imagine it works pretty much the same for GP4 as well.

This post has particular relevance:

[www.grandprixgames.org]

To this two values:

desc76=????? - helps decide if a tyre set needs changing? (dw)
desc77=????? - same as above (dw)

So we can say that these two adjust what the game thinks of as crossover points between dry-to-wet and - I suppose - wet-to-dry conditions. And it calls you and the AI in for dry/wet tyres as aggessively as you let it with the modification of these values.



Edited 1 time(s). Last edit at 05/20/2013 05:32PM by Atticus..
Re: Magic Data Tutorial
Date: May 20, 2013 06:21PM
Posted by: Atticus.
Aand still one more relevant post:

[www.grandprixgames.org]

This one is from the same topic I quoted above, but it relates to a different desc. It is about this:

desc49=????? - subtracted from diff between field_e2 of 2 cars and then compared to speed of first car

Basically it says that field_e2 of a car is one value of 300 each car registers when making laps around the track. Its own description is NumFeetIntoLap, in other words how many feet of that lap did the car do up to the given segment - so 'diff between field_e2 of 2 cars' is basically the distance between two cars on the track in feet.

My hunch is that this should have something to do with the slipstream, although this - as basically - all other findings above needs testing.

Still, I think it is cool to at least have some initial thought on what to look for, when one decides to test and seeks to understand each magic data value more.

EDIT: belini from the GP3 forums confirmed this line is related to the slipstream, but he found that it has no major effect.

[www.grandprixgames.org]

It has a range from 128 to 512 for the original tracks, and it is highest for Spa (512), Monza (512), Indy (512), Sepang (512). Monaco (384), Melbourne (384), Barcelona (256), and all others are 128.

I tested some power of twos in Monza, like 2, 128, 512, 1024, 2048, but indeed I did not notice any difference in the way the slipstream worked.



Edited 2 time(s). Last edit at 05/21/2013 01:17AM by Atticus..
Re: Magic Data Tutorial
Date: May 21, 2013 03:00PM
Posted by: Atticus.
TomMK Wrote:
-------------------------------------------------------
> OK, I have been working on understanding Magic
> Data for a few more days and have found out some
> more:
>
> Tyre types - As we know, values range from 52-55.
> I believe lower values indicate a harder, slower
> compound. Have a look at these results:
>
> Track = Spa-Francorchamps 2011
> Race type = Quickrace (15% distance)
>
> Tyre Type / Average Fastest AI lap time:
> Type 52 = 1m 50.8
> Type 53 = 1m 50.2
> Type 54 = 1m 49.6
> Type 55 = 1m 49.0
>
> These average lap times were calculated using lots
> of simulations and show a clear pattern.
>
> In the 17 original tracks' Magic Data, the first
> value is always higher (that is softer, according
> to my findings). Interestingly, this makes me
> think the labels in TSM ( "Hard" / "Soft" ) are
> the wrong way around.
>
> The "type" value determines which compound the AI
> cars run. A value of 100 (it is 100 in all of the
> 17 original tracks magic data) makes the AI choose
> the first compound. A value of 0 makes them choose
> the second.


I can confirm this.

I ran a qualifying session on Ace level on the original Silverstone track (with my personal 2013 perf and physics files), and tyre type 55 provided a pole time of 1:16.8, while tyre type 53 (the original in the magic data, which the AI choose) gave one of 1:17.5, a huge difference, clearly on the account of the tyre type change.
Re: Magic Data Tutorial
Date: May 21, 2013 03:56PM
Posted by: Atticus.
Furthermore, I tested desc91-95 more extensively on an original 2001 track, and I can now confirm that

- desc91 regulates garage position depth for the player car,
- desc92 gives garage position depth for the AI cars,
- desc94 tells pit stall position depth for both player and AI,
- desc95 finetunes the latter.

As for ranges, all that is certain is that you cannot go as close to the fast lane of the pit as you want, there is a threshold for both garage depth and pit stall depth. If you gives it a value higher than this - yet unknown - threshold, the game simply puts you back, either to the default position, or begins another cycle of the available range.

Desc93 is car orientation in garage, but that is already known.
Re: Magic Data Tutorial
Date: May 21, 2013 04:24PM
Posted by: Prblanco
Just stopped to say that I'm loving all the investigation in this thread :)


My unfinished tracks: [www.grandprixgames.org]
Send bug reports and track editing questions to f1virtualblog@gmail.com
Re: Magic Data Tutorial
Date: May 21, 2013 07:26PM
Posted by: Atticus.
Prblanco Wrote:
-------------------------------------------------------
> Just stopped to say that I'm loving all the
> investigation in this thread :)


Thanks. :-)

Confirmations on the following lines:

desc76=????? - helps decide if a tyre set needs changing? (dw)
desc77=????? - same as above (dw)

Desc76 manages when the AI pits for drys on a drying track and for wets on a track which gets wetter. The higher the value is, the sooner the AI reacts to changes in track conditions. Its range should be 0-65536, I believe, although the original tracks do not go above 16413 so very high figures would be unrealistic. Of the 17 original GP4 tracks Monte-Carlo (15413), Hungaroring (15453), and Melbourne (15400) has the highest value, while Montreal (9053), Sepang, Monza and Indianapolis (9373) has the lowest value.

Desc77 seems to finetune it, I did not notice much difference by changing its value.

It is important that both affect AI only, they have absolutely no effect on the player team calling the player into the box for drys/wets. Edit: I found this out by decreasing desc76 to 0 (i. e. no pit calls for wets/drys) and began a monsoon race on soft drys in Silverstone! :D I was only praying for it not to affect player pit calls and luckily it did not: my pit called me in at the same time as it did with higher values, so it had no effect. IT was on lap 1 instantly, so I didn't have to drove slow, painful and difficult laps in the rain. :D



Edited 2 time(s). Last edit at 05/22/2013 09:36AM by Atticus..
Re: Magic Data Tutorial
Date: May 22, 2013 02:03AM
Posted by: TomMK
Great to see this investigation continuing guys, great work!!

=====================================================


Intel NUC 8i3, 8GB RAM, MS Sidewinder Wheel
Re: Magic Data Tutorial
Date: May 23, 2013 09:09AM
Posted by: TomMK
Atticus. Wrote:
-------------------------------------------------------
> - desc91 regulates garage position depth for the
> player car,
> - desc92 gives garage position depth for the AI
> cars,

I've noticed these values are different in all the original tracks (player = 1814, AI = 896). Why would that be the case? Surely the Player car and AI cars should be the same "depth" from the pit lane?

=====================================================


Intel NUC 8i3, 8GB RAM, MS Sidewinder Wheel
Re: Magic Data Tutorial
Date: May 23, 2013 09:56AM
Posted by: Atticus.
@TomMK: They are.

They are just on different scales somehow. If you try 0 for both for example, you will notice the player car will be further forward. But still, modifying them separately reveals that they are independent from each other - the former gives the player pos, the latter the AI pos.
Sorry, only registered users may post in this forum.

Click here to login

Maintainer: mortal, stephan | Design: stephan, Lo2k | Moderatoren: mortal, TomMK, Noog, stephan | Downloads: Lo2k | Supported by: Atlassian Experts Berlin | Forum Rules | Policy