public interface KMath
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final double
     
    static final double
     
    static final double
     
    static final double
     
  • Method Summary

    Static Methods
    Modifier and Type
    Method
    Description
    static double
    approach(double current, double target, double speed)
     
    static double
    approachDegrees(double current, double target, double speed)
     
    static net.minecraft.core.BlockPos
    block(double x, double y, double z)
     
    static long
    ceil(double value)
     
    static double
    clamp(double value, double min, double max)
     
    static double
    clampedLerp(double value, double min, double max)
     
    static double
    deg(double value)
     
    static double
    degreesDifference(double current, double target)
     
    static long
    floor(double value)
     
    static boolean
    isPowerOfTwo(int value)
     
    static double
    lerp(double value, double min, double max)
     
    static org.joml.Matrix3f
    m3f()
     
    static org.joml.Matrix4f
    m4f()
     
    static double
    map(double value, double min0, double max0, double min1, double max1)
     
    static org.joml.Quaternionf
    quaternion(float x, float y, float z, float w)
     
    static double
    rad(double value)
     
    static double
    rotateIfNecessary(double current, double target, double max)
     
    static net.minecraft.world.phys.Vec3
    v3(double x, double y, double z)
     
    static org.joml.Vector3d
    v3d(double x, double y, double z)
     
    static org.joml.Vector3f
    v3f(float x, float y, float z)
     
    static org.joml.Vector4f
    v4f(float x, float y, float z, float w)
     
    static double
    wrapDegrees(double d)
     
  • Field Details

  • Method Details

    • block

      static net.minecraft.core.BlockPos block(double x, double y, double z)
    • v3

      static net.minecraft.world.phys.Vec3 v3(double x, double y, double z)
    • v3d

      static org.joml.Vector3d v3d(double x, double y, double z)
    • v3f

      static org.joml.Vector3f v3f(float x, float y, float z)
    • v4f

      static org.joml.Vector4f v4f(float x, float y, float z, float w)
    • m3f

      static org.joml.Matrix3f m3f()
    • m4f

      static org.joml.Matrix4f m4f()
    • quaternion

      static org.joml.Quaternionf quaternion(float x, float y, float z, float w)
    • rad

      static double rad(double value)
    • deg

      static double deg(double value)
    • floor

      static long floor(double value)
    • ceil

      static long ceil(double value)
    • clamp

      static double clamp(double value, double min, double max)
    • lerp

      static double lerp(double value, double min, double max)
    • map

      static double map(double value, double min0, double max0, double min1, double max1)
    • clampedLerp

      static double clampedLerp(double value, double min, double max)
    • wrapDegrees

      static double wrapDegrees(double d)
    • degreesDifference

      static double degreesDifference(double current, double target)
    • rotateIfNecessary

      static double rotateIfNecessary(double current, double target, double max)
    • approach

      static double approach(double current, double target, double speed)
    • approachDegrees

      static double approachDegrees(double current, double target, double speed)
    • isPowerOfTwo

      static boolean isPowerOfTwo(int value)