Update FaWe #7

Zusammengeführt
Lixfel hat 467 Commits von update nach main 2024-11-28 22:27:32 +01:00 zusammengeführt
Nur Änderungen aus Commit aae9249014 werden angezeigt - Alle Commits anzeigen

Datei anzeigen

@ -257,7 +257,8 @@ public class ExtentEntityCopy implements EntityFunction {
//FAWE start
if (hasRotation) {
ListTag orgrot = state.getNbtData().getListTag("Rotation");
Vector3 orgDirection = new Location(source, 0, 0, 0, orgrot.getFloat(0), orgrot.getFloat(1)).getDirection();
// source extent may be null: use non-nullable destination instead since this is just a conversion into a vector.
Vector3 orgDirection = new Location(destination, 0, 0, 0, orgrot.getFloat(0), orgrot.getFloat(1)).getDirection();
Vector3 newDirection = transform.apply(orgDirection).subtract(transform.apply(Vector3.ZERO)).normalize();
builder.put(
"Rotation",
@ -276,7 +277,8 @@ public class ExtentEntityCopy implements EntityFunction {
CompoundTagBuilder builder = tag.createBuilder();
ListTag orgrot = state.getNbtData().getListTag("Rotation");
Vector3 orgDirection = new Location(source, 0, 0, 0, orgrot.getFloat(0), orgrot.getFloat(1)).getDirection();
// source extent may be null: use non-nullable destination instead since this is just a conversion into a vector.
Vector3 orgDirection = new Location(destination, 0, 0, 0, orgrot.getFloat(0), orgrot.getFloat(1)).getDirection();
Vector3 newDirection = transform.apply(orgDirection).subtract(transform.apply(Vector3.ZERO)).normalize();
builder.put(
"Rotation",