mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-22 17:27:38 +00:00
Added a workaround for hey0's getComplexBlock() returning a null when it should not.
This commit is contained in:
parent
ed2859c1de
commit
263417550b
@ -81,6 +81,9 @@ public class SMServerInterface implements ServerInterface {
|
||||
public void setSignText(Vector pt, String[] text) {
|
||||
Sign signData = (Sign)etc.getServer().getComplexBlock(
|
||||
pt.getBlockX(), pt.getBlockY(), pt.getBlockZ());
|
||||
if (signData == null) {
|
||||
return;
|
||||
}
|
||||
for (byte i = 0; i < 4; i++) {
|
||||
signData.setText(i, text[i]);
|
||||
}
|
||||
@ -96,6 +99,9 @@ public class SMServerInterface implements ServerInterface {
|
||||
public String[] getSignText(Vector pt) {
|
||||
Sign signData = (Sign)etc.getServer().getComplexBlock(
|
||||
pt.getBlockX(), pt.getBlockY(), pt.getBlockZ());
|
||||
if (signData == null) {
|
||||
return new String[]{"", "", "", ""};
|
||||
}
|
||||
String[] text = new String[4];
|
||||
for (byte i = 0; i < 4; i++) {
|
||||
text[i] = signData.getText(i);
|
||||
|
Loading…
Reference in New Issue
Block a user