[Feature] Build for 1.19.4
This commit is contained in:
parent
8a8e73348c
commit
55930d73d5
55 changed files with 380 additions and 304 deletions
|
@ -37,6 +37,18 @@ public class AnvilScreenMixin extends ItemCombinerScreen<AnvilMenu> {
|
|||
super(handler, playerInventory, title, texture);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void renderErrorIcon(PoseStack poseStack, int i, int j) {
|
||||
if (this.hasRecipeError()) {
|
||||
blit(poseStack, i + 65, j + 46, this.imageWidth, 0, 28, 21);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean hasRecipeError() {
|
||||
//TODO: 1.19.4 check error conditions
|
||||
return false;
|
||||
}
|
||||
|
||||
@Inject(method = "subInit", at = @At("TAIL"))
|
||||
protected void be_subInit(CallbackInfo info) {
|
||||
int x = (width - imageWidth) / 2;
|
||||
|
|
|
@ -2,17 +2,17 @@ package org.betterx.bclib.mixin.client;
|
|||
|
||||
import org.betterx.bclib.api.v2.dataexchange.DataExchangeAPI;
|
||||
|
||||
import net.minecraft.client.Game;
|
||||
import net.minecraft.client.multiplayer.ClientPacketListener;
|
||||
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.injection.At;
|
||||
import org.spongepowered.asm.mixin.injection.Inject;
|
||||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
|
||||
@Mixin(Game.class)
|
||||
public class GameMixin {
|
||||
@Mixin(ClientPacketListener.class)
|
||||
public class ClientPacketListenerMixin {
|
||||
|
||||
@Inject(method = "onStartGameSession", at = @At("TAIL"))
|
||||
@Inject(method = "handleLogin", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/telemetry/WorldSessionTelemetryManager;onPlayerInfoReceived(Lnet/minecraft/world/level/GameType;Z)V"))
|
||||
public void bclib_onStart(CallbackInfo ci) {
|
||||
DataExchangeAPI.sendOnEnter();
|
||||
}
|
|
@ -5,6 +5,7 @@ import org.betterx.bclib.blocks.LeveledAnvilBlock;
|
|||
import org.betterx.bclib.interfaces.AnvilScreenHandlerExtended;
|
||||
import org.betterx.bclib.recipes.AnvilRecipe;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.core.BlockPos;
|
||||
import net.minecraft.tags.BlockTags;
|
||||
import net.minecraft.world.entity.player.Inventory;
|
||||
|
@ -164,7 +165,7 @@ public abstract class AnvilMenuMixin extends ItemCombinerMenu implements AnvilSc
|
|||
|
||||
private void be_updateResult() {
|
||||
if (be_currentRecipe == null) return;
|
||||
resultSlots.setItem(0, be_currentRecipe.assemble(inputSlots));
|
||||
resultSlots.setItem(0, be_currentRecipe.assemble(inputSlots, Minecraft.getInstance().level.registryAccess()));
|
||||
broadcastChanges();
|
||||
}
|
||||
|
||||
|
|
|
@ -8,11 +8,7 @@ import net.minecraft.world.level.biome.BiomeSource;
|
|||
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.Shadow;
|
||||
import org.spongepowered.asm.mixin.injection.At;
|
||||
import org.spongepowered.asm.mixin.injection.Inject;
|
||||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
@Mixin(BiomeSource.class)
|
||||
|
@ -26,14 +22,4 @@ public abstract class BiomeSourceMixin implements BiomeSourceAccessor {
|
|||
BCLib.LOGGER.info("Rebuilding features in BiomeSource " + this);
|
||||
//featuresPerStep = Suppliers.memoize(() -> FeatureSorter.buildFeaturesPerStep(this.possibleBiomes().stream().toList(), true));
|
||||
}
|
||||
|
||||
@Inject(method = "<init>(Ljava/util/List;)V", at = @At("TAIL"))
|
||||
public void bcl_init(List list, CallbackInfo ci) {
|
||||
// System.out.println("new BiomeSource (" + Integer.toHexString(hashCode()) + ", biomes=" + possibleBiomes().size() + ")");
|
||||
// if (possibleBiomes().size() == 27) {
|
||||
// System.out.println("Nether????");
|
||||
// } else if (possibleBiomes().size() == 2) {
|
||||
// System.out.println("Datapack Nether???");
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,6 +5,7 @@ import org.betterx.worlds.together.world.BiomeSourceWithNoiseRelatedSettings;
|
|||
import org.betterx.worlds.together.world.BiomeSourceWithSeed;
|
||||
|
||||
import net.minecraft.core.Holder;
|
||||
import net.minecraft.core.RegistryAccess;
|
||||
import net.minecraft.resources.ResourceKey;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.server.level.ServerLevel;
|
||||
|
@ -34,6 +35,7 @@ public abstract class ServerLevelMixin extends Level {
|
|||
protected ServerLevelMixin(
|
||||
WritableLevelData writableLevelData,
|
||||
ResourceKey<Level> resourceKey,
|
||||
RegistryAccess registryAccess,
|
||||
Holder<DimensionType> holder,
|
||||
Supplier<ProfilerFiller> supplier,
|
||||
boolean bl,
|
||||
|
@ -41,7 +43,7 @@ public abstract class ServerLevelMixin extends Level {
|
|||
long l,
|
||||
int i
|
||||
) {
|
||||
super(writableLevelData, resourceKey, holder, supplier, bl, bl2, l, i);
|
||||
super(writableLevelData, resourceKey, registryAccess, holder, supplier, bl, bl2, l, i);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue