1
mirror of https://github.com/StarWishsama/Slimefun4.git synced 2024-09-20 03:35:51 +00:00

Merge branch 'master' into master

This commit is contained in:
TheBusyBiscuit 2018-08-06 21:13:46 +02:00 committed by GitHub
commit 1c649a4537
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 8 deletions

View File

@ -93,19 +93,25 @@ public class RitualAnimation implements Runnable {
private void abort() {
running = false;
pedestals.forEach((pblock) -> Variables.altarinuse.remove(pblock.getLocation()));
pedestals.forEach((pblock)->{
Variables.altarinuse.remove(pblock.getLocation());
});
Variables.altarinuse.remove(altar.getLocation()); // should re-enable altar blocks on craft failure.
l.getWorld().playSound(l, Sound.ENTITY_ZOMBIE_ATTACK_IRON_DOOR, 5F, 1F);
altars.remove(altar);
}
private void finish() {
if (running) {
l.getWorld().playSound(l, Sound.ENTITY_ZOMBIE_VILLAGER_CURE, 1F, 1F);
l.getWorld().playEffect(l, Effect.STEP_SOUND, Material.EMERALD_BLOCK);
l.getWorld().dropItemNaturally(l.add(0, 1, 0), output);
pedestals.forEach((pblock)-> Variables.altarinuse.remove(pblock.getLocation()));
pedestals.forEach((pblock)->{
Variables.altarinuse.remove(pblock.getLocation());
});
Variables.altarinuse.remove(altar.getLocation()); // should re-enable altar blocks on craft completion.
altars.remove(altar);
}

View File

@ -56,10 +56,8 @@ public class AndroidKillingListener implements Listener {
items.add(new ItemStack(Material.GOLD_NUGGET, 1 + CSCoreLib.randomizer().nextInt(3)));
break;
}
case SKELETON: {
if (((Skeleton) e.getEntity()).getSkeletonType().equals(SkeletonType.WITHER)) {
if (CSCoreLib.randomizer().nextInt(250) < 2) items.add(new MaterialData(Material.SKULL_ITEM, (byte) 1).toItemStack(1));
}
case WITHER_SKELETON: {
if (CSCoreLib.randomizer().nextInt(250) < 2) items.add(new MaterialData(Material.SKULL_ITEM, (byte) 1).toItemStack(1));
break;
}
default: