Search Unity

[WIP] dDrive - little car driving game

Discussion in 'Works In Progress - Archive' started by Deleted User, Jun 7, 2015.

  1. Deleted User

    Deleted User

    Guest

    Hello all.
    I play with Unity for some time and I like it. I decided to document the progress of my own little game. I recorded a short video that shows the current progress. After some failures with default Unity WheelCollider a decided to use Edy’s Vehicle Physics.

     
  2. Deleted User

    Deleted User

    Guest

    Hello again.
    I worked on world editor. So here is my first version of very basic terrain editor.

     
  3. Deleted User

    Deleted User

    Guest

    Hello again.
    I reworked blocky terrain shaping and add some water ;)
     
  4. John-G

    John-G

    Joined:
    Mar 21, 2013
    Posts:
    1,122
    Love the fully functional car system you implemented.
     
  5. Deleted User

    Deleted User

    Guest

    Thank you. I'm going to implement even more functions, but now I need some terrain and roads where to drive : D
     
  6. Deleted User

    Deleted User

    Guest

    Hi again.
    I have reworked terrain editing again. I'm going to make new progress video, but not until I solve one problem. I have trouble with terrain material. I use Unity terrain component. I create terrain component programmatically.

    Code (CSharp):
    1. private void Start()
    2.         {
    3.             m_Terrain = gameObject.AddComponent<UnityEngine.Terrain>();
    4.  
    5.             m_TerrainData = new TerrainData();
    6.            
    7.             m_TerrainData.heightmapResolution = SectorSize;
    8.             m_TerrainData.size = new Vector3(SectorSize, SectorHeight, SectorSize);
    9.             m_TerrainData.SetHeights(0, 0, m_Heights);
    10.            
    11.             m_TerrainData.alphamapResolution = SectorSize;
    12.             m_Alphamaps = new float[SectorSize, SectorSize, SplatTextures.Length];
    13.            
    14.             m_TerrainData.splatPrototypes = SplatTextures;
    15.             m_TerrainData.SetAlphamaps(0, 0, m_Alphamaps);
    16.             m_TerrainTextureChanged = false;
    17.            
    18.             m_TerrainData.SetDetailResolution(DetailResolution, DetailResolutionPatch);
    19.            
    20.             m_Terrain.terrainData = m_TerrainData;
    21.            
    22.  
    23.              UnityEngine.TerrainCollider myCollider = gameObject.AddComponent<UnityEngine.TerrainCollider>();
    24.             myCollider.terrainData = m_TerrainData;
    25.              
    26.             gameObject.transform.position = new Vector3(X * TerrainSector.SectorSize, 0, Z * TerrainSector.SectorSize);
    27.  
    28.             gameObject.tag = "TerrainSector";
    29.             gameObject.layer = 9;
    30.  
    31.             UpdateNeighbors();
    32.         }
    Everything works fine in editor. But after building project and running exe file, my terrain looks glossy. See difference on these pictures. First one is from editor and second from build application.
    TerrainProblem1.png TerrainProblem2.png
    Terrain is matte in editor and glossy in build. I also added shaders in "Project Settings -> Graphics".
    TerrainProblem3.png
    I'd really appreciate your help.
     
  7. xboxxxxd

    xboxxxxd

    Joined:
    Jul 18, 2015
    Posts:
    14
    I am not the best at Unity3D yet..
    But if there's any way of lightning Or so include'd in that scene, then it Would be the the UV that messe's it up, if not.. Try to Change settings if using: Bloom/Blur, it wil suprice you if you change it loads of times, you wil notice some weird/good things could happen to it, Further.. Great Job with the Car Engine etc do!..

    EDIT:
    Add for each Shader a Level Settings, it make life easyer :p.
    EDIT1:
    I did change the settings of blur and/or Bloom alot of times, i came out as results once with A Blur level settings of: 0,12 of max: 100, Blur was like it had no color when Running project ?!. So ye.

    Gr.xboxxxxd.
     
  8. Deleted User

    Deleted User

    Guest

    OK, here is my latest progress video. Progress in two things. In the world editor and also vehicle gameplay...
    Hope you will like it ;)

     
  9. Deleted User

    Deleted User

    Guest

    Hello again. New video here. The most noticable new features are 3D grass and trees... Hope you will like it ;)

     
  10. woodsynzl

    woodsynzl

    Joined:
    Apr 8, 2015
    Posts:
    156
    Looks really good! Just wondering how you made the console script?
     
  11. Deleted User

    Deleted User

    Guest

  12. woodsynzl

    woodsynzl

    Joined:
    Apr 8, 2015
    Posts:
    156
    Thanks for the source! I'm really curious how you got the moving parts in the car itself. Looks like something I'll have to keep my eye on.
     
  13. Deleted User

    Deleted User

    Guest

    I created car model by myself. So I also created animations for different parts like steering wheel, windows, doors, speedometer and so on. All moving parts (except wheels) are animations.
     
  14. woodsynzl

    woodsynzl

    Joined:
    Apr 8, 2015
    Posts:
    156
    Is there a way I could get my hands on a demo? I really do like this game
     
  15. Deleted User

    Deleted User

    Guest

    I'm sorry but game isn't ready for this....
     
    GarBenjamin likes this.
  16. woodsynzl

    woodsynzl

    Joined:
    Apr 8, 2015
    Posts:
    156
    Okay I know this may be a little intrusive, but may I ask how you link the value from the rpm to the animation of the speedo?
     
  17. Deleted User

    Deleted User

    Guest

    I just set animation time something like this:
    Code (CSharp):
    1. public void SetAnimationTime(string _AnimName, string _Layer, float _Time)
    2.         {
    3.             m_Animator.Play(_AnimName, m_Animator.GetLayerIndex(_Layer), _Time);
    4.         }
     
    woodsynzl likes this.
  18. woodsynzl

    woodsynzl

    Joined:
    Apr 8, 2015
    Posts:
    156
    Is this still going? I'd like to see it!
     
  19. Deleted User

    Deleted User

    Guest

    Yes. I work on road system. I seek the best way to do it (trying different approaches). In addiction, I'm pretty busy at my job, so the dev speed has slowed... :(