diff --git a/Effects/Dyes/AerialiteDyeShader.fx b/Effects/Dyes/AerialiteDyeShader.fx index fbe1872edd..22b2b4ee27 100644 --- a/Effects/Dyes/AerialiteDyeShader.fx +++ b/Effects/Dyes/AerialiteDyeShader.fx @@ -29,7 +29,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; @@ -52,7 +52,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float4 metalColor = lerp(color, float4(BlendColor(color.rgb * 0.6, uColor), 1), 0.7); // And mix it all together. - return (color * 0.35 + metalColor * 0.65 + updraftColor * 0.8 + cloudColor * 0.3) * color.a * 0.85; + return (color * 0.35 + metalColor * 0.65 + updraftColor * 0.8 + cloudColor * 0.3) * color.a * sampleColor * 0.85; } technique Technique1 { diff --git a/Effects/Dyes/AerialiteDyeShader.xnb b/Effects/Dyes/AerialiteDyeShader.xnb index 38221656d5..079c6f5f7b 100644 Binary files a/Effects/Dyes/AerialiteDyeShader.xnb and b/Effects/Dyes/AerialiteDyeShader.xnb differ diff --git a/Effects/Dyes/AstralBlueDyeShader.fx b/Effects/Dyes/AstralBlueDyeShader.fx index ec1ff1b145..d1b7a0f077 100644 --- a/Effects/Dyes/AstralBlueDyeShader.fx +++ b/Effects/Dyes/AstralBlueDyeShader.fx @@ -21,13 +21,13 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); float interval = cos(uTime * 7 + framedCoords.x * 4) / 2 + 0.5; float4 returnColor = float4(lerp(uColor, uSecondaryColor, interval), 1); // Fade between two colors depending on the time and x position on the texture in a 0-1 cosine linear interpolation. The color can vary. - return returnColor * color; // And multiply by the original color to give it a blend effect. + return returnColor * sampleColor * color; // And multiply by the original color to give it a blend effect. } technique Technique1 { diff --git a/Effects/Dyes/AstralBlueDyeShader.xnb b/Effects/Dyes/AstralBlueDyeShader.xnb index f78dd3b877..785e1e3220 100644 Binary files a/Effects/Dyes/AstralBlueDyeShader.xnb and b/Effects/Dyes/AstralBlueDyeShader.xnb differ diff --git a/Effects/Dyes/AstralDyeShader.fx b/Effects/Dyes/AstralDyeShader.fx index d894a8dd54..d3539b40f6 100644 --- a/Effects/Dyes/AstralDyeShader.fx +++ b/Effects/Dyes/AstralDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; @@ -42,7 +42,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // Become notably darker to reinforce the stone aesthetic. stoneColor.rgb *= 0.2 + noiseColor.r * 0.65; - return (stoneColor + flameColor * 0.4) * color.a; + return (stoneColor + flameColor * 0.4) * sampleColor * color.a; } technique Technique1 { diff --git a/Effects/Dyes/AstralDyeShader.xnb b/Effects/Dyes/AstralDyeShader.xnb index 49f8351acc..0f7330cf1b 100644 Binary files a/Effects/Dyes/AstralDyeShader.xnb and b/Effects/Dyes/AstralDyeShader.xnb differ diff --git a/Effects/Dyes/AstralOrangeDyeShader.fx b/Effects/Dyes/AstralOrangeDyeShader.fx index f7e61dc67e..22edad0fae 100644 --- a/Effects/Dyes/AstralOrangeDyeShader.fx +++ b/Effects/Dyes/AstralOrangeDyeShader.fx @@ -21,14 +21,14 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); - float interval = (cos((uTime - 0.5) * 17 + framedCoords.y * 8) / 2 + 0.5); + float interval = (sin((uTime - 0.5) * 17 + framedCoords.y * 8) / 2 + 0.5); float4 returnColor = float4(lerp(uColor, uSecondaryColor, interval), 1); // One again, use a cosine lerp based on position and time, but this time, with the Y position. - return returnColor * color; + return returnColor * color * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/AstralOrangeDyeShader.xnb b/Effects/Dyes/AstralOrangeDyeShader.xnb index 0b50ee3f1b..de89577f2d 100644 Binary files a/Effects/Dyes/AstralOrangeDyeShader.xnb and b/Effects/Dyes/AstralOrangeDyeShader.xnb differ diff --git a/Effects/Dyes/AstralSwirlDyeShader.fx b/Effects/Dyes/AstralSwirlDyeShader.fx index 33f9cb17f5..4ca2d68511 100644 --- a/Effects/Dyes/AstralSwirlDyeShader.fx +++ b/Effects/Dyes/AstralSwirlDyeShader.fx @@ -26,18 +26,18 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); - float interval = (cos(uTime * 2.2 + framedCoords.x * framedCoords.y * 1.55) * 0.5 + 0.5) * 0.6 + 0.2; // A complex function that works based on the X and Y coords with a 0.2-0.8 range. + float interval = (sin(uTime * 2.2 + framedCoords.x * framedCoords.y * 1.55 + 1.57) * 0.5 + 0.5) * 0.6 + 0.2; // A complex function that works based on the X and Y coords with a 0.2-0.8 range. float brightness = 1.35; float3 returnColor = uColor; // Rotate the colors around and adjust the brightness. for (int i = 0; i < 4; i++) { float2 positionAt = float2(interval, 1 - interval); - positionAt = (RotatedBy(float2(cos(uTime * 1.7 + i / 4 * 6.283), cos(uTime * 1.9 + i / 4 * 6.283)), uTime + i / 4 * 6.283) * 0.5 + 0.5) - positionAt; + positionAt = (RotatedBy(float2(sin(uTime * 1.7 + i / 4 * 6.283), sin(uTime * 1.9 + i / 4 * 6.283)), uTime + i / 4 * 6.283) * 0.5 + 0.5) - positionAt; float dist = distance(coords, positionAt); if (dist < 0.35) { @@ -52,12 +52,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO returnColor = lerp(returnColor, uSecondaryColor, (framedCoords.y - 0.5) * 3); } - return float4(returnColor, 1) * color * brightness; + return float4(returnColor, 1) * color * sampleColor * brightness; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/AstralSwirlDyeShader.xnb b/Effects/Dyes/AstralSwirlDyeShader.xnb index 3149938b49..82bf612a58 100644 Binary files a/Effects/Dyes/AstralSwirlDyeShader.xnb and b/Effects/Dyes/AstralSwirlDyeShader.xnb differ diff --git a/Effects/Dyes/AuricDyeShader.fx b/Effects/Dyes/AuricDyeShader.fx index 48af60bd46..187ab5463e 100644 --- a/Effects/Dyes/AuricDyeShader.fx +++ b/Effects/Dyes/AuricDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; @@ -42,12 +42,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // Use a specialized blend method to create the shine effect. color.rgb = (length(color.rgb) <= 0.5) ? 2 * color.rgb * goldColor : 1 - 2 * (1 - color.rgb) * (1 - goldColor); - return (color + noiseColor * 0.45) * color.a; + return (color + noiseColor * 0.45) * sampleColor * color.a; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/AuricDyeShader.xnb b/Effects/Dyes/AuricDyeShader.xnb index d58ab23c08..123b7a573d 100644 Binary files a/Effects/Dyes/AuricDyeShader.xnb and b/Effects/Dyes/AuricDyeShader.xnb differ diff --git a/Effects/Dyes/BloodflareDyeShader.fx b/Effects/Dyes/BloodflareDyeShader.fx index 8714257fab..ca68a699db 100644 --- a/Effects/Dyes/BloodflareDyeShader.fx +++ b/Effects/Dyes/BloodflareDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 pixelBelow = tex2D(uImage0, coords); @@ -41,7 +41,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // Handle red fades based on noise. color = lerp(color, float4(1, 0, 0, 1), pow(noiseColor.r, 3) * 0.3 + verticalFlowMovement * 0.3 + 0.16) * color.a; - return color * (1 + (1 - outlineFade) * 0.25); + return color * (1 + (1 - outlineFade) * 0.25) * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/BloodflareDyeShader.xnb b/Effects/Dyes/BloodflareDyeShader.xnb index 9164223900..66eef1b7b3 100644 Binary files a/Effects/Dyes/BloodflareDyeShader.xnb and b/Effects/Dyes/BloodflareDyeShader.xnb differ diff --git a/Effects/Dyes/BrimflameDyeShader.fx b/Effects/Dyes/BrimflameDyeShader.fx index 76224fb027..069956a418 100644 --- a/Effects/Dyes/BrimflameDyeShader.fx +++ b/Effects/Dyes/BrimflameDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); @@ -36,7 +36,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float3 flameColor = lerp(alteredColor, alteredSecondaryColor, fadeToRed); flameColor.r = 0.6 + sqrt(fadeToRed) * 0.4; color = lerp(color, float4(flameColor, 1), 0.45) * color.a; - return color * lerp(1.3, 5.4, pow(flameStreakBrightness, 4.44)); + return color * lerp(1.3, 5.4, pow(flameStreakBrightness, 4.44)) * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/BrimflameDyeShader.xnb b/Effects/Dyes/BrimflameDyeShader.xnb index 6e1bf8331b..74666725e8 100644 Binary files a/Effects/Dyes/BrimflameDyeShader.xnb and b/Effects/Dyes/BrimflameDyeShader.xnb differ diff --git a/Effects/Dyes/CalamitousDyeShader.fx b/Effects/Dyes/CalamitousDyeShader.fx index b3e13de81a..12c826bd2b 100644 --- a/Effects/Dyes/CalamitousDyeShader.fx +++ b/Effects/Dyes/CalamitousDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 noiseColor = tex2D(uImage1, framedCoords); @@ -40,12 +40,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO blendFactor *= framedCoords.y / 0.2; } float4 colorBlendMultiplier = lerp(float4(blendColor, 1), float4(1, 1, 1, 1), saturate(pow(blendFactor * 1.5, 2))); - return (lerp(color, float4(blendColor, 1), blendFactor * 0.5 + 0.2) * color.a) * colorBlendMultiplier * (1 + brightness); + return (lerp(color, float4(blendColor, 1), blendFactor * 0.5 + 0.2) * color.a) * colorBlendMultiplier * (1 + brightness) * sampleColor; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/CalamitousDyeShader.xnb b/Effects/Dyes/CalamitousDyeShader.xnb index a9ad15843b..98ff4d7091 100644 Binary files a/Effects/Dyes/CalamitousDyeShader.xnb and b/Effects/Dyes/CalamitousDyeShader.xnb differ diff --git a/Effects/Dyes/CeaselessDyeShader.fx b/Effects/Dyes/CeaselessDyeShader.fx index 8b6b8554af..0fbb61a21a 100644 --- a/Effects/Dyes/CeaselessDyeShader.fx +++ b/Effects/Dyes/CeaselessDyeShader.fx @@ -27,14 +27,14 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; coords.x += randomness(uTime + framedCoords.y).x * (1 - framedCoords.y) * 6 / uImageSize0.x; // Add an X offset based on a noise function, giving a moon lord void-esque shader effect. float4 color = tex2D(uImage0, coords); float4 returnColor = color * 0.1; returnColor.a = color.a; - return returnColor; + return returnColor * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/CeaselessDyeShader.xnb b/Effects/Dyes/CeaselessDyeShader.xnb index 2d2971eff7..02571b5f18 100644 Binary files a/Effects/Dyes/CeaselessDyeShader.xnb and b/Effects/Dyes/CeaselessDyeShader.xnb differ diff --git a/Effects/Dyes/CosmicFlameShader.fx b/Effects/Dyes/CosmicFlameShader.fx index 624511762c..5ecb960b59 100644 --- a/Effects/Dyes/CosmicFlameShader.fx +++ b/Effects/Dyes/CosmicFlameShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float2 swirlOffset = float2(sin(uTime * 0.26 + 1.754) * 0.31, sin(uTime * 0.26) * 0.16) * uSaturation; @@ -46,12 +46,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // And create stars based on a noise texture that rise upward. color = lerp(color, float4(starColor, 1) * color.a, fadeToNormal * pow(brightnessFactor, 6) * 0.15); - return color * (1 + brightnessFactor); + return color * (1 + brightnessFactor) * sampleColor; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/CosmicFlameShader.xnb b/Effects/Dyes/CosmicFlameShader.xnb index b2851d2938..77399b244c 100644 Binary files a/Effects/Dyes/CosmicFlameShader.xnb and b/Effects/Dyes/CosmicFlameShader.xnb differ diff --git a/Effects/Dyes/CosmiliteDyeShader.fx b/Effects/Dyes/CosmiliteDyeShader.fx index 34d100a222..d21a65fd1f 100644 --- a/Effects/Dyes/CosmiliteDyeShader.fx +++ b/Effects/Dyes/CosmiliteDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); @@ -35,7 +35,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO baseColor *= 1 + pow(baseColor, 5).r * 8 - noiseColor2.r * 1.25; baseColor = lerp(baseColor, uSecondaryColor * 2, pow(noiseColor.r, 2)); - return float4(baseColor, 1) * opacity; + return float4(baseColor, 1) * sampleColor * opacity; } technique Technique1 { diff --git a/Effects/Dyes/CosmiliteDyeShader.xnb b/Effects/Dyes/CosmiliteDyeShader.xnb index 04e0b4554f..1d2ae49391 100644 Binary files a/Effects/Dyes/CosmiliteDyeShader.xnb and b/Effects/Dyes/CosmiliteDyeShader.xnb differ diff --git a/Effects/Dyes/CryonicDyeShader.fx b/Effects/Dyes/CryonicDyeShader.fx index cdd28b50c5..cc73f53ef9 100644 --- a/Effects/Dyes/CryonicDyeShader.fx +++ b/Effects/Dyes/CryonicDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 noiseColor = tex2D(uImage1, float2(frac(framedCoords.x + uTime * 0.1), framedCoords.y)); @@ -39,7 +39,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO if (normalizedDistanceFromCenter > 0.7) fadeToSecondaryColor *= saturate(1 - (normalizedDistanceFromCenter - 0.7) / 0.2); float4 endFadeColor = lerp(float4(uColor, 1), float4(uSecondaryColor, 1), 0.5); - return (lerp(color, endFadeColor, 0.3 + fadeToSecondaryColor * 0.6) * color.a) * (1 + brightness); + return (lerp(color, endFadeColor, 0.3 + fadeToSecondaryColor * 0.6) * color.a) * sampleColor * (1 + brightness); } technique Technique1 { diff --git a/Effects/Dyes/CryonicDyeShader.xnb b/Effects/Dyes/CryonicDyeShader.xnb index e7e3077218..b2bbcb543a 100644 Binary files a/Effects/Dyes/CryonicDyeShader.xnb and b/Effects/Dyes/CryonicDyeShader.xnb differ diff --git a/Effects/Dyes/DefiledFlameDyeShader.fx b/Effects/Dyes/DefiledFlameDyeShader.fx index 7c56288de8..d2a82133cd 100644 --- a/Effects/Dyes/DefiledFlameDyeShader.fx +++ b/Effects/Dyes/DefiledFlameDyeShader.fx @@ -25,7 +25,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); @@ -40,7 +40,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO colorMap.rgb *= brightness; colorMap.rgb = colorMap.rgb - colorMap.rgb % Variance; // Slice the return color map to make pixels appear less varied and more extreme - return colorMap * color; + return colorMap * color * sampleColor * sampleColor.a; } technique Technique1 { diff --git a/Effects/Dyes/DefiledFlameDyeShader.xnb b/Effects/Dyes/DefiledFlameDyeShader.xnb index fa0bc32b1e..9ad552827d 100644 Binary files a/Effects/Dyes/DefiledFlameDyeShader.xnb and b/Effects/Dyes/DefiledFlameDyeShader.xnb differ diff --git a/Effects/Dyes/DragonSoulDyeShader.fx b/Effects/Dyes/DragonSoulDyeShader.fx index ff9c9c6dc7..82db5d09cf 100644 --- a/Effects/Dyes/DragonSoulDyeShader.fx +++ b/Effects/Dyes/DragonSoulDyeShader.fx @@ -29,20 +29,20 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); - float interval = (cos(framedCoords.x * 6.283 + uTime * 3.141) * 2 + sin(uTime * 7 + framedCoords.y * 6)) * 0.125 + 0.5; + float interval = (sin(framedCoords.x * 6.283 + uTime * 3.141) * 2 + sin(uTime * 7 + framedCoords.y * 6)) * 0.125 + 0.5; interval *= 2; // Exaggerate the interval. float4 returnColor = float4(lerp(colors[floor(interval) % 4], colors[floor(interval + 1) % 4], interval % 1), 1); // But clamp it to a 0-1 range. - return returnColor * color * 1.95; + return returnColor * color * sampleColor * 1.95; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/DragonSoulDyeShader.xnb b/Effects/Dyes/DragonSoulDyeShader.xnb index 25e328a9f6..51016279ce 100644 Binary files a/Effects/Dyes/DragonSoulDyeShader.xnb and b/Effects/Dyes/DragonSoulDyeShader.xnb differ diff --git a/Effects/Dyes/ElementalDyeShader.fx b/Effects/Dyes/ElementalDyeShader.fx index 67c13b2af3..1bce69bfa1 100644 --- a/Effects/Dyes/ElementalDyeShader.fx +++ b/Effects/Dyes/ElementalDyeShader.fx @@ -21,11 +21,11 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); - float time = (sin(uTime + framedCoords.x * cos(uTime + 3.141 * framedCoords.x) + 1.5707 * framedCoords.y) * 0.5 + 0.5) * 6; + float time = (sin(uTime + framedCoords.x * sin(uTime + 3.141 * framedCoords.x) + 1.5707 * framedCoords.y) * 0.5 + 0.5) * 6; float timeFloored = floor(time); float3 colors[6] = @@ -40,12 +40,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // Use a multi-lerp to fade between colors and then base them on a trig-based time step. color.rgb *= lerp(colors[timeFloored] / 255.0, colors[(timeFloored + 1) % 6] / 255.0, time / 6) * 1.6; - return color; + return color * sampleColor; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/ElementalDyeShader.xnb b/Effects/Dyes/ElementalDyeShader.xnb index 17e00fdb00..a058d35d1e 100644 Binary files a/Effects/Dyes/ElementalDyeShader.xnb and b/Effects/Dyes/ElementalDyeShader.xnb differ diff --git a/Effects/Dyes/EndothermicDyeShader.fx b/Effects/Dyes/EndothermicDyeShader.fx index 71da951320..1ee81b9098 100644 --- a/Effects/Dyes/EndothermicDyeShader.fx +++ b/Effects/Dyes/EndothermicDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; @@ -30,7 +30,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float4 color = tex2D(uImage0, coords); float luminosity = (color.r + color.g + color.b) / 3; color.rgb = luminosity * idealColor * 1.3; // Average out the colors. - return color; + return color * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/EndothermicDyeShader.xnb b/Effects/Dyes/EndothermicDyeShader.xnb index ac4bca77c8..d3745d6622 100644 Binary files a/Effects/Dyes/EndothermicDyeShader.xnb and b/Effects/Dyes/EndothermicDyeShader.xnb differ diff --git a/Effects/Dyes/ExoDyeShader.fx b/Effects/Dyes/ExoDyeShader.fx index fd5de42c32..66df3bc5fc 100644 --- a/Effects/Dyes/ExoDyeShader.fx +++ b/Effects/Dyes/ExoDyeShader.fx @@ -56,7 +56,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 noiseColor = tex2D(uImage1, float2(framedCoords.x, framedCoords.y - uTime * 0.45) * 0.1); @@ -66,12 +66,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float brightness = (blendFactor * 0.4 + noiseColor.r * 0.9) * 1.2; float4 colorBlendMultiplier = lerp(float4(blendColor, 1), float4(1, 1, 1, 1), saturate(blendFactor * 1.5)); - return (lerp(color, float4(blendColor, 1), blendFactor * 0.5 + 0.2) * color.a) * colorBlendMultiplier * (1 + brightness); + return (lerp(color, float4(blendColor, 1), blendFactor * 0.5 + 0.2) * color.a) * sampleColor * colorBlendMultiplier * (1 + brightness); } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/ExoDyeShader.xnb b/Effects/Dyes/ExoDyeShader.xnb index c78cad0aef..46d12eb074 100644 Binary files a/Effects/Dyes/ExoDyeShader.xnb and b/Effects/Dyes/ExoDyeShader.xnb differ diff --git a/Effects/Dyes/NightmareDyeShader.fx b/Effects/Dyes/NightmareDyeShader.fx index ad9abbe471..a05e8e504f 100644 --- a/Effects/Dyes/NightmareDyeShader.fx +++ b/Effects/Dyes/NightmareDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float3 idealColor = uColor; @@ -33,7 +33,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float4 color = tex2D(uImage0, coords); float luminosity = (color.r + color.g + color.b) / 3; color.rgb = luminosity * idealColor * 1.6; // Average out the colors. - return color; + return color * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/NightmareDyeShader.xnb b/Effects/Dyes/NightmareDyeShader.xnb index 4e52fc32ec..5cf941877a 100644 Binary files a/Effects/Dyes/NightmareDyeShader.xnb and b/Effects/Dyes/NightmareDyeShader.xnb differ diff --git a/Effects/Dyes/PhantoplasmDyeShader.fx b/Effects/Dyes/PhantoplasmDyeShader.fx index 5e48cfc31e..dc937ddf26 100644 --- a/Effects/Dyes/PhantoplasmDyeShader.fx +++ b/Effects/Dyes/PhantoplasmDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 noiseColor = tex2D(uImage1, float2(framedCoords.x, frac(framedCoords.y + uTime * 0.7))); @@ -39,7 +39,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO float4 blendedColor = (color + endFadeColor) * 0.5 - 0.05; blendedColor *= 1.4; blendedColor.a = 1; - return blendedColor * color.a * (1 + lerp(0.07, 0.3, fadeToSecondaryColor) + noiseColor.g * 0.1); + return blendedColor * color.a * (1 + lerp(0.07, 0.3, fadeToSecondaryColor) + noiseColor.g * 0.1) * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/PhantoplasmDyeShader.xnb b/Effects/Dyes/PhantoplasmDyeShader.xnb index 40f81c156e..d49d7dcf29 100644 Binary files a/Effects/Dyes/PhantoplasmDyeShader.xnb and b/Effects/Dyes/PhantoplasmDyeShader.xnb differ diff --git a/Effects/Dyes/ProfanedFlameDyeShader.fx b/Effects/Dyes/ProfanedFlameDyeShader.fx index 9c47314e41..8c4ecb6817 100644 --- a/Effects/Dyes/ProfanedFlameDyeShader.fx +++ b/Effects/Dyes/ProfanedFlameDyeShader.fx @@ -21,13 +21,13 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); // Read the fade map as a streak. - float4 fadeMapColor = tex2D(uImage1, float2(frac(framedCoords.x * 0.18 + cos(uTime * 0.9) * 0.021), frac(framedCoords.y * 0.32 + uTime * 0.2))); + float4 fadeMapColor = tex2D(uImage1, float2(frac(framedCoords.x * 0.18 + sin(uTime * 0.9) * 0.021), frac(framedCoords.y * 0.32 + uTime * 0.2))); fadeMapColor.r *= pow(framedCoords.x, 0.2); float opacity = lerp(1.05, 1.95, fadeMapColor.r); @@ -41,7 +41,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO transformColor = lerp(transformColor, float3(206 / 255, 116 / 255, 59 / 255), orangeFade); color.rgb = lerp(color.rgb, transformColor, fadeMapColor.r); opacity *= color.a; - return color * opacity; + return color * sampleColor * opacity; } technique Technique1 { diff --git a/Effects/Dyes/ProfanedFlameDyeShader.xnb b/Effects/Dyes/ProfanedFlameDyeShader.xnb index 5e2e87ffde..6312ce8a11 100644 Binary files a/Effects/Dyes/ProfanedFlameDyeShader.xnb and b/Effects/Dyes/ProfanedFlameDyeShader.xnb differ diff --git a/Effects/Dyes/ProfanedMoonlightDye.fx b/Effects/Dyes/ProfanedMoonlightDye.fx index 467893fac2..75894ab43c 100644 --- a/Effects/Dyes/ProfanedMoonlightDye.fx +++ b/Effects/Dyes/ProfanedMoonlightDye.fx @@ -20,7 +20,7 @@ float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD { float4 returnColor = tex2D(uImage0, coords); returnColor.rgb *= uColor * max(1, (sin(uTime) * 0.5 + 0.5) * 0.3 + 1.3); - return returnColor; + return returnColor * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/ProfanedMoonlightDye.xnb b/Effects/Dyes/ProfanedMoonlightDye.xnb index 03bdc522c0..b404745683 100644 Binary files a/Effects/Dyes/ProfanedMoonlightDye.xnb and b/Effects/Dyes/ProfanedMoonlightDye.xnb differ diff --git a/Effects/Dyes/ReaverDyeShader.fx b/Effects/Dyes/ReaverDyeShader.fx index db0966aafd..fd945f8736 100644 --- a/Effects/Dyes/ReaverDyeShader.fx +++ b/Effects/Dyes/ReaverDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); @@ -30,7 +30,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO color.rgb *= ((framedCoords.x * uColor * (1 - yMultiplier) * 1.4) + ((1 - framedCoords.x) * uSecondaryColor * yMultiplier * 1.7)) * luminosity * 2.1; color.rgb *= clamp(1.6 * saturate(distance((0.5, 0.5), framedCoords)), 0.8, 1.6); // Intensify the colors based on how far they are from the center of the sprite. - return color; + return color * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/ReaverDyeShader.xnb b/Effects/Dyes/ReaverDyeShader.xnb index 877b808101..9265449b00 100644 Binary files a/Effects/Dyes/ReaverDyeShader.xnb and b/Effects/Dyes/ReaverDyeShader.xnb differ diff --git a/Effects/Dyes/ShadowspecDyeShader.fx b/Effects/Dyes/ShadowspecDyeShader.fx index c501691ea2..18db9000d3 100644 --- a/Effects/Dyes/ShadowspecDyeShader.fx +++ b/Effects/Dyes/ShadowspecDyeShader.fx @@ -18,14 +18,14 @@ float2 uLegacyArmorSheetSize; float2 RotatedBy(float theta, float x, float y) { - return float2(x * cos(theta) + y * sin(theta), x * sin(theta) - y * cos(theta)); + return float2(x * sin(theta + 1.57) + y * sin(theta), x * sin(theta) - y * sin(theta + 1.57)); } float2 InverseLerp(float2 start, float2 end, float2 x) { return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float sineTime = sin(uTime); // Saved so that I don't have the compute this multiple times. Shaders have a limited number of mathematical instructions you can use - 64. @@ -35,7 +35,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO modifiedCoords = RotatedBy(uTime + 0.4 * sineTime, modifiedCoords.y, modifiedCoords.x); float4 noiseColor = tex2D(uImage1, modifiedCoords); - float xMultiplier = cos(framedCoords.x * 2.3 + uTime) + 1; + float xMultiplier = sin(framedCoords.x * 2.3 + uTime + 1.57) + 1; float yMultiplier = sin(framedCoords.y * 2 + uTime * 1.4) + 1; float interpolationValue = saturate(xMultiplier * yMultiplier) * 0.7 + 0.3; // Range of 0-1. Depends on the current coordinates and the time. @@ -43,12 +43,12 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO color.rgb *= 0.2 + pow(noiseColor.rgb, 3); // Squash the color to the upper and lower bounds and add a bit of lightness to it. color.rgb *= lerp(uColor, uSecondaryColor, interpolationValue); // Blend with the secondary color. color.rgb *= 1.7 + (sineTime * 0.5 + 1.5) * interpolationValue; // Range of 1.7 to 3.7, can cause certain spots to become very bright. - return color; + return color * sampleColor; } technique Technique1 { pass DyePass { - PixelShader = compile ps_2_0 PixelShaderFunction(); + PixelShader = compile ps_3_0 PixelShaderFunction(); } } \ No newline at end of file diff --git a/Effects/Dyes/ShadowspecDyeShader.xnb b/Effects/Dyes/ShadowspecDyeShader.xnb index f95f233945..73f535eaf2 100644 Binary files a/Effects/Dyes/ShadowspecDyeShader.xnb and b/Effects/Dyes/ShadowspecDyeShader.xnb differ diff --git a/Effects/Dyes/SlimeGodDyeShader.fx b/Effects/Dyes/SlimeGodDyeShader.fx index 458d4f26fa..20a64cc51f 100644 --- a/Effects/Dyes/SlimeGodDyeShader.fx +++ b/Effects/Dyes/SlimeGodDyeShader.fx @@ -21,7 +21,7 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); @@ -42,7 +42,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO // Handle sludge fades based on noise. color = lerp(color, float4(uSecondaryColor * 0.375, 1), pow(noiseColor.r, 3) * 0.3 + verticalFlowMovement * 0.3 + 0.13) * color.a; - return color * (1 + (1 - outlineFade) * 0.1); + return color * sampleColor * (1 + (1 - outlineFade) * 0.1); } technique Technique1 { diff --git a/Effects/Dyes/SlimeGodDyeShader.xnb b/Effects/Dyes/SlimeGodDyeShader.xnb index dd68e84f6b..5cb258832c 100644 Binary files a/Effects/Dyes/SlimeGodDyeShader.xnb and b/Effects/Dyes/SlimeGodDyeShader.xnb differ diff --git a/Effects/Dyes/StratusDyeShader.fx b/Effects/Dyes/StratusDyeShader.fx index 6a8ce34270..f9b8c23901 100644 --- a/Effects/Dyes/StratusDyeShader.fx +++ b/Effects/Dyes/StratusDyeShader.fx @@ -22,17 +22,17 @@ float2 InverseLerp(float2 start, float2 end, float2 x) return saturate((x - start) / (end - start)); } -float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOORD0) : COLOR0 +float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { float2 framedCoords = (coords * uImageSize0 - uSourceRect.xy) / uSourceRect.zw; float4 color = tex2D(uImage0, coords); float sineTime = sin(uTime); // Saved so that I don't have the compute this multiple times. Shaders have a limited number of mathematical instructions you can use - 64. float2 modifiedCoords = coords; - modifiedCoords.x += cos(uTime + framedCoords.y) * 0.5 + 0.5; // Cause the effect to sway around a bit with time. + modifiedCoords.x += sin(uTime + framedCoords.y + 1.57) * 0.5 + 0.5; // Cause the effect to sway around a bit with time. float4 noiseColor = tex2D(uImage1, frac(modifiedCoords)); - float xMultiplier = cos(framedCoords.x * 2.3 + uTime * 1.15) + 0.5; + float xMultiplier = sin(framedCoords.x * 2.3 + uTime * 1.15 + 1.57) + 0.5; float yMultiplier = (sin(framedCoords.y * 2 + uTime * 1.4) + 1) * 0.5; color.rgb *= lerp(uColor, uSecondaryColor, saturate(xMultiplier * yMultiplier * 1.6)); @@ -41,7 +41,7 @@ float4 PixelShaderFunction(float4 sampleColor : TEXCOORD, float2 coords : TEXCOO color.rgb *= 1.6; // Sometimes give light "patches" depending on the swaying noise image. } color.rgb *= 1.6; // Brighten the shader over time. - return color; + return color * sampleColor; } technique Technique1 { diff --git a/Effects/Dyes/StratusDyeShader.xnb b/Effects/Dyes/StratusDyeShader.xnb index b7107324ff..f2d450e689 100644 Binary files a/Effects/Dyes/StratusDyeShader.xnb and b/Effects/Dyes/StratusDyeShader.xnb differ diff --git a/Effects/IntersectionClipShader.fx b/Effects/IntersectionClipShader.fx index cce7b32bee..21c6aa4fa4 100644 --- a/Effects/IntersectionClipShader.fx +++ b/Effects/IntersectionClipShader.fx @@ -20,12 +20,12 @@ float4 uShaderSpecificData; float2 RotatedBy(float2 xy, float theta) { - return float2(xy.x * cos(theta) + xy.y * sin(theta), xy.x * sin(theta) - xy.y * cos(theta)); + return float2(xy.x * sin(theta + 1.57) - xy.y * sin(theta), xy.x * sin(theta) + xy.y * sin(theta + 1.57)); } float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0 { - float2 worldPos = uWorldPosition + RotatedBy(coords - 0.5, uRotation - 1.57) * uSize; - if (sign(dot(uIntersectionNormal, worldPos - uIntersectionPosition)) == uIntersectionCutoffDirection) + float2 worldPos = uWorldPosition + RotatedBy(coords - 0.5, uRotation) * uSize; + if (sign(dot(uIntersectionNormal, normalize(worldPos - uIntersectionPosition))) == uIntersectionCutoffDirection) return 0; return tex2D(uImage0, coords) * sampleColor; diff --git a/Effects/IntersectionClipShader.xnb b/Effects/IntersectionClipShader.xnb index 39031b6a83..8fc86f0147 100644 Binary files a/Effects/IntersectionClipShader.xnb and b/Effects/IntersectionClipShader.xnb differ diff --git a/Projectiles/Melee/Spears/StreamGougeProj.cs b/Projectiles/Melee/Spears/StreamGougeProj.cs index ce4c43fa86..f7d8803fc4 100644 --- a/Projectiles/Melee/Spears/StreamGougeProj.cs +++ b/Projectiles/Melee/Spears/StreamGougeProj.cs @@ -161,11 +161,11 @@ namespace CalamityMod.Projectiles.Melee.Spears { Main.spriteBatch.EnterShaderRegion(); Vector2 intersectionNormal = portalDrawPosition + Main.screenPosition - Projectile.Center; - Vector2 worldOffset = Projectile.rotation.ToRotationVector2() * -45f; + Vector2 worldOffset = Projectile.rotation.ToRotationVector2() * Utils.GetLerpValue(0f, StreamGouge.SpearFireTime, Time - StreamGouge.SpinTime, true) * 80f; Vector2 intersectionOffset = (portalDrawPosition + Main.screenPosition - Projectile.Center) * -1.5f; GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uIntersectionPosition"].SetValue(portalDrawPosition + intersectionOffset); GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uIntersectionNormal"].SetValue(intersectionNormal); - GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uIntersectionCutoffDirection"].SetValue(-1f); + GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uIntersectionCutoffDirection"].SetValue(1f); GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uWorldPosition"].SetValue(Projectile.Center - Main.screenPosition + worldOffset); GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uSize"].SetValue(texture.Size()); GameShaders.Misc["CalamityMod:IntersectionClip"].Shader.Parameters["uRotation"].SetValue(Projectile.rotation);