BeamNG.drive

BeamNG.drive

View Stats:
path Jul 23, 2019 @ 8:21am
how to edit material friction in map editor
i want to make the terrain have very high friction, but i cant find the option to change it
< >
Showing 1-5 of 5 comments
Nadeox1 Jul 23, 2019 @ 8:25am 
You cannot edit Groundmodels within the editor, and it's also not advised to really change them, as it will affect all the other maps as well.
path Jul 23, 2019 @ 8:30am 
well what can i do to have a large flat high friction area to drive on?
Nadeox1 Jul 23, 2019 @ 11:52pm 
Ok, to be clear: You don't want to edit the friction values. The game comes with different 'GroudModels, which are basically what determines if a road is asphalt, dirt, grass, and so on.

The highest friction groundmodel we have is the 'prepped asphalt' which is the one used in the West Coast drag strip (sticky asphalt)

What you want to do is having a material in your terrain, that is using that groundmodel, so that you can paint part of your terrain with that material (F11 World Editor > F3 Terrain Painter)



This varies depending on how you set up your level files, but you can have a look at official levels to see how they work there.

For example go to the game's directory > content > levels > GridMap > art > terrain > materials.cs (open with notepad)

You will see that every 'TerrainMaterial' has an 'internalName' value. That what define the groundmodel.

What you need to do is going to your own level folder, find the materials.cs file that contains your TerrainMaterial(s) and either add a new one, or edit an existing one, and change the internalName to "asphalt_prepped" (sticky asphalt).

Then if you paint your terrain with that material, that part you painted will be using that groundmodel.
path Jul 24, 2019 @ 8:18am 
ill try using that material, but if it is not enough friction, how do i edit the actual friction values for a terrain or a large flat object?

EDIT: to clarify a bit more, if editing terrain friction values is impossible, what if i were to make a cube, then stretch that cube out as far as i can be bothered in both horizontal axis, how would i increase the friction of that cube's surface
Last edited by path; Jul 24, 2019 @ 8:21am
Nadeox1 Jul 24, 2019 @ 10:51pm 
You first need to check how to apply groundmodels on static meshes:
https://wiki.beamng.com/Groundmodel_on_static_objects



Then you can simply use custom groundmodels and apply to the mesh you want.

The custom groundmodel is defined in a json file. That must be placed inside your map's folder, under a folder named 'groundmodels'

http://media.beamng.com/9Nkn7m1HEHj2x916/Capture.PNG

Sample json:

/******************************************************************************* This is an example of how to add per-level custom groundmodels *******************************************************************************/ { "goo" : { "adhesionVelocity" : 1, "staticFrictionCoefficient" : 0.73, "slidingFrictionCoefficient" : 0.58, "hydrodynamicFriction" : 0.1, "stribeckVelocity" : 3.0, "strength" : 1.0, "fluidDensity" : 1200, "flowConsistencyIndex" : 1000, "flowBehaviorIndex" : 1.5, "dragAnisotropy" : 0, "defaultDepth" : 0.002, "collisiontype" : "DIRT", "skidMarks" : false /*"aliases" : ["dirt", "rockydirt", "dirt_loose", "dirt_loose_dusty", "dirt_rocky", "dirt_rocky_large", "dirt_sandy"]*/ }, }
< >
Showing 1-5 of 5 comments
Per page: 1530 50

Date Posted: Jul 23, 2019 @ 8:21am
Posts: 5