mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-09 21:31:51 +09:00
phys debugging; see L818@ActorWithBody.kt
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
package org.dyn4j.geometry
|
||||
|
||||
import org.dyn4j.Epsilon
|
||||
import kotlin.math.sign
|
||||
|
||||
/**
|
||||
* This class represents a vector or point in 2D space.
|
||||
@@ -699,6 +700,9 @@ class Vector2 {
|
||||
return a
|
||||
}
|
||||
|
||||
val signum: Vector2
|
||||
get() = Vector2(this.x.sign, this.y.sign)
|
||||
|
||||
companion object {
|
||||
/** A vector representing the x-axis; this vector should not be changed at runtime; used internally */
|
||||
internal val X_AXIS = Vector2(1.0, 0.0)
|
||||
|
||||
Reference in New Issue
Block a user