ASMR/src/main/kotlin/net/shadowfacts/cacao/geometry/Point.kt

16 lines
284 B
Kotlin

package net.shadowfacts.cacao.geometry
/**
* Helper class for defining 2D points.
*
* @author shadowfacts
*/
data class Point(val x: Double, val y: Double) {
constructor(x: Int, y: Int): this(x.toDouble(), y.toDouble())
companion object {
val ORIGIN = Point(0.0, 0.0)
}
}