Locky overrides

This commit is contained in:
cyberpwn
2021-08-22 03:30:39 -04:00
parent 5bf6687f1f
commit 4a6d58c36e
5 changed files with 64 additions and 34 deletions

View File

@@ -114,9 +114,9 @@ public class PlannedStructure {
int xx = i.getPosition().getX() + sx;
int zz = i.getPosition().getZ() + sz;
int offset = i.getPosition().getY() - startHeight;
int height = (i.getStructure().getStructure().getLockY() != -1
? i.getStructure().getStructure().getLockY()
: placer.getHighest(xx, zz, getData())) + offset + (v.getH() / 2);
int height = (i.getStructure().getStructure().getLockY() == -1 ? i.getStructure().getStructure().getOverrideYRange() != null
? (int)i.getStructure().getStructure().getOverrideYRange().get(rng, xx, zz, getData())
: i.getStructure().getStructure().getLockY() : placer.getHighest(xx, zz, getData())) + offset + (v.getH() / 2);
if (options.getMode().equals(ObjectPlaceMode.PAINT) || options.isVacuum()) {
height = -1;