LuaJake
|
  |
| Joined: 20 Jun 2013 |
| Total Posts: 2009 |
|
|
| 05 Mar 2015 04:14 AM |
I made this from scratch, it's not based off Perlin or anything like that.
I call it Septanian noise.
-- Septanian noise by LuaJake
local block = Instance.new('Part') block.FormFactor = Enum.FormFactor.Symmetric block.Size = Vector3.new(4,4,4) block.Anchored = true block.BrickColor = BrickColor.Green()
local lowest = -25 local highest = 25 local lowmap = -1 local highmap = 1
local range = highest - lowest local noise = {} local currentblock = 1
function setBlock(a,b,c) local p = block:Clone() p.Parent = workspace p.CFrame = CFrame.new(p.Size.X*a,p.Size.Y*b,p.Size.Z*c) p.Size = Vector3.new(4,4*(highmap - lowmap),4) end
for x = lowest,highest do wait() for z = lowest,highest do local xvalue = nil local zvalue = nil if x == lowest then xvalue = 0 else xvalue = noise[currentblock-range-1]+math.random(lowmap,highmap) end if z == lowest then zvalue = 0 else zvalue = noise[currentblock-1]+math.random(lowmap,highmap) end local y = (xvalue + zvalue)/2 table.insert(noise,y) currentblock = currentblock + 1 setBlock(x,y,z) end end |
|
|
| Report Abuse |
|
LuaJake
|
  |
| Joined: 20 Jun 2013 |
| Total Posts: 2009 |
|
|
| 05 Mar 2015 04:16 AM |
| I'll eventually add some smoothing operators to make it better ;) |
|
|
| Report Abuse |
|
|
| 05 Mar 2015 07:55 AM |
| how is it noise,I doesn't see anything about :play() |
|
|
| Report Abuse |
|
| |
| |
LuaJake
|
  |
| Joined: 20 Jun 2013 |
| Total Posts: 2009 |
|
|
| 05 Mar 2015 11:01 PM |
| It's nowhere as good as Perlin, but hey, at least I tried :] |
|
|
| Report Abuse |
|