Tracks Absolute newbie needs help creating track

I've just started on a basic street track, and i created the very basic geometry for now just to test the concept. I'm using blender. After I exported to fbx and opened it in the kunos editor, I see nothing. Could someone help take a look at my blender file and point me in the right direction? I have no idea what I'm doing wrong.

[Link updated again - applied scale to start/end points, and added ferris wheel geometry]

It's very minimal, I just need to get the basics right first before I add more geometry and materials.

Thank you so much!
 
Last edited:
When exporting to FBX and importing it into the ksEditor, I could see the track.
Untitled.png

I'm guessing you have some export settings wrong. Try these settings:
FBXexport.png


A lot of your objects still have a scale applied to them. Reset their scale to 1 by applying the scale with CTRL+A > Scale. This will definately help with some lighting/shading issues.

As you can see in the attached screenshot above, some of your mesh has the normals flipped. You can easily see this by turning on "Face Orientation". You can do this by going to the top-right of your viewport and click the arrow next to the two circles icon, and there you'll see it. It should all be blue when facing towards you, and red when facing away (=wrong direction if it's facing the camera). You can flip normals by selecting the faces, ALT+N > Flip.
2021-10-06 06_20_07-Window.png
Your vegetation object (Plane.001) is one of them, ideally you don't want ngons anyway so triangulate that (when face is selected > CTRL+T).
 
Thank you so much... I was about to give up on all this. Thanks to you I finally got it to show in the kunos editor. I think the thing that did it was the scaling to 0.1.

I've flipped the normals as much as I can but if I view from the underside there are still a lot of normals facing the wrong way.. but no ones going to see underneath so I left it that way. I also applied scale to everything. So right now I have the basic geometry done.. it's quite dense so I need to remove the building complexity next.

I was wondering how the Kunos editor is supposed to work. Is the viewport supposed to represent the in-car view? How do I move around the track in the Kunos editor?

Ive also updated the link to the blender file in the first post, in case anyone wants to see it and offer suggestions.
 
You're welcome :)

I've flipped the normals as much as I can but if I view from the underside there are still a lot of normals facing the wrong way.. but no ones going to see underneath so I left it that way.
AC (and many more game engines) do not support double sided polygons, so wherever you see a polygon from the underside, it will not show from above. They'll stand out in game eventually so they're easy to spot. Another method can be to do a recalculation of the normals (ALT+N > Recalculate Outside), to save you from having to go around every polygon to check.
In all quickness I didn't see any, though.

I also applied scale to everything. So right now I have the basic geometry done.. it's quite dense so I need to remove the building complexity next.
Nothing wrong with dense geometry. With good LOD models/distances the game will run it just fine. Try first, worry later :p
But there are a few unnessecary polygons, especially in the rows of houses. That could pretty much be 5 polygons instead of 100+ (due to repeating)

I was wondering how the Kunos editor is supposed to work. Is the viewport supposed to represent the in-car view? How do I move around the track in the Kunos editor?
The ksEditor works similar to the F7 view ingame.
Look around by using the mouse with left mouse button.
Move around using the arrow keys. CTRL makes you go faster, SHIFT makes you go superslow, CTRL+SHIFT is somewhere in between fast and normal.
Change FOV with the mouse wheel.
Point and click on objects with the right mouse button.
At the bottom you have a few tabs. Make sure the weather and PP filter are set "correctly" on the Illumination tab.

Concerning materials and textures, there's a whole thread on them on the AC forums. Or use the CM Inspector tool ingame to see values and texture slots used.
 
I just tried to assign shaders in the kunos editor and got this error:
1633665394748.png


Does anyone know what's wrong?

Anyway, I'm really eager to just get it working enough to do a drive through the environment, without any fancy materials added yet. Is the process as simple as just adding shaders to the fbx file, exporting to kn5, and then loading AC? I've already added the spawn points to the blender file.

Anyway, I spent yesterday tidying up the geometry, removing as many vertices as I can to simplify the buildings. I'm at 69k vertices now for my building mesh, and the kunos editor still won't load it, so i still need to spend time on this. I also removed all the unecessary materials and the file size dropped to around 20mb.

I've updated the blender file link in the first post. If anyone wants to take a look and have some suggestions on where I can remove detail that'd be great!
 

Attachments

  • 1633665376944.png
    1633665376944.png
    677.5 KB · Views: 73
Last edited:
Don't remove detail, just split those buildings into multiple objects. Be smart about that and use either the (future) materials to split the objects, or use quadrants so the game can cull them when not in view.
The game can easily handle 2M triangle tracks, but 65k vertices is the import limit for one object (there are hacks but best to refrain I guess).

If you have your folder setup correctly (i.e. copied this from, say, imola, and renamed the things that matter), it is as simple as making sure every material has a texture (this can be a 1x1 grey texture file, for instance), exporting to kn5, and running the game.

You have spawn points, you say, but this is incorrect.
You need AC_START_0 (this is where you start "on the grid"), AC_PIT_0 (this is where you start "in pitlane"), AC_HOTLAP_START_0 (this is where you start in hotlap mode).
Then you need your timing gates. In your case it looks like you want to use A2B-layout. Then you will need AC_AB_START_L / AC_AB_START_R to the left and right of your starting line, and AC_AB_FINISH_L / _R at the left and right of your finish line.
 
You don't need to start of with some complex shader like a multimap one, just use ksPerPixel and use this for the first few rows and a simple single color texture file:
Code:
ksAmbient 0.3
ksDiffuse 0.3
ksSpecular 0.3
ksSepcularExp 100

Did it throw that error message on trying to save the track? I think it throws a cryptic error if you try saving a track with a shader that has not all texture slots used.
 
Last edited:
You don't need to start of with some complex shader like a multimap one, just use ksPerPixel and use this for the first few rows and a simple single color texture file:
Code:
ksAmbient 0.3
ksDiffuse 0.3
ksSpecular 0.3
ksSepcularExp 100

Did it throw that error message on trying to save the track? I think it throws a cryptic error if you try saving a track with a shader that has not all texture slots used.
I'm not sure what I'm doing wrong, but in the KS editor, right after I open the fbx file, and go to the shader tab, as soon as I select ksperpixel, I get an unhandled exceptioon error - object reference not set to an instance of an object. But if I don't go to that tab, I can view the track in the ks editor scene tab. I've uploaded the blender source file, if you have time, maybe you can take a look? If you can import into kseditor and edit the shaders fine, then there's something wrong on my end.

Anyway, if anyone here is interested in this project, you're welcome to join. I'm just interested in bringing this track to the game.
 
Don't remove detail, just split those buildings into multiple objects. Be smart about that and use either the (future) materials to split the objects, or use quadrants so the game can cull them when not in view.
The game can easily handle 2M triangle tracks, but 65k vertices is the import limit for one object (there are hacks but best to refrain I guess).

If you have your folder setup correctly (i.e. copied this from, say, imola, and renamed the things that matter), it is as simple as making sure every material has a texture (this can be a 1x1 grey texture file, for instance), exporting to kn5, and running the game.

You have spawn points, you say, but this is incorrect.
You need AC_START_0 (this is where you start "on the grid"), AC_PIT_0 (this is where you start "in pitlane"), AC_HOTLAP_START_0 (this is where you start in hotlap mode).
Then you need your timing gates. In your case it looks like you want to use A2B-layout. Then you will need AC_AB_START_L / AC_AB_START_R to the left and right of your starting line, and AC_AB_FINISH_L / _R at the left and right of your finish line.
Thank you, I've started grouping the major building masses into smaller groups. For now, I'll just be assigning basic colors to them in blender. I've also updated the spawn points following what you said.

I've tried creating the folder structure. I copied imola to a new directory, deleted the files but kept the folder structure. Then I set the material properties in the kseditor material tab, and gave everything KsPerPixel values of around 0.3. But I get this error when I try to export.

1633687914285.png



I assume it's because I need textures? I can't just assign colors for now?

-----
EDIT:

ok, I just managed to assign texture files to all materials in my track, and I exported a kn5 file and put it into the folder I copied off the original imola track.

1633688929003.png

After editing the track info json file and selecting the track in content manager, I got a black screen.

1633689005686.png



Did I miss something out?
 
Last edited:
Did I miss something out?
CM sometimes does this. Have you tried quitting and relaunching a practice session?
In any case, the log.txt inside the /documents/assetto corsa/logs/ folder can provide some useful feedback while modding.

If you want, you could upload the track folder to, say, Google Drive, so it's easier to troubleshoot with you :)
 
Thanks, I tried CM again and still get the black screen regardless of hotlap/practice/race.

I've uploaded the kn5 folder to google drive.


And the latest blender file is in the first post.

I was wondering about the kseditor process. Does this mean everytime i export a fbx from blender, I have to manually reassign shader materials to every single object in kseditor? Originally I didn't keep my texture files; i just attached them as materials to the blender objects in blender and they were all saved in the .blend file. But that meant that when going to the kseditor stage i had no png files to attach to objects. So does this mean I'm supposed to keep a folder with all the source png texture files for this?
 
Last edited:
I was wondering about the kseditor process. Does this mean everytime i export a fbx from blender, I have to manually reassign shader materials to every single object in kseditor? Originally I didn't keep my texture files; i just attached them as materials to the blender objects in blender and they were all saved in the .blend file. But that meant that when going to the kseditor stage i had no png files to attach to objects. So does this mean I'm supposed to keep a folder with all the source png texture files for this?
No, that is what the persistence file is for. As long as you don't change the name of the fbx file it will load the material settings you saved in the persistence file.

As such my workflow is working from the blend file, then always exporting and overwriting the same fbx file I then open in the KSEditor. For the textures you need a folder called "texture" on the same folder level as the fbx and persistence file.
 
Last edited:
1.jpg

works here. Scale of everything seems a bit off :D

____
ok, played around a little further, made a new export from the blend file with my typical export settings (0.01 scale). I had to trail&error a lot as some objects don't have materials applied.

All the AC obejcts need to be scaled to 1,1,1. Your pit guy stretches into the sky on the z-axis.
2.jpg
 
Last edited:
No, that is what the persistence file is for. As long as you don't change the name of the fbx file it will load the material settings you saved in the persistence file.

As such my workflow is working from the blend file, then always exporting and overwriting the same fbx file I then open in the KSEditor. For the textures you need a folder called "texture" on the same folder level as the fbx and persistence file.
I don't quite understand this. I did some searching but can't find much. Is this persistence file an ini file? Stored in the "texture" folder you mentioned? Is it created by blender or kseditor? I'm guessing it would be created by kseditor, after you've opened the fbx, assigned the materials and saved the kn5 for the first time? I don't see it in my kseditor or fbx directory even after I've saved the kn5.
 
View attachment 508401
works here. Scale of everything seems a bit off :D

____
ok, played around a little further, made a new export from the blend file with my typical export settings (0.01 scale). I had to trail&error a lot as some objects don't have materials applied.

All the AC obejcts need to be scaled to 1,1,1. Your pit guy stretches into the sky on the z-axis.
View attachment 508405

Yes, I guess it's off because I did an import from blender's OSM plug in and didn't set any measurements. The buildings will be correclty scaled relative to each other, but probably not relative to the world... I have been exporting to fbx using a 0.1 scale factor; i see you used 0.01. Are there any specific units and scaling settings I should use in blender, so I don't need to set a scale factor when exporting to fbx?

I don't have a pit guy. Do you mean the black box? That's supposed to be the pit start point, I used a empty cube in blender to represent it. I just revised my blender file and Applied Scaling to all objects, that should fix it.


Anyway, somehow I got it to load in AC already. No idea what I did but I see the track in AC practice mode. But the car start position is spinnng.

1633744151819.png


In the Blender file, I already set the scale and rotate of the start points to 1,1,1.
 
I don't quite understand this. I did some searching but can't find much. Is this persistence file an ini file? Stored in the "texture" folder you mentioned? Is it created by blender or kseditor? I'm guessing it would be created by kseditor, after you've opened the fbx, assigned the materials and saved the kn5 for the first time? I don't see it in my kseditor or fbx directory even after I've saved the kn5.
this is my typical folder structure
1.jpg

the DOM blend file is what I work in (just named that as I started working of public LiDAR data, "Digitales OberflächenModell"), the acc_oschersleben.fbx is what I export to, the acc_oschersleben.fbx.ini is the persistence file the KSEditor saves automatically in that place. The "texture" folder is the active texture folder, the "texture_backup" folder is where the KSEditor puts texture files if you use the Texture Review tool to filter out unused files. "kn5" I made myself, it's where I save the kn5s to, which I then copy the content/tracks folder. I don't work directly in the AC directories.


the black box on my screenshot is from the track map display. I meant this regarding the pit guy, he get's spawned automatically where the AC_PIT empty is placed:
2.jpg

he's a tall fella it's moving slightly hence I know it must be the pit guy

there's still scale on the Empties in the blend you uploaded:
3.jpg
 
Last edited:
Thanks, the folder structure you use is easy to organize. I'll adopt that.

I still have a problem with the kunos editor, everytime I open the fbx it's fine, but as soon as I click on the "material " tab I get this error:
Code:
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
   at ksEditor.Form1.cmbShader_SelectedIndexChanged(Object sender, EventArgs e) in i:\Manu\Documents\ac-source-pc\ksEditor\Form1.cs:line 1038
   at System.Windows.Forms.ComboBox.OnSelectedIndexChanged(EventArgs e)
   at System.Windows.Forms.ComboBox.WmReflectCommand(Message& m)
   at System.Windows.Forms.ComboBox.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4400.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
ksEditor
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///Z:/Steamgames/steamapps/common/assettocorsa/sdk/editor/ksEditor.exe
----------------------------------------
System
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4360.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Windows.Forms
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4400.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4390.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Configuration
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4190.0 built by: NET48REL1LAST_B
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Core
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4390.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Xml
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4084.0 built by: NET48REL1
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
ksNet
    Assembly Version: 1.0.5884.33843
    Win32 Version:
    CodeBase: file:///Z:/Steamgames/steamapps/common/assettocorsa/sdk/editor/ksNet.DLL
----------------------------------------
Microsoft.GeneratedCode
    Assembly Version: 1.0.0.0
    Win32 Version: 4.8.4084.0 built by: NET48REL1
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
ksMathCore
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///Z:/Steamgames/steamapps/common/assettocorsa/sdk/editor/ksMathCore.DLL
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.

This error strikes me as odd:
System.NullReferenceException: Object reference not set to an instance of an object.
at ksEditor.Form1.cmbShader_SelectedIndexChanged(Object sender, EventArgs e) in i:\Manu\Documents\ac-source-pc\ksEditor\Form1.cs:line 1038

because my steam app and steam games/blender/assettocorsa/kunos editor are all installed on Z:. My i: is just a data drive that's totally unused by them. There is no i:\Manu directory at all.

I can "continue" past this error instead of quitting the app, but I'm guessing it's causing some problem. After adding the material textures in Kunos editor, I also don't see any .ini persistence file anywhere. Could be related to this.

I've 'applied' scale to the empty pit boxes again, if they still result in the pit guy being too tall, there must be something wrong at my end. I've updated the blender file in the first post again, and added more geometry for the ferris wheel.

With this file, my problem is still the same. When I load the track into AC, my car starts off spinning. I have no idea what is wrong. My Blender export settings for the fbx are:

scale 0.01
forward: z forward
up: y up

For you, does the car start off rolling and falling, or does it start on the track?

Can I also know how you got to the track map in Kunos editor? I don't see it in the tabs.
 
Last edited:
This error strikes me as odd:
System.NullReferenceException: Object reference not set to an instance of an object.
at ksEditor.Form1.cmbShader_SelectedIndexChanged(Object sender, EventArgs e) in i:\Manu\Documents\ac-source-pc\ksEditor\Form1.cs:line 1038

because my steam app and steam games/blender/assettocorsa/kunos editor are all installed on Z:. My i: is just a data drive that's totally unused by them. There is no i:\Manu directory at all.
those debugger messages refer to one of the developers, https://www.assettocorsa.net/forum/index.php?members/6s-manu.971/ I suppose, you can ignore those.

I can open and change stuff in the Materials tab with no issue, no idea what's causing this. What Blender version are you on? I'm on 2.93 beta

can you open and change these files? https://www.dropbox.com/s/i0p823o8mqfjcki/mymarinacoastalexpressway.zip?dl=0
 
I'm on Blendr 2.93.5.

I downloaded your archive with the fbx file, and I get the same error in kunos editor when I switch to the material tab and click on ksperpixel.

Anyway, i exported your fbx to a kn5 file and tried a practice lap in AC, I get a similar but different problem, the car starts upside down and lands upside down on the track and then stops rolling. When I used my own file, the car keeps spinning up/down at the start position and does not stop spinning. I'm sure the pit/start points in my blender file are correctly oriented, and i scaled to 1,1,1 already.
 
Wondering at this point if there's an issue with your AC/KSEditor install.

And no I haven't actually tried driving on it yet, but the car did not fall through the ground.
edit: just tried it, can drive the whole "blue road" no issue
 
Last edited:

Latest News

What's needed for simracing in 2024?

  • More games, period

  • Better graphics/visuals

  • Advanced physics and handling

  • More cars and tracks

  • AI improvements

  • AI engineering

  • Cross-platform play

  • New game Modes

  • Other, post your idea


Results are only viewable after voting.
Back
Top