I wanna make a map for my game which has a z axis also. I used terrain tools’ toolbox but it generates once and if I change (in other words if a modder wants to change) the map’s heightmap or other png files about map properties it wont update itself.
You can check out the MakeHeightmap1
script in my MakeGeo project for ideas.
MakeGeo is presently hosted at these locations:
https://bitbucket.org/kurtdekker/makegeo
The above example makes a mesh.
You can also manipulate heights on Terrains… that functionality is built into terrains directly. Here are two examples of it in use:
I used both two of your codes at the path u said but it says my image isnt readdable, how to make it readdable via script so you dont have to use unity for make it readdable?
I think you just view it with a RenderTexture to make a readable Texture2D at runtime.
I seem to remember this example worked… give it a test:
https://answers.unity.com/questions/988174/create-modify-texture2d-to-readwrite-enabled-at-ru.html
this one has also code for heightmap to terrain generation (and splat mapping etc)
As I said before, I want to make it via script.
Don’t tell strangers on a forum about your error! GO FIX IT NOW!
The complete error message contains everything you need to know to fix the error yourself.
The important parts of the error message are:
- the description of the error itself (google this; you are NEVER the first one!)
- the file it occurred in (critical!)
- the line number and character position (the two numbers in parentheses)
- also possibly useful is the stack trace (all the lines of text in the lower console window)
Always start with the FIRST error in the console window, as sometimes that error causes or compounds some or all of the subsequent errors. Often the error will be immediately prior to the indicated line, so make sure to check there as well.
All of that information is in the actual error message and you must pay attention to it. Learn how to identify it instantly so you don’t have to stop your progress and fiddle around with the forum.
Remember: NOBODY here memorizes error codes. That’s not a thing. The error code is absolutely the least useful part of the error. It serves no purpose at all. Forget the error code. Put it out of your mind.