lightning bolt WIP, player sprite declaration macro

Former-commit-id: d4999cda37bff2aa27615183aa125bfbc8cfa975
Former-commit-id: 224aee51d4fb7e5fe9d11bf3c0cc758a5604251d
This commit is contained in:
Song Minjae
2016-10-31 13:26:26 +09:00
parent e4886acc92
commit 5e82f87ee5
8 changed files with 92 additions and 108 deletions

View File

@@ -0,0 +1,8 @@
package net.torvald.random
/**
* Created by minjaesong on 16-10-28.
*/
interface NoiseGenerator1D {
fun get(x: Double): Double
}

View File

@@ -0,0 +1,18 @@
package net.torvald.random
/**
* Generate value noise that is always "tileably looped" every x in loopSize.
*
* Created by minjaesong on 16-10-28.
*/
class TileableValueNoise(
val octaves: Int, val persistency: Double,
val loopSize: Double = 1.0, val seed: Long? = null
) : NoiseGenerator1D {
val rng = if (seed != null) HQRNG(seed) else HQRNG()
override fun get(x: Double): Double {
TODO()
}
}