Add a slider for handheld light reflection strength, fix boat having water in it in some older mc versions

This commit is contained in:
Merlin1809
2026-04-23 23:32:59 +02:00
parent 8dfb9b5b64
commit db53385aaf
7 changed files with 36 additions and 26 deletions
+10 -7
View File
@@ -634,12 +634,15 @@ void main() {
#endif
#if (defined BLOCKENTITIES || defined ENTITIES || defined HAND) && !defined TRANSLUCENT_ENTITIES && defined TRANSLUCENT_ENTITIES_DITHER_FALLBACK
float entityAlbedo = clamp((Albedo.a*Color.a - 0.1) * 10.0 / 9.0, 0.0, 1.0);
#ifdef TAA
if(entityAlbedo < BN) discard;
#else
if(entityAlbedo < R2) discard;
#endif
if(data_in.blockID != 1612) {
float entityAlbedo = clamp((Albedo.a*Color.a - 0.1) * 10.0 / 9.0, 0.0, 1.0);
#ifdef TAA
if(entityAlbedo < BN) discard;
#else
if(entityAlbedo < R2) discard;
#endif
}
#endif
float torchlightmap = lmcoord.x;
@@ -676,7 +679,7 @@ void main() {
float endPortalEmission = 0.0;
if(PORTAL) {
#if MC_VERSION < 260100 && defined SHADER_END_PORTAL
#if MC_VERSION < 260100 && defined SHADER_END_PORTAL
const float steps = 20.0;
vec3 color = vec3(0.0);
+7 -7
View File
@@ -548,7 +548,7 @@ void main() {
FINAL_COLOR += flashLightReflection;
#endif
#if defined Hand_Held_lights && defined IS_LPV_ENABLED
#if defined Hand_Held_lights && defined IS_LPV_ENABLED && HANDHELD_LIGHT_REFLECTIONS > 0
if(!hand && firstPersonCamera && !isShaderGrass) {
if (heldItemId > 0){
vec3 shiftedViewPos = viewPos + vec3(-0.25, 0.2, 0.0);
@@ -558,8 +558,8 @@ void main() {
vec3 handLightCol = GetHandLight(heldItemId, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
@@ -571,8 +571,8 @@ void main() {
vec3 handLightCol = GetHandLight(heldItemId2, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
@@ -585,8 +585,8 @@ void main() {
vec3 handLightCol = GetHandLight(IEXT_beltborne_lanterns_Id, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
FINAL_COLOR += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
#endif
+3 -1
View File
@@ -1,6 +1,6 @@
option.SHADER_VERSION_LABEL = §d§lECLIPSE§r - A Bliss Edit
prefix.SHADER_VERSION_LABEL = V
value.SHADER_VERSION_LABEL.482 = 8.2.1
value.SHADER_VERSION_LABEL.482 = 8.2.2
iris_extension.keybind.key0.name=Flashlight
@@ -258,6 +258,8 @@ screen.Direct_Light = Direct Light
option.LPV_HANDHELD_SHADOWS_QUALITY = Handheld Shadows Quality
value.LPV_HANDHELD_SHADOWS_QUALITY.0 = Low
value.LPV_HANDHELD_SHADOWS_QUALITY.1 = High
option.HANDHELD_LIGHT_REFLECTIONS = Handheld Lights in Reflections
suffix.HANDHELD_LIGHT_REFLECTIONS=%
screen.Ambient_light = Ambient Light
+1 -1
View File
@@ -1,6 +1,6 @@
option.SHADER_VERSION_LABEL = §d§lECLIPSE§r - Bliss 编辑版
prefix.SHADER_VERSION_LABEL = 版本
value.SHADER_VERSION_LABEL.482 = 8.2.1
value.SHADER_VERSION_LABEL.482 = 8.2.2
# 如果你是来翻译的,这不是玩笑,这些选项的功能正如其名
profile.POTATO=§4土豆 (极低配置)
+4
View File
@@ -1159,6 +1159,10 @@ const vec3 aerochrome_color = mix(vec3(1.0, 0.0, 0.0), vec3(0.715, 0.303, 0.631)
#ifdef LPV_HANDHELD_SHADOWS
#endif
#define HANDHELD_LIGHT_REFLECTIONS 100 // [0 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 150 175 200]
#ifdef HANDHELD_LIGHT_REFLECTIONS
#endif
//////////////////////////////////
// ----- VOXY SETTINGS ----- //
+7 -7
View File
@@ -2456,7 +2456,7 @@ vec3 specularReflections(
specularReflections += flashLightReflection;
#endif
#if defined Hand_Held_lights && defined IS_LPV_ENABLED
#if defined Hand_Held_lights && defined IS_LPV_ENABLED && HANDHELD_LIGHT_REFLECTIONS > 0
if(!isHand && firstPersonCamera
#ifdef DEFERRED_SPECULAR
&& !isShaderGrass
@@ -2470,8 +2470,8 @@ vec3 specularReflections(
vec3 handLightCol = GetHandLight(heldItemId, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
@@ -2483,8 +2483,8 @@ vec3 specularReflections(
vec3 handLightCol = GetHandLight(heldItemId2, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
@@ -2497,8 +2497,8 @@ vec3 specularReflections(
vec3 handLightCol = GetHandLight(IEXT_beltborne_lanterns_Id, shiftedPlayerPos, lightRange);
if(lightRange > 0.0) {
vec3 handheldReflection1 = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection1;
vec3 handheldReflection = handLightCol * GGX(normal, -shiftedPlayerPos, -shiftedPlayerPos, roughness, reflectance, metalAlbedoTint);
specularReflections += handheldReflection*HANDHELD_LIGHT_REFLECTIONS*0.005;
}
}
#endif
File diff suppressed because one or more lines are too long