Hi i am new on strackoverflow, could anyone help me with 2d Terrain trigonometry algorithm, how to achieve something like in screenshot?
this tutorial helps me a lot but still can't figure out how to create mountain terrain
My attempt evolved to this:
Vector (v0.x + t * length, center + amplitude * Mathf.Cos (angle * t));
thanks in advance
it looks like chain so:
generate n
random height points
just the peaks covering your screen or map or whatever.
compute chain between neighbors
the chain length should be bigger then the distance between points. For the math see:
the equation image was taken from the Wiki page linked.