Updated to CB 386. Finally fixed the signs issue thanks to Grums help. Turns out the resetzone bug solves itself after a few minutes .. huh.

This commit is contained in:
taoneill 2011-03-03 15:28:38 -05:00
parent a184ff4bf1
commit 091c237406
2 changed files with 2 additions and 5 deletions

View File

@ -13,10 +13,8 @@ public class SignHelper {
if(block.getType() != Material.SIGN_POST) { if(block.getType() != Material.SIGN_POST) {
block.setType(Material.SIGN_POST); block.setType(Material.SIGN_POST);
} }
if(block.getData() != data) {
block.setData(data);
}
BlockState state = block.getState(); BlockState state = block.getState();
state.setData(new org.bukkit.material.Sign(Material.SIGN_POST, data));
if(state instanceof Sign) { if(state instanceof Sign) {
Sign sign = (Sign) state; Sign sign = (Sign) state;
try { try {
@ -28,7 +26,6 @@ public class SignHelper {
sign.update(true); sign.update(true);
} }
} catch (Exception e) { } catch (Exception e) {
// just can't stand this anymore // just can't stand this anymore
} }
} }

View File

@ -170,8 +170,8 @@ public class Volume {
|| oldBlockType == Material.SIGN_POST.getId()) { || oldBlockType == Material.SIGN_POST.getId()) {
// Signs // Signs
currentBlock.setType(Material.getMaterial(oldBlockType)); currentBlock.setType(Material.getMaterial(oldBlockType));
currentBlock.setData(oldBlockData);
BlockState state = currentBlock.getState(); BlockState state = currentBlock.getState();
state.setData(new org.bukkit.material.Sign(oldBlockType, oldBlockData));
if(state instanceof Sign) { if(state instanceof Sign) {
Sign sign = (Sign)state; Sign sign = (Sign)state;
String[] lines = this.getSignLines().get("sign-" + i + "-" + j + "-" + k); String[] lines = this.getSignLines().get("sign-" + i + "-" + j + "-" + k);