Fixed twittermites and magic beams appearing invisible with sodium

This commit is contained in:
Sollace 2022-10-09 00:23:28 +02:00
parent 276e2f2b2a
commit 986c4a5f85
3 changed files with 7 additions and 6 deletions

View file

@ -87,7 +87,7 @@ public class HydrophobicSpell extends AbstractSpell {
} }
}); });
if (source.getMaster().age % 200 == 0) { if (source.getEntity().age % 200 == 0) {
source.playSound(SoundEvents.BLOCK_BEACON_AMBIENT, 0.5F); source.playSound(SoundEvents.BLOCK_BEACON_AMBIENT, 0.5F);
} }
} }

View file

@ -23,11 +23,13 @@ public final class RenderLayers extends RenderLayer {
.build(false)); .build(false));
private static final Function<Integer, RenderLayer> MAGIC_COLORIN_FUNC = Util.memoize(color -> { private static final Function<Integer, RenderLayer> MAGIC_COLORIN_FUNC = Util.memoize(color -> {
return of("magic_colored_" + color, VertexFormats.POSITION_COLOR_TEXTURE_OVERLAY_LIGHT_NORMAL, return of("magic_colored_" + color,
VertexFormat.DrawMode.QUADS, 256, true, true, MultiPhaseParameters.builder() VertexFormats.POSITION_COLOR_TEXTURE_OVERLAY_LIGHT_NORMAL,
VertexFormat.DrawMode.QUADS, 256, true, true,
MultiPhaseParameters.builder()
.shader(COLOR_SHADER) .shader(COLOR_SHADER)
.transparency(TRANSLUCENT_TRANSPARENCY) .transparency(TRANSLUCENT_TRANSPARENCY)
.target(TRANSLUCENT_TARGET) // .target(TRANSLUCENT_TARGET)
.texturing(solid(Color.r(color), Color.g(color), Color.b(color), 0.6F)) .texturing(solid(Color.r(color), Color.g(color), Color.b(color), 0.6F))
.build(false)); .build(false));
}); });

View file

@ -3,8 +3,7 @@ package com.minelittlepony.unicopia.client.render.entity;
import com.minelittlepony.unicopia.client.particle.SphereModel; import com.minelittlepony.unicopia.client.particle.SphereModel;
import com.minelittlepony.unicopia.client.render.RenderLayers; import com.minelittlepony.unicopia.client.render.RenderLayers;
import com.minelittlepony.unicopia.entity.FairyEntity; import com.minelittlepony.unicopia.entity.FairyEntity;
import net.minecraft.client.render.*;
import net.minecraft.client.render.VertexConsumer;
import net.minecraft.client.render.entity.EntityRendererFactory; import net.minecraft.client.render.entity.EntityRendererFactory;
import net.minecraft.client.render.entity.MobEntityRenderer; import net.minecraft.client.render.entity.MobEntityRenderer;
import net.minecraft.client.render.entity.model.EntityModel; import net.minecraft.client.render.entity.model.EntityModel;