SebLague / Procedural-Landmass-Generation

Procedural Landmass Generation in Unity
https://www.youtube.com/playlist?list=PLFt_AvWsXl0eBW2EiBtl_sxmDtSgZBxB3
MIT License
1.1k stars 596 forks source link

Mesh is black by default #35

Open MrPhantistic opened 3 years ago

MrPhantistic commented 3 years ago

First of all, Sebastian great tutorials! I was experimenting and I found out that the mesh is always black scene or game until i change a value(f.e if octaves = 5 if change to 6 then it fixes). but the problem is i cant just change one of these values while you are playing. Also when you stop playing then it goes back to black until you do the same thing.

Any help is appreciated, Thanks

Gryph2021 commented 3 years ago

So you have to generate the terrain when the game starts for one. And black mesh also mean you probably don't have a directional light in your project. So to fix the issue make it generate on start and put in a light and it should work. Hope this helps! :)

SajawalHassan commented 2 years ago

Probably a little late here, but I also had the same problem and I fixed it by simply calling the DrawMapInEdition function inside of the Start function in the MapGenerator script