mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 09:47:38 +00:00
Fix a NPE with brush using a global mask and no brush mask
This commit is contained in:
parent
fcd792191a
commit
d82111a4fc
@ -177,6 +177,7 @@ public class BrushTool implements TraceTool {
|
||||
BlockBag bag = session.getBlockBag(player);
|
||||
|
||||
EditSession editSession = session.createEditSession(player);
|
||||
if (mask != null) {
|
||||
Mask existingMask = editSession.getMask();
|
||||
if (existingMask == null) {
|
||||
editSession.setMask(mask);
|
||||
@ -187,6 +188,7 @@ public class BrushTool implements TraceTool {
|
||||
newMask.add(mask);
|
||||
editSession.setMask(newMask);
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
brush.build(editSession, target, material, size);
|
||||
|
Loading…
Reference in New Issue
Block a user