mirror of
https://github.com/EngineHub/WorldEdit.git
synced 2024-12-21 04:49:51 +08:00
Fixed UnderOverlayMask not really supporting Extent.
This commit is contained in:
parent
e657fd5be9
commit
9ab1d0f150
@ -19,16 +19,19 @@
|
|||||||
|
|
||||||
package com.sk89q.worldedit.masks;
|
package com.sk89q.worldedit.masks;
|
||||||
|
|
||||||
import java.util.Set;
|
import com.sk89q.worldedit.EditSession;
|
||||||
|
import com.sk89q.worldedit.LocalPlayer;
|
||||||
import com.sk89q.worldedit.*;
|
import com.sk89q.worldedit.LocalSession;
|
||||||
|
import com.sk89q.worldedit.Vector;
|
||||||
import com.sk89q.worldedit.blocks.BaseBlock;
|
import com.sk89q.worldedit.blocks.BaseBlock;
|
||||||
|
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author 1337
|
* @author 1337
|
||||||
*/
|
*/
|
||||||
public class UnderOverlayMask extends ExtentAwareMask {
|
public class UnderOverlayMask extends AbstractMask {
|
||||||
private final int yMod;
|
private final int yMod;
|
||||||
private Mask mask;
|
private Mask mask;
|
||||||
|
|
||||||
@ -65,7 +68,6 @@ public void prepare(LocalSession session, LocalPlayer player, Vector target) {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean matches(EditSession editSession, Vector pos) {
|
public boolean matches(EditSession editSession, Vector pos) {
|
||||||
Extent extent = getExtent(editSession);
|
return !mask.matches(editSession, pos) && mask.matches(editSession, pos.add(0, yMod, 0));
|
||||||
return !mask.matches(extent, pos) && mask.matches(extent, pos.add(0, yMod, 0));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user