Package net.minecraft.util.math
Class Vec3f
java.lang.Object
net.minecraft.util.math.Vec3f
public final class Vec3f extends Object
A mutable vector composed of 3 floats.
- Mappings:
Namespace Name official g
intermediary net/minecraft/class_1160
named net/minecraft/util/math/Vec3f
-
Field Summary
Fields Modifier and Type Field Description static com.mojang.serialization.Codec<Vec3f>
CODEC
static Vec3f
NEGATIVE_X
static Vec3f
NEGATIVE_Y
static Vec3f
NEGATIVE_Z
static Vec3f
POSITIVE_X
static Vec3f
POSITIVE_Y
static Vec3f
POSITIVE_Z
private float
x
private float
y
private float
z
-
Constructor Summary
-
Method Summary
Modifier and Type Method Description void
add(float x, float y, float z)
void
add(Vec3f vector)
void
clamp(float min, float max)
Vec3f
copy()
void
cross(Vec3f vector)
float
dot(Vec3f other)
boolean
equals(Object o)
Quaternion
getDegreesQuaternion(float angle)
Quaternion
getRadialQuaternion(float angle)
float
getX()
float
getY()
float
getZ()
int
hashCode()
void
lerp(Vec3f vector, float delta)
void
modify(Float2FloatFunction function)
void
multiplyComponentwise(float x, float y, float z)
boolean
normalize()
void
rotate(Quaternion rotation)
void
scale(float scale)
void
set(float x, float y, float z)
void
subtract(Vec3f other)
String
toString()
void
transform(Matrix3f matrix3f)
-
Field Details
-
CODEC
- Mappings:
Namespace Name Mixin selector official a
Lg;a:Lcom/mojang/serialization/Codec;
intermediary field_28477
Lnet/minecraft/class_1160;field_28477:Lcom/mojang/serialization/Codec;
named CODEC
Lnet/minecraft/util/math/Vec3f;CODEC:Lcom/mojang/serialization/Codec;
-
NEGATIVE_X
- Mappings:
Namespace Name Mixin selector official b
Lg;b:Lg;
intermediary field_20702
Lnet/minecraft/class_1160;field_20702:Lnet/minecraft/class_1160;
named NEGATIVE_X
Lnet/minecraft/util/math/Vec3f;NEGATIVE_X:Lnet/minecraft/util/math/Vec3f;
-
POSITIVE_X
- Mappings:
Namespace Name Mixin selector official c
Lg;c:Lg;
intermediary field_20703
Lnet/minecraft/class_1160;field_20703:Lnet/minecraft/class_1160;
named POSITIVE_X
Lnet/minecraft/util/math/Vec3f;POSITIVE_X:Lnet/minecraft/util/math/Vec3f;
-
NEGATIVE_Y
- Mappings:
Namespace Name Mixin selector official d
Lg;d:Lg;
intermediary field_20704
Lnet/minecraft/class_1160;field_20704:Lnet/minecraft/class_1160;
named NEGATIVE_Y
Lnet/minecraft/util/math/Vec3f;NEGATIVE_Y:Lnet/minecraft/util/math/Vec3f;
-
POSITIVE_Y
- Mappings:
Namespace Name Mixin selector official e
Lg;e:Lg;
intermediary field_20705
Lnet/minecraft/class_1160;field_20705:Lnet/minecraft/class_1160;
named POSITIVE_Y
Lnet/minecraft/util/math/Vec3f;POSITIVE_Y:Lnet/minecraft/util/math/Vec3f;
-
NEGATIVE_Z
- Mappings:
Namespace Name Mixin selector official f
Lg;f:Lg;
intermediary field_20706
Lnet/minecraft/class_1160;field_20706:Lnet/minecraft/class_1160;
named NEGATIVE_Z
Lnet/minecraft/util/math/Vec3f;NEGATIVE_Z:Lnet/minecraft/util/math/Vec3f;
-
POSITIVE_Z
- Mappings:
Namespace Name Mixin selector official g
Lg;g:Lg;
intermediary field_20707
Lnet/minecraft/class_1160;field_20707:Lnet/minecraft/class_1160;
named POSITIVE_Z
Lnet/minecraft/util/math/Vec3f;POSITIVE_Z:Lnet/minecraft/util/math/Vec3f;
-
x
private float x- Mappings:
Namespace Name Mixin selector official h
Lg;h:F
intermediary field_21483
Lnet/minecraft/class_1160;field_21483:F
named x
Lnet/minecraft/util/math/Vec3f;x:F
-
y
private float y- Mappings:
Namespace Name Mixin selector official i
Lg;i:F
intermediary field_21484
Lnet/minecraft/class_1160;field_21484:F
named y
Lnet/minecraft/util/math/Vec3f;y:F
-
z
private float z- Mappings:
Namespace Name Mixin selector official j
Lg;j:F
intermediary field_21485
Lnet/minecraft/class_1160;field_21485:F
named z
Lnet/minecraft/util/math/Vec3f;z:F
-
-
Constructor Details
-
Vec3f
public Vec3f() -
Vec3f
public Vec3f(float x, float y, float z)- Mappings:
Namespace Name Mixin selector official <init>
Lg;<init>(FFF)V
intermediary <init>
Lnet/minecraft/class_1160;<init>(FFF)V
named <init>
Lnet/minecraft/util/math/Vec3f;<init>(FFF)V
-
Vec3f
- Mappings:
Namespace Name Mixin selector official <init>
Lg;<init>(Ldiu;)V
intermediary <init>
Lnet/minecraft/class_1160;<init>(Lnet/minecraft/class_243;)V
named <init>
Lnet/minecraft/util/math/Vec3f;<init>(Lnet/minecraft/util/math/Vec3d;)V
-
-
Method Details
-
equals
-
hashCode
public int hashCode() -
getX
public float getX()- Mappings:
Namespace Name Mixin selector official a
Lg;a()F
intermediary method_4943
Lnet/minecraft/class_1160;method_4943()F
named getX
Lnet/minecraft/util/math/Vec3f;getX()F
-
getY
public float getY()- Mappings:
Namespace Name Mixin selector official b
Lg;b()F
intermediary method_4945
Lnet/minecraft/class_1160;method_4945()F
named getY
Lnet/minecraft/util/math/Vec3f;getY()F
-
getZ
public float getZ()- Mappings:
Namespace Name Mixin selector official c
Lg;c()F
intermediary method_4947
Lnet/minecraft/class_1160;method_4947()F
named getZ
Lnet/minecraft/util/math/Vec3f;getZ()F
-
scale
- Mappings:
Namespace Name Mixin selector official b
Lg;b(F)V
intermediary method_4942
Lnet/minecraft/class_1160;method_4942(F)V
named scale
Lnet/minecraft/util/math/Vec3f;scale(F)V
-
multiplyComponentwise
- Mappings:
Namespace Name Mixin selector official b
Lg;b(FFF)V
intermediary method_23849
Lnet/minecraft/class_1160;method_23849(FFF)V
named multiplyComponentwise
Lnet/minecraft/util/math/Vec3f;multiplyComponentwise(FFF)V
-
clamp
- Mappings:
Namespace Name Mixin selector official a
Lg;a(FF)V
intermediary method_4946
Lnet/minecraft/class_1160;method_4946(FF)V
named clamp
Lnet/minecraft/util/math/Vec3f;clamp(FF)V
-
set
public void set(float x, float y, float z)- Mappings:
Namespace Name Mixin selector official a
Lg;a(FFF)V
intermediary method_4949
Lnet/minecraft/class_1160;method_4949(FFF)V
named set
Lnet/minecraft/util/math/Vec3f;set(FFF)V
-
add
- Mappings:
Namespace Name Mixin selector official c
Lg;c(FFF)V
intermediary method_4948
Lnet/minecraft/class_1160;method_4948(FFF)V
named add
Lnet/minecraft/util/math/Vec3f;add(FFF)V
-
add
- Mappings:
Namespace Name Mixin selector official b
Lg;b(Lg;)V
intermediary method_23846
Lnet/minecraft/class_1160;method_23846(Lnet/minecraft/class_1160;)V
named add
Lnet/minecraft/util/math/Vec3f;add(Lnet/minecraft/util/math/Vec3f;)V
-
subtract
- Mappings:
Namespace Name Mixin selector official c
Lg;c(Lg;)V
intermediary method_4944
Lnet/minecraft/class_1160;method_4944(Lnet/minecraft/class_1160;)V
named subtract
Lnet/minecraft/util/math/Vec3f;subtract(Lnet/minecraft/util/math/Vec3f;)V
-
dot
- Mappings:
Namespace Name Mixin selector official d
Lg;d(Lg;)F
intermediary method_4950
Lnet/minecraft/class_1160;method_4950(Lnet/minecraft/class_1160;)F
named dot
Lnet/minecraft/util/math/Vec3f;dot(Lnet/minecraft/util/math/Vec3f;)F
-
normalize
- Mappings:
Namespace Name Mixin selector official d
Lg;d()Z
intermediary method_4952
Lnet/minecraft/class_1160;method_4952()Z
named normalize
Lnet/minecraft/util/math/Vec3f;normalize()Z
-
cross
- Mappings:
Namespace Name Mixin selector official e
Lg;e(Lg;)V
intermediary method_4951
Lnet/minecraft/class_1160;method_4951(Lnet/minecraft/class_1160;)V
named cross
Lnet/minecraft/util/math/Vec3f;cross(Lnet/minecraft/util/math/Vec3f;)V
-
transform
- Mappings:
Namespace Name Mixin selector official a
Lg;a(La;)V
intermediary method_23215
Lnet/minecraft/class_1160;method_23215(Lnet/minecraft/class_4581;)V
named transform
Lnet/minecraft/util/math/Vec3f;transform(Lnet/minecraft/util/math/Matrix3f;)V
-
rotate
- Mappings:
Namespace Name Mixin selector official a
Lg;a(Ld;)V
intermediary method_19262
Lnet/minecraft/class_1160;method_19262(Lnet/minecraft/class_1158;)V
named rotate
Lnet/minecraft/util/math/Vec3f;rotate(Lnet/minecraft/util/math/Quaternion;)V
-
lerp
- Mappings:
Namespace Name Mixin selector official a
Lg;a(Lg;F)V
intermediary method_23847
Lnet/minecraft/class_1160;method_23847(Lnet/minecraft/class_1160;F)V
named lerp
Lnet/minecraft/util/math/Vec3f;lerp(Lnet/minecraft/util/math/Vec3f;F)V
-
getRadialQuaternion
- Mappings:
Namespace Name Mixin selector official c
Lg;c(F)Ld;
intermediary method_23626
Lnet/minecraft/class_1160;method_23626(F)Lnet/minecraft/class_1158;
named getRadialQuaternion
Lnet/minecraft/util/math/Vec3f;getRadialQuaternion(F)Lnet/minecraft/util/math/Quaternion;
-
getDegreesQuaternion
- Mappings:
Namespace Name Mixin selector official a
Lg;a(F)Ld;
intermediary method_23214
Lnet/minecraft/class_1160;method_23214(F)Lnet/minecraft/class_1158;
named getDegreesQuaternion
Lnet/minecraft/util/math/Vec3f;getDegreesQuaternion(F)Lnet/minecraft/util/math/Quaternion;
-
copy
- Mappings:
Namespace Name Mixin selector official e
Lg;e()Lg;
intermediary method_23850
Lnet/minecraft/class_1160;method_23850()Lnet/minecraft/class_1160;
named copy
Lnet/minecraft/util/math/Vec3f;copy()Lnet/minecraft/util/math/Vec3f;
-
modify
- Mappings:
Namespace Name Mixin selector official a
Lg;a(Lit/unimi/dsi/fastutil/floats/Float2FloatFunction;)V
intermediary method_23848
Lnet/minecraft/class_1160;method_23848(Lit/unimi/dsi/fastutil/floats/Float2FloatFunction;)V
named modify
Lnet/minecraft/util/math/Vec3f;modify(Lit/unimi/dsi/fastutil/floats/Float2FloatFunction;)V
-
toString
-