Perlin.lua 236 B

123456789101112
  1. class "Perlin"
  2. function Perlin:Perlin(octaves, freq, amp, seed)
  3. if self.__ptr == nil then
  4. self.__ptr = Polycore.Perlin(octaves, freq, amp, seed)
  5. end
  6. end
  7. function Perlin:Get(x, y)
  8. return Polycore.Perlin_Get(self.__ptr, x, y)
  9. end