Add new types rocks, add test gradient mapgen
This commit is contained in:
@@ -16,6 +16,8 @@ local MapGen = mapGenRequire('MapGen')
|
||||
|
||||
-- Rocks
|
||||
sylite = 'rocks:sylite',
|
||||
syliteGray = 'rocks:sylite_gray',
|
||||
syliteBlack = 'rocks:sylite_black',
|
||||
tauitite = 'rocks:tauitite',
|
||||
iyellite = 'rocks:iyellite',
|
||||
falmyte = 'rocks:falmyte',
|
||||
@@ -219,8 +221,8 @@ local function generateRock(biome, mapGenerator, data, index, x, y, z)
|
||||
rocksNoise = core.get_value_noise(rocksNoiseParams)
|
||||
end
|
||||
|
||||
local noiseRocksValue = mathRound(rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
if noiseRocksValue == 1 then
|
||||
local noiseRocksValue = (rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
--[[if noiseRocksValue == 1 then
|
||||
data[index] = ids.malachite
|
||||
elseif noiseRocksValue == 2 then
|
||||
data[index] = ids.hapcoryte
|
||||
@@ -236,6 +238,13 @@ local function generateRock(biome, mapGenerator, data, index, x, y, z)
|
||||
data[index] = ids.burcite
|
||||
elseif noiseRocksValue == 8 then
|
||||
data[index] = ids.felhor
|
||||
end--]]
|
||||
if noiseRocksValue > 5 then
|
||||
data[index] = ids.syliteBlack
|
||||
elseif noiseRocksValue > 4.5 then
|
||||
data[index] = ids.syliteGray
|
||||
else
|
||||
data[index] = ids.sylite
|
||||
end
|
||||
end
|
||||
|
||||
@@ -246,9 +255,13 @@ local function generateSoil(biome, mapGenerator, data, index, x, y, z)
|
||||
rocksNoise = core.get_value_noise(rocksNoiseParams)
|
||||
end
|
||||
|
||||
local noiseRocksValue = mathRound(rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
local noiseRocksValue = (rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
|
||||
if noiseRocksValue > 4 then
|
||||
if noiseRocksValue > 5 then
|
||||
data[index] = ids.syliteBlack
|
||||
elseif noiseRocksValue > 4.5 then
|
||||
data[index] = ids.syliteGray
|
||||
elseif noiseRocksValue > 4 then
|
||||
data[index] = ids.sylite
|
||||
else
|
||||
data[index] = biome.groundNodesIDs.soil
|
||||
@@ -262,9 +275,13 @@ local function generateTurf(biome, mapGenerator, data, index, x, y, z)
|
||||
rocksNoise = core.get_value_noise(rocksNoiseParams)
|
||||
end
|
||||
|
||||
local noiseRocksValue = mathRound(rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
local noiseRocksValue = (rocksNoise:get_3d({x = x, y = y, z = z}))
|
||||
|
||||
if noiseRocksValue > 4 then
|
||||
if noiseRocksValue > 5 then
|
||||
data[index] = ids.syliteBlack
|
||||
elseif noiseRocksValue > 4.5 then
|
||||
data[index] = ids.syliteGray
|
||||
elseif noiseRocksValue > 4 then
|
||||
data[index] = ids.sylite
|
||||
else
|
||||
data[index] = biome.groundNodesIDs.turf
|
||||
|
||||
Reference in New Issue
Block a user