1.15.2 - mainly mapping updates. Will be backwards compatible with 1.15.1 and 1.15
This commit is contained in:
parent
a543a562b2
commit
1202a1c588
7 changed files with 23 additions and 12 deletions
|
@ -61,12 +61,12 @@ license {
|
||||||
group = 'TechReborn'
|
group = 'TechReborn'
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
minecraft "com.mojang:minecraft:1.15.1"
|
minecraft "com.mojang:minecraft:1.15.2-pre1"
|
||||||
mappings "net.fabricmc:yarn:1.15.1+build.24:v2"
|
mappings "net.fabricmc:yarn:1.15.2-pre1+build.1:v2"
|
||||||
modImplementation "net.fabricmc:fabric-loader:0.7.3+build.176"
|
modImplementation "net.fabricmc:fabric-loader:0.7.4+build.177"
|
||||||
|
|
||||||
//Fabric api
|
//Fabric api
|
||||||
modImplementation "net.fabricmc.fabric-api:fabric-api:0.4.27+build.286-1.15"
|
modImplementation "net.fabricmc.fabric-api:fabric-api:0.4.28+build.288-1.15"
|
||||||
|
|
||||||
optionalDependency ("me.shedaniel:RoughlyEnoughItems:3.2.31")
|
optionalDependency ("me.shedaniel:RoughlyEnoughItems:3.2.31")
|
||||||
optionalDependency ('io.github.cottonmc:LibCD:2.0.1+1.15')
|
optionalDependency ('io.github.cottonmc:LibCD:2.0.1+1.15')
|
||||||
|
|
|
@ -73,7 +73,7 @@ public class DataDrivenBEProvider extends BlockEntityType<DataDrivenBEProvider.D
|
||||||
}
|
}
|
||||||
Identifier id = new Identifier(JsonHelper.getString(jsonObject, "name"));
|
Identifier id = new Identifier(JsonHelper.getString(jsonObject, "name"));
|
||||||
DataDrivenBEProvider provider = new DataDrivenBEProvider(block, jsonObject);
|
DataDrivenBEProvider provider = new DataDrivenBEProvider(block, jsonObject);
|
||||||
Registry.register(Registry.BLOCK_ENTITY, id, provider);
|
Registry.register(Registry.BLOCK_ENTITY_TYPE, id, provider);
|
||||||
return provider;
|
return provider;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -134,4 +134,9 @@ public abstract class BaseDynamicFluidBakedModel implements BakedModel, FabricBa
|
||||||
return ModelItemPropertyOverrideList.EMPTY;
|
return ModelItemPropertyOverrideList.EMPTY;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean method_24304() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -161,7 +161,7 @@ public class TRBlockEntities {
|
||||||
|
|
||||||
public static <T extends BlockEntity> BlockEntityType<T> register(String id, BlockEntityType.Builder<T> builder) {
|
public static <T extends BlockEntity> BlockEntityType<T> register(String id, BlockEntityType.Builder<T> builder) {
|
||||||
BlockEntityType<T> blockEntityType = builder.build(null);
|
BlockEntityType<T> blockEntityType = builder.build(null);
|
||||||
Registry.register(Registry.BLOCK_ENTITY, new Identifier(id), blockEntityType);
|
Registry.register(Registry.BLOCK_ENTITY_TYPE, new Identifier(id), blockEntityType);
|
||||||
TRBlockEntities.TYPES.add(blockEntityType);
|
TRBlockEntities.TYPES.add(blockEntityType);
|
||||||
return blockEntityType;
|
return blockEntityType;
|
||||||
}
|
}
|
||||||
|
|
|
@ -117,7 +117,7 @@ public class FrequencyTransmitterItem extends Item {
|
||||||
tooltip.add(new LiteralText(Formatting.GRAY + "X: " + Formatting.GOLD + x));
|
tooltip.add(new LiteralText(Formatting.GRAY + "X: " + Formatting.GOLD + x));
|
||||||
tooltip.add(new LiteralText(Formatting.GRAY + "Y: " + Formatting.GOLD + y));
|
tooltip.add(new LiteralText(Formatting.GRAY + "Y: " + Formatting.GOLD + y));
|
||||||
tooltip.add(new LiteralText(Formatting.GRAY + "Z: " + Formatting.GOLD + z));
|
tooltip.add(new LiteralText(Formatting.GRAY + "Z: " + Formatting.GOLD + z));
|
||||||
tooltip.add(new LiteralText(Formatting.DARK_GRAY + getDimName(Registry.DIMENSION.get(dim)).toString()));
|
tooltip.add(new LiteralText(Formatting.DARK_GRAY + getDimName(Registry.DIMENSION_TYPE.get(dim)).toString()));
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
tooltip.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.message.noCoordsSet")));
|
tooltip.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.message.noCoordsSet")));
|
||||||
|
@ -125,7 +125,7 @@ public class FrequencyTransmitterItem extends Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Identifier getDimName(DimensionType type){
|
private static Identifier getDimName(DimensionType type){
|
||||||
return Registry.DIMENSION.getId(type);
|
return Registry.DIMENSION_TYPE.getId(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class StackInfoFreqTransmitter extends StackInfoElement {
|
public static class StackInfoFreqTransmitter extends StackInfoElement {
|
||||||
|
@ -144,7 +144,7 @@ public class FrequencyTransmitterItem extends Item {
|
||||||
int coordY = stack.getTag().getInt("y");
|
int coordY = stack.getTag().getInt("y");
|
||||||
int coordZ = stack.getTag().getInt("z");
|
int coordZ = stack.getTag().getInt("z");
|
||||||
int coordDim = stack.getTag().getInt("dim");
|
int coordDim = stack.getTag().getInt("dim");
|
||||||
text = grey + "X: " + gold + coordX + grey + " Y: " + gold + coordY + grey + " Z: " + gold + coordZ + grey + " Dim: " + gold + getDimName(Registry.DIMENSION.get(coordDim)).toString() + " (" + coordDim + ")";
|
text = grey + "X: " + gold + coordX + grey + " Y: " + gold + coordY + grey + " Z: " + gold + coordZ + grey + " Dim: " + gold + getDimName(Registry.DIMENSION_TYPE.get(coordDim)).toString() + " (" + coordDim + ")";
|
||||||
} else {
|
} else {
|
||||||
text = grey + StringUtils.t("techreborn.message.noCoordsSet");
|
text = grey + StringUtils.t("techreborn.message.noCoordsSet");
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,10 +32,16 @@ import java.util.Random;
|
||||||
|
|
||||||
public class RubberSaplingGenerator extends SaplingGenerator {
|
public class RubberSaplingGenerator extends SaplingGenerator {
|
||||||
|
|
||||||
|
//TODO remove with 1.16, backwards compat for 1.15/1.15.1
|
||||||
@Nullable
|
@Nullable
|
||||||
@Override
|
|
||||||
protected ConfiguredFeature<BranchedTreeFeatureConfig, ?> createTreeFeature(Random random) {
|
protected ConfiguredFeature<BranchedTreeFeatureConfig, ?> createTreeFeature(Random random) {
|
||||||
return WorldGenerator.RUBBER_TREE.configure(WorldGenerator.RUBBER_TREE_CONFIG);
|
return createTreeFeature(random, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//1.15.2 method
|
||||||
|
@Nullable
|
||||||
|
@Override
|
||||||
|
protected ConfiguredFeature<BranchedTreeFeatureConfig, ?> createTreeFeature(Random random, boolean bl) {
|
||||||
|
return WorldGenerator.RUBBER_TREE.configure(WorldGenerator.RUBBER_TREE_CONFIG);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,7 +75,7 @@ public class WorldGenerator {
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void setupTrees() {
|
private static void setupTrees() {
|
||||||
RUBBER_TREE = Registry.register(Registry.FEATURE, new Identifier("techreborn:rubber_tree"), new RubberTreeFeature(BranchedTreeFeatureConfig::deserialize2));
|
RUBBER_TREE = Registry.register(Registry.FEATURE, new Identifier("techreborn:rubber_tree"), new RubberTreeFeature(BranchedTreeFeatureConfig::deserialize));
|
||||||
|
|
||||||
WeightedStateProvider logProvider = new WeightedStateProvider();
|
WeightedStateProvider logProvider = new WeightedStateProvider();
|
||||||
logProvider.addState(TRContent.RUBBER_LOG.getDefaultState(), 10);
|
logProvider.addState(TRContent.RUBBER_LOG.getDefaultState(), 10);
|
||||||
|
|
Loading…
Add table
Reference in a new issue