//Heatwave PS. Rail gun when shooting.
// ---- Created with 3Dmigoto v0.6.163 on Sun Sep 13 00:10:55 2026
Texture2D<float4> t2 : register(t2);

Texture2D<float4> t1 : register(t1);

Texture2D<float4> t0 : register(t0);

SamplerState s2_s : register(s2);

SamplerState s1_s : register(s1);

SamplerState s0_s : register(s0);

cbuffer cb0 : register(b0)
{
  float4 cb0[2];
}




// 3Dmigoto declarations
#define cmp -
Texture1D<float4> IniParams : register(t120);
Texture2D<float4> StereoParams : register(t125);


void main(
  float4 v0 : SV_POSITION0,
  float v1 : COLOR2,
  float2 w1 : TEXCOORD0,
  float4 v2 : TEXCOORD1,
  float4 v3 : TEXCOORD2,
  int4 v4 : TEXCOORD4,
  float4 v5 : TEXCOORD5,
  float4 v6 : TEXCOORD7,
  out float4 o0 : SV_TARGET0)
{
  float4 r0;
  uint4 bitmask, uiDest;
  float4 fDest;
  
  float4 stereo = StereoParams.Load(0);
  
  r0.xy = t1.Sample(s1_s, v2.xy).yw;
  r0.xy = float2(-0.5,-0.5) + r0.yx;
  r0.xy = cb0[1].xy * r0.xy;
  
  v3.x+=stereo.x*(1-stereo.y/v0.w)*0.5;
  
  r0.xy = r0.xy * float2(2,2) + v3.xy;
  r0.xyzw = t2.Sample(s2_s, r0.xy).xyzw;
  r0.xyz = r0.xyz / r0.www;
  r0.xyz = cb0[0].xyz * r0.xyz;
  r0.xyz = v6.xyz * r0.xyz;
  o0.xyz = saturate(float3(0.25,0.25,0.25) * r0.xyz);
  r0.xy = t0.Sample(s0_s, w1.xy).xw;
  r0.y = cb0[0].w * r0.y;
  r0.x = r0.y * r0.x;
  o0.w = saturate(v6.w * r0.x);
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) D3D Shader Disassembler
//
//   using 3Dmigoto v0.6.163 on Sun Sep 13 00:10:55 2026
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float
// COLOR                    2   x           1     NONE   float
// TEXCOORD                 0    yz         1     NONE   float    yz
// TEXCOORD                 1   xyzw        2     NONE   float   xy
// TEXCOORD                 2   xyzw        3     NONE   float   xy
// TEXCOORD                 4   xyzw        4     NONE     int
// TEXCOORD                 5   xyzw        5     NONE   float
// TEXCOORD                 7   xyzw        6     NONE   float   xyzw
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_TARGET                0   xyzw        0   TARGET   float   xyzw
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer CB0[2], immediateIndexed
dcl_sampler s0, mode_default
dcl_sampler s1, mode_default
dcl_sampler s2, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_texture2d (float,float,float,float) t1
dcl_resource_texture2d (float,float,float,float) t2
dcl_input_ps linear v1.yz
dcl_input_ps linear v2.xy
dcl_input_ps linear v3.xy
dcl_input_ps linear v6.xyzw
dcl_output o0.xyzw
dcl_temps 1
sample_indexable(texture2d)(float,float,float,float) r0.xy, v2.xyxx, t1.ywxz, s1
add r0.xy, r0.yxyy, l(-0.500000, -0.500000, 0.000000, 0.000000)
mul r0.xy, r0.xyxx, cb0[1].xyxx
mad r0.xy, r0.xyxx, l(2.000000, 2.000000, 0.000000, 0.000000), v3.xyxx
sample_indexable(texture2d)(float,float,float,float) r0.xyzw, r0.xyxx, t2.xyzw, s2
div r0.xyz, r0.xyzx, r0.wwww
mul r0.xyz, r0.xyzx, cb0[0].xyzx
mul r0.xyz, r0.xyzx, v6.xyzx
mul_sat o0.xyz, r0.xyzx, l(0.250000, 0.250000, 0.250000, 0.000000)
sample_indexable(texture2d)(float,float,float,float) r0.xy, v1.yzyy, t0.xwyz, s0
mul r0.y, r0.y, cb0[0].w
mul r0.x, r0.x, r0.y
mul_sat o0.w, r0.x, v6.w
ret
// Approximately 0 instruction slots used

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
