Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix block setting while not in fast mode

  • Loading branch information...
commit 1af61f827bb89c48fd2ba9cb4b3c1fc005362206 1 parent be320f6
@wizjany wizjany authored
View
2  src/main/java/com/sk89q/worldedit/EditSession.java
@@ -234,7 +234,7 @@ public boolean rawSetBlock(Vector pt, BaseBlock block) {
result = world.setBlockType(pt, 0);
}
} else {
- result = world.setBlock(pt, block, fastMode);
+ result = world.setBlock(pt, block, !fastMode);
}
return result;
View
12 src/main/java/com/sk89q/worldedit/bukkit/DefaultNmsBlock.java
@@ -259,14 +259,10 @@ public static boolean setSafely(BukkitWorld world, Vector position,
world.copyToWorld(position, (BaseBlock) block);
}
- changed = craftWorld.getHandle().setData(x, y, z, block.getData(), 0);
-
- if (changed) {
- if (notifyAdjacent) {
- craftWorld.getHandle().update(x, y, z, block.getId());
- } else {
- craftWorld.getHandle().notify(x, y, z);
- }
+ changed = craftWorld.getHandle().setData(x, y, z, block.getData(), 0) || changed;
+ if (changed && notifyAdjacent) {
+ craftWorld.getHandle().notify(x, y, z);
+ craftWorld.getHandle().update(x, y, z, block.getId());
}
return changed;
Please sign in to comment.
Something went wrong with that request. Please try again.