1. Trouble with the game?
    Try the troubleshooter!

    Dismiss Notice
  2. Issues with the game?
    Check the Known Issues list before reporting!

    Dismiss Notice
  3. Before reporting issues or bugs, please check the up-to-date Bug Reporting Thread for the current version.
    0.37 Bug Reporting thread
    Solutions and more information may already be available.

Making different terrain types in the editor

Discussion in 'Troubleshooting: Bugs, Questions and Support' started by danodude, Sep 5, 2013.

  1. danodude

    danodude
    Expand Collapse

    Joined:
    Sep 3, 2013
    Messages:
    27
    Hey guys!

    I'm just in the middle of building my first map in Drive, and I'm needing to put some mud in it... how do I get different terrain types, like when you sink into mud and sand a bit?

    I tried searching for it but haven't found any solution. This guy here in post #11 had the same question but didn't post the answer so I'm stuck. I'm really new to this so yeah... I guess this is a nooby question :D

    Thanks :)
     
  2. Miura

    Miura
    Expand Collapse

    Joined:
    Aug 5, 2012
    Messages:
    311
    This thread had some discussion on how to make the groundmodels and depth map work. See lua/groundmodel.lua to see which names you can use for the ground layers to get the right behavior.
     
  3. danodude

    danodude
    Expand Collapse

    Joined:
    Sep 3, 2013
    Messages:
    27
    Ohh... I think I get it.

    So, in the file it says

    Code:
    --------------------------------------------------------------------------------- mud
    g = groundModel()
    g.adhesionVelocity            = 3
    g.staticFrictionCoefficient   = 0.39
    g.slidingFrictionCoefficient  = 0.28
    g.hydrodynamicFriction        = 0.1
    g.stribeckVelocity            = 6
    g.strength                    = 1.0
    
    
    g.fluidDensity = 100
    g.flowConsistencyIndex = 460
    g.flowBehaviorIndex = 0.5
    g.dragAnisotropy = 0
    
    
    g.collisiontype               = particles.getMaterialIDByName(materials, "MUD") 
    g.skidMarks                   = false
    BeamEngine:setGroundModel(g, "Mud") -- ###
    
    
    -- public interface
    
    
    -- currently empty
    
    
    return M
    so where the ### is I have to name the texture the same name as that?

    Also when I place the default mud texture on my map my car does not sink into it at all.
     
  4. Miura

    Miura
    Expand Collapse

    Joined:
    Aug 5, 2012
    Messages:
    311
    If you name a layer in the terrain painter "Mud", it should give the correct particles and friction. To make the tires sink into the mud, you'll need a depth map. See the other thread for more info on that. Just make sure the file name and format are right. Have a look at other terrains for example.
     
  5. danodude

    danodude
    Expand Collapse

    Joined:
    Sep 3, 2013
    Messages:
    27
    Thanks! I'm not on my PC at the moment so I'll try next time I'm on and see if I can do it.

    If I don't stuff any files up or ruin anything, I should have the map done by next week :)

    - - - Updated - - -

    Ok, I'm trying to make the depthmap right now, but I need a little bit of help :)

    I've exported the terrain hightmap to a folder and now have different layers of the map. Do I need to change all of them, or just the Mud layer?

    If its just the Mud layer, do I just open it into Gimp and paint it all white, and make the mud holes a little darker? I've never made a depthmap before so its all new to me :p


    Don't worry about responding, I just took a deep breath and tried it... IT WORKED!

    Thanks for the answers, now my map is really rolling along :)
     
    #5 danodude, Sep 6, 2013
    Last edited: Sep 6, 2013
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice