mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-19 11:59:25 +00:00
- Creative mode tabs are now a registry; the `BuildContents` event was renamed to `BuildCreativeModeTabContentsEvent` and moved it to its own class - The pack format is now 15 for both resource packs and data packs - `ScreenUtils` was deprecated in favor of a `GuiGraphics` extension - Forge and the MDK were updated to Gradle 8 and FG6 - The Forge common config file was removed (it only contained the deprecated old fields for resource caching, which was removed in 1.19.3) - Registry dummy entries were removed - `RemappingVertexPipeline` was fixed to forward the `endVertex()` call - Forge tool tags were removed in favor of vanilla ones Co-authored-by: ChampionAsh5357 <[email protected]> Co-authored-by: coehlrich <[email protected]> Co-authored-by: Dennis C <[email protected]> Co-authored-by: Matyrobbrt <[email protected]>
32 lines
1.1 KiB
Diff
32 lines
1.1 KiB
Diff
--- a/com/mojang/math/Transformation.java
|
|
+++ b/com/mojang/math/Transformation.java
|
|
@@ -14,7 +_,7 @@
|
|
import org.joml.Vector3f;
|
|
import org.joml.Vector3fc;
|
|
|
|
-public final class Transformation {
|
|
+public final class Transformation implements net.minecraftforge.common.extensions.IForgeTransformation {
|
|
private final Matrix4f f_121078_;
|
|
public static final Codec<Transformation> f_268453_ = RecordCodecBuilder.create((p_269604_) -> {
|
|
return p_269604_.group(ExtraCodecs.f_252432_.fieldOf("translation").forGetter((p_269599_) -> {
|
|
@@ -163,6 +_,19 @@
|
|
public int hashCode() {
|
|
return Objects.hash(this.f_121078_);
|
|
}
|
|
+
|
|
+ private Matrix3f normalTransform = null;
|
|
+ public Matrix3f getNormalMatrix() {
|
|
+ checkNormalTransform();
|
|
+ return normalTransform;
|
|
+ }
|
|
+ private void checkNormalTransform() {
|
|
+ if (normalTransform == null) {
|
|
+ normalTransform = new Matrix3f(f_121078_);
|
|
+ normalTransform.invert();
|
|
+ normalTransform.transpose();
|
|
+ }
|
|
+ }
|
|
|
|
public Transformation m_175937_(Transformation p_175938_, float p_175939_) {
|
|
Vector3f vector3f = this.m_252829_();
|