mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-06 02:30:34 +01:00
commit
d8d41eb39b
@ -179,7 +179,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getId(bs);
|
int idx = bsids.getId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -330,7 +330,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -338,7 +338,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
@ -179,7 +179,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getId(bs);
|
int idx = bsids.getId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -330,7 +330,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -338,7 +338,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
@ -177,7 +177,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getId(bs);
|
int idx = bsids.getId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -328,7 +328,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -336,7 +336,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
@ -177,7 +177,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getRawId(bs);
|
int idx = bsids.getRawId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -314,7 +314,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -322,7 +322,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
@ -177,7 +177,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getRawId(bs);
|
int idx = bsids.getRawId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -314,7 +314,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -322,7 +322,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
@ -178,7 +178,7 @@ public class DynmapPlugin {
|
|||||||
int idx = bsids.getRawId(bs);
|
int idx = bsids.getRawId(bs);
|
||||||
if (idx >= stateByID.length) {
|
if (idx >= stateByID.length) {
|
||||||
int plen = stateByID.length;
|
int plen = stateByID.length;
|
||||||
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
stateByID = Arrays.copyOf(stateByID, idx*11/10); // grow array by 10%
|
||||||
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
Arrays.fill(stateByID, plen, stateByID.length, DynmapBlockState.AIR);
|
||||||
}
|
}
|
||||||
Block b = bs.getBlock();
|
Block b = bs.getBlock();
|
||||||
@ -315,7 +315,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPerm(PlayerEntity psender, String permission) {
|
boolean hasPerm(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermission(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.has(psender, permission);
|
return permissions.has(psender, permission);
|
||||||
@ -323,7 +323,7 @@ public class DynmapPlugin {
|
|||||||
|
|
||||||
boolean hasPermNode(PlayerEntity psender, String permission) {
|
boolean hasPermNode(PlayerEntity psender, String permission) {
|
||||||
PermissionsHandler ph = PermissionsHandler.getHandler();
|
PermissionsHandler ph = PermissionsHandler.getHandler();
|
||||||
if ((psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
if ((ph != null) && (psender != null) && ph.hasPermissionNode(psender.getName().getString(), permission)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return permissions.hasPermissionNode(psender, permission);
|
return permissions.hasPermissionNode(psender, permission);
|
||||||
|
Loading…
Reference in New Issue
Block a user