mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2024-11-07 03:00:29 +01:00
Piston heads, donkeys/mules, biomes in 1.9 fixes
This commit is contained in:
parent
f1ad953644
commit
a73ed51bb1
@ -46,7 +46,7 @@ public class BiomeManager {
|
||||
|
||||
for (Player all : skyblock.getIslandManager().getPlayersAtIsland(island, IslandWorld.Normal)) {
|
||||
try {
|
||||
if (NMSUtil.getVersionNumber() < 10) {
|
||||
if (NMSUtil.getVersionNumber() < 9) {
|
||||
NMSUtil.sendPacket(all,
|
||||
packetPlayOutMapChunkClass.getConstructor(chunkClass, boolean.class, int.class)
|
||||
.newInstance(all.getLocation().getChunk().getClass().getMethod("getHandle")
|
||||
|
@ -30,7 +30,7 @@ public class BankCommand extends SubCommand {
|
||||
Config config = fileManager.getConfig(new File(skyblock.getDataFolder(), "language.yml"));
|
||||
FileConfiguration configLoad = config.getFileConfiguration();
|
||||
|
||||
if (fileManager.getConfig(new File(skyblock.getDataFolder(), "config.yml")).getFileConfiguration().getBoolean("Island.Bank.Disabled")) {
|
||||
if (!fileManager.getConfig(new File(skyblock.getDataFolder(), "config.yml")).getFileConfiguration().getBoolean("Island.Bank.Enable")) {
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Bank.Disabled.Message"));
|
||||
soundManager.playSound(player, Sounds.ANVIL_LAND.bukkitSound(), 1.0F, 1.0F);
|
||||
return;
|
||||
|
@ -351,6 +351,13 @@ public class Block implements Listener {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Check piston head
|
||||
if (configLoad.getBoolean("Island.Spawn.Protection")) {
|
||||
if (LocationUtil.isLocationAffectingLocation(event.getBlock().getRelative(event.getDirection()).getLocation(), island.getLocation(world, IslandEnvironment.Main))) {
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
@ -556,6 +556,11 @@ public class Entity implements Listener {
|
||||
livingEntity instanceof Horse) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (NMSUtil.getVersionNumber() > 8) {
|
||||
if (livingEntity instanceof Donkey || livingEntity instanceof Mule)
|
||||
return;
|
||||
}
|
||||
|
||||
if (livingEntity.hasMetadata("SkyBlock")) {
|
||||
return;
|
||||
@ -574,8 +579,7 @@ public class Entity implements Listener {
|
||||
List<ItemStack> entityDrops = event.getDrops();
|
||||
|
||||
if (entityDrops != null) {
|
||||
for (int i = 0; i < entityDrops.size(); i++) {
|
||||
ItemStack is = entityDrops.get(i);
|
||||
for (ItemStack is : entityDrops) {
|
||||
is.setAmount(is.getAmount() * 2);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user