Bump up to 1.19.1
This commit is contained in:
@@ -19,6 +19,7 @@ import net.minecraft.client.renderer.texture.TextureAtlasSprite;
|
|||||||
import net.minecraft.network.chat.Component;
|
import net.minecraft.network.chat.Component;
|
||||||
import net.minecraft.resources.ResourceLocation;
|
import net.minecraft.resources.ResourceLocation;
|
||||||
import net.minecraft.util.FastColor;
|
import net.minecraft.util.FastColor;
|
||||||
|
import net.minecraftforge.client.extensions.common.IClientFluidTypeExtensions;
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
import net.minecraftforge.fluids.capability.templates.FluidTank;
|
import net.minecraftforge.fluids.capability.templates.FluidTank;
|
||||||
|
|
||||||
@@ -52,14 +53,15 @@ public class FluidStackWidget extends AbstractWidget {
|
|||||||
FluidTank fluidTank = getFluid.get();
|
FluidTank fluidTank = getFluid.get();
|
||||||
if (!fluidTank.isEmpty()) {
|
if (!fluidTank.isEmpty()) {
|
||||||
FluidStack fluidStack = fluidTank.getFluid();
|
FluidStack fluidStack = fluidTank.getFluid();
|
||||||
ResourceLocation still = fluidStack.getFluid().getAttributes().getStillTexture(fluidStack);
|
IClientFluidTypeExtensions props = IClientFluidTypeExtensions.of(fluidStack.getFluid());
|
||||||
|
ResourceLocation still = props.getStillTexture(fluidStack);
|
||||||
if (still != null) {
|
if (still != null) {
|
||||||
AbstractTexture texture = minecraft.getTextureManager().getTexture(TextureAtlas.LOCATION_BLOCKS);
|
AbstractTexture texture = minecraft.getTextureManager().getTexture(TextureAtlas.LOCATION_BLOCKS);
|
||||||
if (texture instanceof TextureAtlas atlas) {
|
if (texture instanceof TextureAtlas atlas) {
|
||||||
TextureAtlasSprite sprite = atlas.getSprite(still);
|
TextureAtlasSprite sprite = atlas.getSprite(still);
|
||||||
RenderSystem.setShaderTexture(0, TextureAtlas.LOCATION_BLOCKS);
|
RenderSystem.setShaderTexture(0, TextureAtlas.LOCATION_BLOCKS);
|
||||||
|
|
||||||
int color = fluidStack.getFluid().getAttributes().getColor();
|
int color = props.getTintColor();
|
||||||
RenderSystem.setShaderColor(
|
RenderSystem.setShaderColor(
|
||||||
FastColor.ARGB32.red(color) / 255.0F,
|
FastColor.ARGB32.red(color) / 255.0F,
|
||||||
FastColor.ARGB32.green(color) / 255.0F,
|
FastColor.ARGB32.green(color) / 255.0F,
|
||||||
|
@@ -1,22 +1,22 @@
|
|||||||
# Project
|
# Project
|
||||||
version_major=1
|
version_major=1
|
||||||
version_minor=0
|
version_minor=0
|
||||||
version_patch=8d
|
version_patch=9d
|
||||||
group=me.hypherionmc.craterlib
|
group=me.hypherionmc.craterlib
|
||||||
|
|
||||||
# Common
|
# Common
|
||||||
minecraft_version=1.19
|
minecraft_version=1.19.1
|
||||||
common_runs_enabled=false
|
common_runs_enabled=false
|
||||||
common_client_run_name=Common Client
|
common_client_run_name=Common Client
|
||||||
common_server_run_name=Common Server
|
common_server_run_name=Common Server
|
||||||
|
|
||||||
# Forge
|
# Forge
|
||||||
forge_version=41.0.16
|
forge_version=42.0.1
|
||||||
forge_ats_enabled=true
|
forge_ats_enabled=true
|
||||||
|
|
||||||
# Fabric
|
# Fabric
|
||||||
fabric_version=0.55.3+1.19
|
fabric_version=0.58.5+1.19.1
|
||||||
fabric_loader_version=0.14.7
|
fabric_loader_version=0.14.8
|
||||||
|
|
||||||
# Mod options
|
# Mod options
|
||||||
mod_name=CraterLib
|
mod_name=CraterLib
|
||||||
|
Reference in New Issue
Block a user