SteamWar/BauSystem2.0
Archiviert
12
0

QOL #203

Zusammengeführt
YoyoNow hat 44 Commits von QOL nach master 2023-10-06 14:59:48 +02:00 zusammengeführt
Nur Änderungen aus Commit 06cc2bb35b werden angezeigt - Alle Commits anzeigen

Datei anzeigen

@ -445,22 +445,15 @@ public class Region {
pasteBuilder.pastePoint(minPointBuild.add(prototype.getBuild().getSizeX() / 2, 0, prototype.getBuild().getSizeZ() / 2));
break;
case TESTBLOCK:
Point pastePoint = minPointTestblock.add(prototype.getTestblock().getSizeX() / 2, 0, 0);
if (!pasteBuilder.getClipboardProvider().is(PasteBuilder.SchematicProvider.class)) {
pastePoint = pastePoint.add(0, 0, prototype.getTestblock().getSizeZ() / 2);
} else {
int dz = Math.abs(pasteBuilder.getClipboard().getOrigin().getZ() - pasteBuilder.getClipboard().getMinimumPoint().getZ());
if (dz < 2 || dz > prototype.getTestblock().getSizeZ()) {
pastePoint = pastePoint.add(0, 0, prototype.getTestblock().getSizeZ() / 2);
} else if (pasteBuilder.getClipboard().getDimensions().getZ() != prototype.getTestblock().getSizeZ()) {
pastePoint = pastePoint.add(0, 0, pasteBuilder.getClipboard().getDimensions().getZ() / 2 - (pasteBuilder.getClipboard().getOrigin().getZ() - pasteBuilder.getClipboard().getMinimumPoint().getZ()) - 1);
} else {
pastePoint = pastePoint.add(0, 0, prototype.getTestblock().getSizeZ() / 2);
}
Point pastePoint = minPointTestblock.add(prototype.getTestblock().getSizeX() / 2, 0, prototype.getTestblock().getSizeZ() / 2);
if (pasteBuilder.getClipboardProvider().is(PasteBuilder.SchematicProvider.class)) {
SchematicType schematicType = pasteBuilder.getClipboardProvider().as(PasteBuilder.SchematicProvider.class).getSchematic().getSchemtype();
if (schematicType.getKuerzel().equalsIgnoreCase("wg")) {
pastePoint = pastePoint.add(0, 0, 1);
}
if (schematicType.getKuerzel().equalsIgnoreCase("ws")) {
pastePoint = pastePoint.add(-1, 0, 0);
}
}
pasteBuilder.pastePoint(pastePoint);
break;