mirror of
https://gitlab.com/gaelysam/mapgen_rivers.git
synced 2025-02-20 14:00:32 +01:00
Fix parameters for Simplex noise, to make sure the last octave has not a greater scale than 1
Also use a 401x401 grid instead of 400, so that there are 400 intervals
This commit is contained in:
parent
9700e948b9
commit
49bc397718
@ -15,15 +15,15 @@ argc = len(sys.argv)
|
||||
if argc > 1:
|
||||
mapsize = int(sys.argv[1])
|
||||
else:
|
||||
mapsize = 400
|
||||
mapsize = 401
|
||||
|
||||
scale = mapsize / 2
|
||||
scale = (mapsize-1) / 2
|
||||
n = np.zeros((mapsize, mapsize))
|
||||
|
||||
#micronoise_depth = 0.05
|
||||
|
||||
params = {
|
||||
"octaves" : int(np.log2(mapsize)),
|
||||
"octaves" : int(np.ceil(np.log2(mapsize-1)))+1,
|
||||
"persistence" : 0.5,
|
||||
"lacunarity" : 2.,
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user