Improve code formatting

This commit is contained in:
md_5 2020-07-01 14:17:48 +10:00
parent 008f039f37
commit 3b9cf0f803
No known key found for this signature in database
GPG key ID: E8E901AC7C617C11
5 changed files with 5 additions and 4 deletions

View file

@ -22,7 +22,7 @@
if (!iblockdata1.a(iblockdata.getBlock())) { if (!iblockdata1.a(iblockdata.getBlock())) {
- if (world.getDimensionKey() != World.OVERWORLD && world.getDimensionKey() != World.THE_NETHER || !BlockPortal.a((GeneratorAccess) world, blockposition)) { - if (world.getDimensionKey() != World.OVERWORLD && world.getDimensionKey() != World.THE_NETHER || !BlockPortal.a((GeneratorAccess) world, blockposition)) {
+ // CraftBukkit - getTypeKey() + // CraftBukkit - getTypeKey()
+ if (world.getTypeKey()!= DimensionManager.OVERWORLD && world.getTypeKey()!= DimensionManager.THE_NETHER || !BlockPortal.a((GeneratorAccess) world, blockposition)) { + if (world.getTypeKey() != DimensionManager.OVERWORLD && world.getTypeKey() != DimensionManager.THE_NETHER || !BlockPortal.a((GeneratorAccess) world, blockposition)) {
if (!iblockdata.canPlace(world, blockposition)) { if (!iblockdata.canPlace(world, blockposition)) {
- world.a(blockposition, false); - world.a(blockposition, false);
+ fireExtinguished(world, blockposition); // CraftBukkit - fuel block broke + fireExtinguished(world, blockposition); // CraftBukkit - fuel block broke

View file

@ -56,7 +56,7 @@
entityzombie.u(entityzombie.world.getDamageScaler(entityzombie.getChunkCoordinates()).d()); entityzombie.u(entityzombie.world.getDamageScaler(entityzombie.getChunkCoordinates()).d());
entityzombie.u(entityzombie.eL() && this.eV()); entityzombie.u(entityzombie.eL() && this.eV());
} }
+ else { ((Zombie) getBukkitEntity()).setConversionTime(-1); } // SPIGOT-5208: End conversion to stop event spam + else { ((Zombie) getBukkitEntity()).setConversionTime(-1); } // CraftBukkit - SPIGOT-5208: End conversion to stop event spam
} }

View file

@ -1,5 +1,6 @@
package com.mojang.brigadier.tree; package com.mojang.brigadier.tree;
// CHECKSTYLE:OFF
import com.google.common.collect.ComparisonChain; import com.google.common.collect.ComparisonChain;
import com.google.common.collect.Maps; import com.google.common.collect.Maps;
import com.google.common.collect.Sets; import com.google.common.collect.Sets;

View file

@ -1530,7 +1530,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
break; break;
} }
} }
AttributeModifiable dummy = new AttributeModifiable(GenericAttributes.MAX_HEALTH, (attribute) -> {}); AttributeModifiable dummy = new AttributeModifiable(GenericAttributes.MAX_HEALTH, (attribute) -> { });
dummy.setValue(scaledHealth ? healthScale : getMaxHealth()); dummy.setValue(scaledHealth ? healthScale : getMaxHealth());
collection.add(dummy); collection.add(dummy);
} }

View file

@ -24,6 +24,6 @@ public class CraftSmithingRecipe extends SmithingRecipe implements CraftRecipe {
public void addToCraftingManager() { public void addToCraftingManager() {
ItemStack result = this.getResult(); ItemStack result = this.getResult();
MinecraftServer.getServer().getCraftingManager().addRecipe(new net.minecraft.server.RecipeSmithing(CraftNamespacedKey.toMinecraft(this.getKey()), toNMS(this.getBase(), true), toNMS(this.getAddition(), true), CraftItemStack.asNMSCopy(result))); MinecraftServer.getServer().getCraftingManager().addRecipe(new net.minecraft.server.RecipeSmithing(CraftNamespacedKey.toMinecraft(this.getKey()), toNMS(this.getBase(), true), toNMS(this.getAddition(), true), CraftItemStack.asNMSCopy(result)));
} }
} }