local X,Y,Z = 15,15,15
local posg = {}
local Smooth = 10
for x = 1,X do
posg[x] = {}
for y = 1,Y do
posg[x][y] = {}
for z = 1,Z do
posg[x][y][z] = {}
local part = Instance.new("SpawnLocation")
part.Anchored = true
part.Parent = workspace
part.Position = Vector3.new(x*5, y*5, z*5)
part.Size = Vector3.new(5, 5, 5)
part.Transparency = 1 - math.noise(
(X/Smooth) + x/Smooth * 3,
(Y/Smooth) + x/Smooth * 3,
(Z/Smooth) + x/Smooth * 3
)
end
end
end
i am trying to make a perlin noise system and have only used 2d arrays up to this point and am unable to figure out how to go about doing my math
My end goal: