AIW file editing

sdecorme

Hi,
I've recorded a pilot trajectory with a plugin and I would like to transfer it to the AI path.
How can I do? I think I must use the aiw file but where can I find the file structure.

Thanks you
 
I'm not sure if i understand what you mean with "pilot trajectory" Google translator gives me a ****ty translation :D.

Isn't the plugin giving you more information?

The AIW files are always in the trackfolder and have the ending ".AIW" and they are normal textfiles.
And normally you use the AIW-editor to change these files.
 
I've recorded in a text file the race of a pilot with a special dll.
Now I would like to convert a lap of this race into the ai path.
I've understand that the ai informations are stored in the aiw file , but I don't understand how to pu my data in this files.
 
Where did you get the dll from?
Is it a part of a tool?
Is it compatible with rfactor-format?
Can you post some lines of your textfile?
 
The dll is a selfmade from the Rfactor sample and the text file is a binary file so you can read it , but it looks like this.
X_position Y_position Z_position Speed X_Acceleration Y_Acceleration Z_Acceleration and some other data.
I've logged all the acceleration position and car attitude , now how can I convert them in the aiw format.
 
Sorry, but i have no idea.
Because you've created the dll by your own, you normally should be the first to know how to get the data in game...
Or better, why didn't you made the dll in that way that it gives you the needed data-format?

But anyway, the question is: why don't you simply use the AIW-editor to create a new path?

When you look into the AIW-files of the tracks, each waypoint has different information.
When you create a new AIW-file with the AIW-editor, this information is taken from the line you drive, the speed you go and so on.
 
What I want, Is to extract from a race the best pilot path and to convert it for the AI.
Of course I know how to get all the point of my car but I don't know how to use thel in the AIW file that why I'm looking for the aiw file structure.
 
I fear that your method you try to get the fastest path for the AI will not work as you want.
My experience with creating a fast path is not to drive the line with "cutting" curbs and try to make curves a straight.....

The AI runs faster when you drive a smooth line without touching curbs. The AI will go over the curbs later anyway.
 
Ok I understand what you mean , but if a pilot have a good path on a track why the AI can't have the same path ?
DO you have information about the [waypoint] definition in the aiw file ?
 
Unfortunately i can't give you the exact meaning of each line that is defined for each waypoint.
One gives you the Position, another the speed, cutting...
But i've never found any explanation for all these entries.

But to the "fast" path of the AI i can tell you that, like i've said before, the AI gets faster when you don't drive the fastes line with the AIW-editor.
I think that it is a question of programming from ISI.

You for example have the option to set the "Autocalibrate AI Mode" in the *.PLR file, what means that when you set it to "1", the AI will learn to get better and better and keeps this for future session (Explanation for this entry normally is added at the end of the line in the *.PLR) .
But i don't know if that will help you because i drive offline almost never and so i have no experience with it.

But even when it is set to 0 the AI never follows exact the line that is given in the AIW file.
And that is what i mean, even when you get your line into the AIW file, it is not guaranteed that it will be the best line for the AI.
 
I've found some information about the aiw file, for example:
wp_pos : Waypoint position
wp_perp : Direction vector for this waypoint
I don't finish to understand them all, for each waypoint you have

wp_pos=(972.6858,435.4503,-598.5822)
wp_perp=(0.9491,-0.0010,-0.3151)
wp_normal=(-0.0120,0.9992,-0.0392)
wp_vect=(1.4965,0.1841,4.2200)
wp_width=(4.145,4.148,8.291,8.296) // road left, road right, far left, far right
wp_dwidth=(8.291,8.296,0.000,0.000) // collision left, collision right, cut left, cut right
wp_path=(2.2606,0.0000) // latitude for dry line and wet line (offset from wp_pos along wp_perp)
wp_lockedAlpha=(0) // (used for editor specific algorithms)
wp_galpha=(0.0000) // alpha for groove
wp_groove_lat=(-0.573067)
wp_test_speed=(-1.000000)
wp_score=(0,32.527) // sector ID, distance into lap
wp_cheat=(-1.0000) // multiplier to tweak the speeds through this point.
wp_wpse=(0,0) // some special events
wp_branchID=(0) // 0 = main, 1...whatever pit lanes
wp_bitfields=(0) // 1 = nonpath waypoint.
wp_lockedLats=(1) // editor specific variables
wp_multipathlat=(-0.0950, 0.4224) // inside lat, outside lat (for multiline tracks...like ovals)
wp_pitlane=(1) // what pitlane I'm a part of (only relevent for non-path waypoints)
WP_PTRS=(308,1,-1,0) // prev waypoint id, next waypoint id, branch waypoint id, path of branch wp

I think it will be a big work , I like it ...
 
Yes that really will be a lot of work.
Maybe you find a way to create a kind of "importer" or something like that.
Good luck.
 

Back
Top