Reformatted Code
This commit is contained in:
parent
0de74f96ea
commit
9646b4d0a8
24 changed files with 22 additions and 28 deletions
|
@ -158,11 +158,10 @@ public class DataFixerAPI {
|
|||
|
||||
private static void makeBackupAndShowToast(LevelStorageSource storageSource, String levelID) {
|
||||
boolean didOpen = false;
|
||||
try (LevelStorageSource.LevelStorageAccess access = storageSource.createAccess(levelID);){
|
||||
try (LevelStorageSource.LevelStorageAccess access = storageSource.createAccess(levelID);) {
|
||||
didOpen = true;
|
||||
EditWorldScreen.makeBackupAndShowToast(access);
|
||||
}
|
||||
catch (IOException ex) {
|
||||
} catch (IOException ex) {
|
||||
if (!didOpen) {
|
||||
SystemToast.onWorldAccessFailure(Minecraft.getInstance(), levelID);
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ import net.minecraft.resources.ResourceKey;
|
|||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.util.KeyDispatchDataCodec;
|
||||
import net.minecraft.world.level.biome.Biome;
|
||||
import net.minecraft.world.level.biome.Biomes;
|
||||
import net.minecraft.world.level.biome.Climate;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
|
|
|
@ -2,7 +2,6 @@ package org.betterx.bclib.api.v3.datagen;
|
|||
|
||||
import org.betterx.bclib.api.v2.advancement.AdvancementManager;
|
||||
|
||||
import net.minecraft.advancements.Advancement;
|
||||
import net.minecraft.advancements.AdvancementHolder;
|
||||
|
||||
import net.fabricmc.fabric.api.datagen.v1.FabricDataOutput;
|
||||
|
|
|
@ -3,8 +3,6 @@ package org.betterx.bclib.api.v3.datagen;
|
|||
import net.minecraft.data.recipes.RecipeOutput;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
|
||||
import java.util.function.Consumer;
|
||||
|
||||
public interface DatapackRecipeBuilder {
|
||||
ResourceLocation getId();
|
||||
|
||||
|
|
|
@ -9,7 +9,6 @@ import net.fabricmc.fabric.api.datagen.v1.provider.FabricRecipeProvider;
|
|||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.function.Consumer;
|
||||
import org.jetbrains.annotations.ApiStatus;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
|
|
|
@ -48,6 +48,7 @@ public class BehaviourBuilders {
|
|||
.strength(0.2f)
|
||||
.sound(SoundType.VINE);
|
||||
}
|
||||
|
||||
public static BlockBehaviour.Properties createVine(MapColor color) {
|
||||
return createStaticVine(color)
|
||||
.randomTicks();
|
||||
|
@ -100,6 +101,7 @@ public class BehaviourBuilders {
|
|||
public static BlockBehaviour.Properties createLeaves() {
|
||||
return createLeaves(MapColor.PLANT, true);
|
||||
}
|
||||
|
||||
public static BlockBehaviour.Properties createStaticLeaves() {
|
||||
return createStaticLeaves(MapColor.PLANT, true);
|
||||
}
|
||||
|
|
|
@ -6,5 +6,5 @@ package org.betterx.bclib.behaviours.interfaces;
|
|||
* {@link org.betterx.bclib.api.v2.PostInitAPI} will add the {@link net.minecraft.tags.BlockTags#CLIMBABLE} tag to all blocks that
|
||||
* implement this interface.
|
||||
*/
|
||||
public interface BehaviourClimable extends BlockBehaviour{
|
||||
public interface BehaviourClimable extends BlockBehaviour {
|
||||
}
|
||||
|
|
|
@ -7,7 +7,7 @@ package org.betterx.bclib.behaviours.interfaces;
|
|||
* {@link org.betterx.worlds.together.tag.v3.CommonItemTags#COMPOSTABLE} tag to the items of all blocks that
|
||||
* implement this interface. It will also register the Block with the {@link org.betterx.bclib.api.v2.ComposterAPI}
|
||||
*/
|
||||
public interface BehaviourCompostable extends BlockBehaviour{
|
||||
public interface BehaviourCompostable extends BlockBehaviour {
|
||||
|
||||
/**
|
||||
* The chance that this block will be composted.
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package org.betterx.bclib.behaviours.interfaces;
|
||||
|
||||
public interface BehaviourExplosionResistant extends BlockBehaviour{
|
||||
public interface BehaviourExplosionResistant extends BlockBehaviour {
|
||||
}
|
||||
|
|
|
@ -68,7 +68,9 @@ public abstract class BaseStripableLogBlock extends BaseRotatedPillarBlock {
|
|||
public Wood(MapColor color, Block striped, boolean flammable) {
|
||||
super(
|
||||
striped,
|
||||
(flammable ? Properties.ofFullCopy(striped).ignitedByLava() : Properties.ofFullCopy(striped)).mapColor(color)
|
||||
(flammable
|
||||
? Properties.ofFullCopy(striped).ignitedByLava()
|
||||
: Properties.ofFullCopy(striped)).mapColor(color)
|
||||
);
|
||||
this.flammable = flammable;
|
||||
}
|
||||
|
|
|
@ -101,7 +101,7 @@ public final class BCLWoodTypeWrapper {
|
|||
public BCLWoodTypeWrapper build() {
|
||||
if (setType == null) setType = new BlockSetTypeBuilder().register(id);
|
||||
|
||||
final WoodType type = new WoodTypeBuilder().register(id,setType);
|
||||
final WoodType type = new WoodTypeBuilder().register(id, setType);
|
||||
return new BCLWoodTypeWrapper(id, type, color, flammable);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,8 +9,6 @@ import net.minecraft.tags.TagKey;
|
|||
import net.minecraft.world.item.Item;
|
||||
import net.minecraft.world.level.ItemLike;
|
||||
|
||||
import java.util.function.Consumer;
|
||||
|
||||
public class CookingRecipeBuilder extends AbstractUnlockableRecipeBuilder<CookingRecipeBuilder> {
|
||||
|
||||
protected float xp;
|
||||
|
|
|
@ -10,8 +10,6 @@ import net.minecraft.world.item.Item;
|
|||
import net.minecraft.world.item.crafting.Ingredient;
|
||||
import net.minecraft.world.level.ItemLike;
|
||||
|
||||
import java.util.function.Consumer;
|
||||
|
||||
public class SmithingRecipeBuilder extends AbstractUnlockableRecipeBuilder<SmithingRecipeBuilder> {
|
||||
protected Ingredient addon;
|
||||
protected Item template;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue