486 lines
15 KiB
HLSL
486 lines
15 KiB
HLSL
string DefaultParameterScopeBlock = "material"; // 1
|
|
float3 AmbientLightColor <bool unmanaged = 1;> = { 0.3, 0.3, 0.3 };
|
|
struct {
|
|
float3 Color;
|
|
float3 Direction;
|
|
} DirectionalLight[3] <bool unmanaged = 1;> = { 1.625198, 1.512711, 1.097048, 0.62914, -0.34874, 0.69465, 0.5232916, 0.6654605, 0.7815244, -0.32877, 0.90329, 0.27563, 0.4420466, 0.4102767, 0.4420466, -0.80704, -0.58635, 0.06975 };
|
|
struct {
|
|
float3 Color;
|
|
float3 Position;
|
|
float2 Range_Inner_Outer;
|
|
} PointLight[8] <bool unmanaged = 1;>;
|
|
struct {
|
|
float4 WorldPositionMultiplier_XYZZ;
|
|
float2 CurrentOffsetUV;
|
|
} Cloud <bool unmanaged = 1;>;
|
|
float3 NoCloudMultiplier <bool unmanaged = 1;> = { 1, 1, 1 };
|
|
float3 RecolorColorDummy <bool unmanaged = 1;>;
|
|
row_major float4x4 ShadowMapWorldToShadow <bool unmanaged = 1;>;
|
|
float OpacityOverride : register(vs_2_0, c1) <bool unmanaged = 1;> = { 1 };
|
|
float3 TintColor <bool unmanaged = 1;> = { 1, 1, 1 };
|
|
float3 EyePosition <bool unmanaged = 1;>;
|
|
row_major float4x4 ViewProjection <bool unmanaged = 1;>;
|
|
float4 WorldBones[128] <bool unmanaged = 1;>;
|
|
struct {
|
|
float4 VideoTex_NumPerRow_LastFrame_SingleRow_isRand;
|
|
float4 ColorAnimationFunctions[6];
|
|
float4 TimeKeys;
|
|
int ShaderType;
|
|
float SpeedMultiplier;
|
|
float2 ColorScaleRange;
|
|
} Draw <string UIWidget = "None"; string SasBindAddress = "Particle.Draw";> = { 4, 15, -1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, -0.1, 0.2 };
|
|
struct {
|
|
float3 Gravity;
|
|
float3 DriftVelocity;
|
|
float2 VelocityDampingRange;
|
|
} Physics <string UIWidget = "None"; string SasBindAddress = "Particle.Physics";> = { 0, 0, 0, 0, 0, 0, 1, 0 };
|
|
struct {
|
|
float3 Size_Rate_Damping__Min;
|
|
float3 Size_Rate_Damping__Spread;
|
|
float3 XYRotation_Rate_Damping__Min;
|
|
float3 XYRotation_Rate_Damping__Spread;
|
|
float3 ZRotation_Rate_Damping__Min;
|
|
float3 ZRotation_Rate_Damping__Spread;
|
|
} Update <string UIWidget = "None"; string SasBindAddress = "Particle.Update";> = { 0, 0, 1, 10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0 };
|
|
texture BaseTexture <string UIName = "Base Texture";>; // 8
|
|
sampler2D BaseTextureSampler : register(ps_2_0, s0) <string Texture = "BaseTexture"; string UIName = "Base Texture";> =
|
|
sampler_state
|
|
{
|
|
Texture = <BaseTexture>; // 10
|
|
MinFilter = 2;
|
|
MagFilter = 2;
|
|
MipFilter = 2;
|
|
AddressU = 2;
|
|
AddressV = 2;
|
|
};
|
|
texture SwirlTexture <string UIName = "Swirl Texture";>; // 13
|
|
sampler2D SwirlTextureSampler : register(ps_2_0, s1) <string Texture = "SwirlTexture"; string UIName = "Swirl Texture";> =
|
|
sampler_state
|
|
{
|
|
Texture = <SwirlTexture>; // 15
|
|
MinFilter = 2;
|
|
MagFilter = 2;
|
|
MipFilter = 2;
|
|
AddressU = 2;
|
|
AddressV = 2;
|
|
};
|
|
column_major float4x4 WorldViewProjection : WorldViewProjection : register(vs_2_0, c11);
|
|
float Time : Time;
|
|
// Textured_PixelShader1 Pixel_2_0 Has PRES True
|
|
struct Textured_PixelShader1_Input
|
|
{
|
|
float3 color : COLOR;
|
|
float2 texcoord : TEXCOORD;
|
|
};
|
|
|
|
float4 Textured_PixelShader1(Textured_PixelShader1_Input i) : COLOR
|
|
{
|
|
/*
|
|
PRSI
|
|
OutputRegisterOffset: 11
|
|
Unknown1: 0
|
|
Unknown2: 0
|
|
OutputRegisterCount: 4
|
|
Unknown3: 0
|
|
Unknown4: 0
|
|
Unknown5: 11
|
|
Unknown6: 1
|
|
Mappings: 2
|
|
0 - ConstOutput: 13 ConstInput 2
|
|
1 - ConstOutput: 0 ConstInput 0
|
|
|
|
*/
|
|
float4 expr11;
|
|
float4 expr12;
|
|
float4 expr13;
|
|
float4 expr14;
|
|
{
|
|
float4 temp0;
|
|
float4 temp1;
|
|
// Expression_2_1
|
|
// mul c11.x, c0.x, (0.1075)
|
|
expr11.x = Time.x * (0.1075);
|
|
// mul c13.x, c0.x, (5.3882655)
|
|
expr13.x = Time.x * (5.3882655);
|
|
// mul r0.x, c0.x, (10.75)
|
|
temp0.x = Time.x * (10.75);
|
|
// add r1.x, r0.x, (1000)
|
|
temp1.x = temp0.x + (1000);
|
|
// mul r0.x, r1.x, (-0.01)
|
|
temp0.x = temp1.x * (-0.01);
|
|
// mul r0.y, c0.x, (0.5375)
|
|
temp0.y = Time.x * (0.5375);
|
|
// add c14.x, r0.x, r0.y
|
|
expr14.x = temp0.x + temp0.y;
|
|
}
|
|
|
|
float4 out_color;
|
|
float4 temp0, temp1;
|
|
float2 temp2;
|
|
// def c0, -0.5, 0.1193662, 0.5, 0
|
|
// def c1, 6.283185, -3.141593, 1, -1
|
|
// def c2, 5, 0, 0, 0
|
|
// def c3, -1.550099E-06, -2.170139E-05, 0.002604167, 0.0002604167
|
|
// def c4, -0.02083333, -0.125, 1, 0.5
|
|
// dcl v0.xyz
|
|
// dcl t0.xy
|
|
// dcl_2d s0
|
|
// dcl_2d s1
|
|
// mov r0.w, c13.x
|
|
temp0.w = expr13.x;
|
|
// add r0.y, r0.w, t0.y
|
|
temp0.y = temp0.w + i.texcoord.y;
|
|
// add r0.x, t0.x, c11.x
|
|
temp0.x = i.texcoord.x + expr11.x;
|
|
// mov r0.z, c14.x
|
|
temp0.z = expr14.x;
|
|
// add r1.y, r0.z, t0.y
|
|
temp1.y = temp0.z + i.texcoord.y;
|
|
// mov r1.x, t0.x
|
|
temp1.x = i.texcoord.x;
|
|
// texld r0, r0, s1
|
|
temp0 = tex2D(SwirlTextureSampler, temp0.xy);
|
|
// texld r1, r1, s1
|
|
temp1 = tex2D(SwirlTextureSampler, temp1.xy);
|
|
// add r0.x, -r0.x, r1.x
|
|
temp0.x = -temp0.x + temp1.x;
|
|
// mad r0.x, r0.x, c0.y, c0.z
|
|
temp0.x = temp0.x * float1(0.119366206) + float1(0.5);
|
|
// frc r0.x, r0.x
|
|
temp0.x = frac(temp0.x);
|
|
// mad r0.x, r0.x, c1.x, c1.y
|
|
temp0.x = temp0.x * float1(6.2831855) + float1(-3.1415927);
|
|
// sincos r1.xy, r0.x, c3, c4
|
|
temp1.xy = float2(cos(temp0.x), sin(temp0.x));
|
|
// mul r0.x, r1.y, c1.w
|
|
temp0.x = temp1.y * float1(-1);
|
|
// mul r0.y, r1.x, c1.z
|
|
temp0.y = temp1.x * float1(1);
|
|
// add r2.xy, t0, c0.x
|
|
temp2.xy = i.texcoord.xy + float2(-0.5, -0.5);
|
|
// dp2add r0.y, r2, r0, c0.w
|
|
temp0.y = dot(temp2.xy, temp0.xy) + float1(0);
|
|
// dp2add r0.x, r2, r1, c0.w
|
|
temp0.x = dot(temp2.xy, temp1.xy) + float1(0);
|
|
// add r0.xy, r0, c0.z
|
|
temp0.xy = temp0.xy + float2(0.5, 0.5);
|
|
// texld r0, r0, s0
|
|
temp0 = tex2D(BaseTextureSampler, temp0.xy);
|
|
// min r1.x, r0.x, c1.z
|
|
temp1.x = min(temp0.x, float1(1));
|
|
// mul r0.w, r1.x, c2.x
|
|
temp0.w = temp1.x * float1(5);
|
|
// mov r0.xyz, v0
|
|
temp0.xyz = i.color.xyz;
|
|
// mov oC0, r0
|
|
out_color = temp0;
|
|
//
|
|
|
|
return out_color;
|
|
}
|
|
|
|
// Textured_VertexShader2 Vertex_2_0 Has PRES True
|
|
struct Textured_VertexShader2_Input
|
|
{
|
|
float4 position : POSITION;
|
|
float4 texcoord : TEXCOORD;
|
|
float4 color : COLOR;
|
|
};
|
|
|
|
struct Textured_VertexShader2_Output
|
|
{
|
|
float4 position : POSITION;
|
|
float4 color : COLOR;
|
|
float2 texcoord : TEXCOORD;
|
|
};
|
|
|
|
Textured_VertexShader2_Output Textured_VertexShader2(Textured_VertexShader2_Input i)
|
|
{
|
|
/*
|
|
PRSI
|
|
OutputRegisterOffset: 28
|
|
Unknown1: 0
|
|
Unknown2: 0
|
|
OutputRegisterCount: 6
|
|
Unknown3: 0
|
|
Unknown4: 0
|
|
Unknown5: 28
|
|
Unknown6: 6
|
|
Mappings: 1
|
|
0 - ConstOutput: 0 ConstInput 0
|
|
|
|
*/
|
|
float4 expr28;
|
|
float4 expr29;
|
|
float4 expr30;
|
|
float4 expr31;
|
|
float4 expr32;
|
|
float4 expr33;
|
|
{
|
|
float4 temp0;
|
|
float4 temp1;
|
|
// Expression_2_1
|
|
// mul r0.x, c0.x, (3.75)
|
|
temp0.x = Time.x * (3.75);
|
|
// add r1.x, r0.x, (3.4375)
|
|
temp1.x = temp0.x + (3.4375);
|
|
// frc r0.y, r1.x
|
|
temp0.y = frac(temp1.x);
|
|
// mul r1.x, r0.y, (16)
|
|
temp1.x = temp0.y * (16);
|
|
// frc r0.y, r1.x
|
|
temp0.y = frac(temp1.x);
|
|
// neg r1.y, r0.y
|
|
temp1.y = -temp0.y;
|
|
// add c28.x, r1.x, r1.y
|
|
expr28.x = temp1.x + temp1.y;
|
|
// add r1.x, r0.x, (4.125)
|
|
temp1.x = temp0.x + (4.125);
|
|
// add r1.y, r0.x, (4.8125)
|
|
temp1.y = temp0.x + (4.8125);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// mul r1.x, r0.x, (16)
|
|
temp1.x = temp0.x * (16);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// neg r1.z, r0.x
|
|
temp1.z = -temp0.x;
|
|
// add c29.x, r1.x, r1.z
|
|
expr29.x = temp1.x + temp1.z;
|
|
// frc r0.x, r1.y
|
|
temp0.x = frac(temp1.y);
|
|
// mul r1.x, r0.x, (16)
|
|
temp1.x = temp0.x * (16);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// neg r1.y, r0.x
|
|
temp1.y = -temp0.x;
|
|
// add c30.x, r1.x, r1.y
|
|
expr30.x = temp1.x + temp1.y;
|
|
// mul r0.x, c0.x, (1.875)
|
|
temp0.x = Time.x * (1.875);
|
|
// add r1.x, r0.x, (3.4375)
|
|
temp1.x = temp0.x + (3.4375);
|
|
// frc r0.y, r1.x
|
|
temp0.y = frac(temp1.x);
|
|
// mul r1.x, r0.y, (16)
|
|
temp1.x = temp0.y * (16);
|
|
// frc r0.y, r1.x
|
|
temp0.y = frac(temp1.x);
|
|
// neg r1.y, r0.y
|
|
temp1.y = -temp0.y;
|
|
// add c31.x, r1.x, r1.y
|
|
expr31.x = temp1.x + temp1.y;
|
|
// add r1.x, r0.x, (4.125)
|
|
temp1.x = temp0.x + (4.125);
|
|
// add r1.y, r0.x, (4.8125)
|
|
temp1.y = temp0.x + (4.8125);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// mul r1.x, r0.x, (16)
|
|
temp1.x = temp0.x * (16);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// neg r1.z, r0.x
|
|
temp1.z = -temp0.x;
|
|
// add c32.x, r1.x, r1.z
|
|
expr32.x = temp1.x + temp1.z;
|
|
// frc r0.x, r1.y
|
|
temp0.x = frac(temp1.y);
|
|
// mul r1.x, r0.x, (16)
|
|
temp1.x = temp0.x * (16);
|
|
// frc r0.x, r1.x
|
|
temp0.x = frac(temp1.x);
|
|
// neg r1.y, r0.x
|
|
temp1.y = -temp0.x;
|
|
// add c33.x, r1.x, r1.y
|
|
expr33.x = temp1.x + temp1.y;
|
|
}
|
|
|
|
Textured_VertexShader2_Output o;
|
|
float4 addr0;
|
|
float4 temp0;
|
|
// def c27, -1, 1, 0.25, 0
|
|
// def c11, 0.957897, 0.3788705, 0.3635719, 0.3287609
|
|
// def c12, 0.1762373, 0.9145751, 0.4360935, 0.3476284
|
|
// def c13, 0.743219, 0.4425611, 0.9974546, 0.3622138
|
|
// def c14, 0.4896626, 0.6664233, 0.8305699, 0.9742577
|
|
// def c15, 0.8947675, 0.8236215, 0.9309705, 0.05219847
|
|
// def c16, 0.1411007, 0.6527002, 0.008452523, 0.6430574
|
|
// def c17, 0.229799, 0.897999, 0.753822, 0.1316504
|
|
// def c18, 0.5815384, 0.2836916, 0.09156471, 0.407481
|
|
// def c19, 0.2706044, 0.7228181, 0.1694367, 0.1469052
|
|
// def c20, 0.5995556, 0.0964533, 0.8763983, 0.1172229
|
|
// def c21, 0.5101711, 0.9421572, 0.1957888, 0.9167565
|
|
// def c22, 0.03546793, 0.5340094, 0.1673218, 0.5576764
|
|
// def c23, 0.861564, 0.2251601, 0.082332, 0.8790039
|
|
// def c24, 0.1730866, 0.8935188, 0.01392406, 0.1787381
|
|
// def c25, 0.8269383, 0.7718143, 0.4395359, 0.493963
|
|
// def c26, 0.5423613, 0.7218617, 0.7697314, 0.5878567
|
|
// dcl_position v0
|
|
// dcl_texcoord v1
|
|
// dcl_color v2
|
|
// mova a0.w, c28.x
|
|
addr0.w = expr28.x;
|
|
// add r0.x, v0.x, c11[a0.w].x
|
|
temp0.x = i.position.x + float1(0.957897);
|
|
// mova a0.w, c29.x
|
|
addr0.w = expr29.x;
|
|
// add r0.y, v0.y, c11[a0.w].x
|
|
temp0.y = i.position.y + float1(0.957897);
|
|
// mova a0.w, c30.x
|
|
addr0.w = expr30.x;
|
|
// add r0.z, v0.z, c11[a0.w].x
|
|
temp0.z = i.position.z + float1(0.957897);
|
|
// add r0.xyz, r0, c27.x
|
|
temp0.xyz = temp0.xyz + float3(-1, -1, -1);
|
|
// mov r0.w, c27.y
|
|
temp0.w = float1(1);
|
|
// dp4 oPos.x, r0, c34
|
|
o.position.x = dot(temp0, (WorldViewProjection._m00_m10_m20_m30));
|
|
// dp4 oPos.y, r0, c35
|
|
o.position.y = dot(temp0, (WorldViewProjection._m01_m11_m21_m31));
|
|
// dp4 oPos.z, r0, c36
|
|
o.position.z = dot(temp0, (WorldViewProjection._m02_m12_m22_m32));
|
|
// dp4 oPos.w, r0, c37
|
|
o.position.w = dot(temp0, (WorldViewProjection._m03_m13_m23_m33));
|
|
// mov r0.z, c27.z
|
|
temp0.z = float1(0.25);
|
|
// mova a0.w, c31.x
|
|
addr0.w = expr31.x;
|
|
// mad oD0.x, v2.x, c11[a0.w].x, r0.z
|
|
o.color.x = i.color.x * float1(0.957897) + temp0.z;
|
|
// mova a0.w, c32.x
|
|
addr0.w = expr32.x;
|
|
// mad oD0.y, v2.y, c11[a0.w].x, r0.z
|
|
o.color.y = i.color.y * float1(0.957897) + temp0.z;
|
|
// mova a0.w, c33.x
|
|
addr0.w = expr33.x;
|
|
// mad oD0.z, v2.z, c11[a0.w].x, r0.z
|
|
o.color.z = i.color.z * float1(0.957897) + temp0.z;
|
|
// mov oD0.w, c1.x
|
|
o.color.w = OpacityOverride.x;
|
|
// mov oT0.xy, v1
|
|
o.texcoord = i.texcoord;
|
|
//
|
|
|
|
return o;
|
|
}
|
|
|
|
// DynamicParameter_PixelShader3 Pixel_2_0 Has PRES False
|
|
float4 DynamicParameter_PixelShader3() : COLOR
|
|
{
|
|
float4 out_color;
|
|
// def c0, 1, 0, 0, 1
|
|
// mov oC0, c0
|
|
out_color = float4(1, 0, 0, 1);
|
|
//
|
|
|
|
return out_color;
|
|
}
|
|
|
|
// DynamicParameter_VertexShader4 Vertex_2_0 Has PRES False
|
|
float4 DynamicParameter_VertexShader4(float4 position : POSITION) : POSITION
|
|
{
|
|
float4 out_position;
|
|
float4 temp0;
|
|
// def c0, 1, 0, 0, 0
|
|
// dcl_position v0
|
|
// mad r0, v0.xyzx, c0.xxxy, c0.yyyx
|
|
temp0 = position.xyzx * float4(1, 1, 1, 0) + float4(0, 0, 0, 1);
|
|
// dp4 oPos.x, r0, c11
|
|
out_position.x = dot(temp0, (WorldViewProjection._m00_m10_m20_m30));
|
|
// dp4 oPos.y, r0, c12
|
|
out_position.y = dot(temp0, (WorldViewProjection._m01_m11_m21_m31));
|
|
// dp4 oPos.z, r0, c13
|
|
out_position.z = dot(temp0, (WorldViewProjection._m02_m12_m22_m32));
|
|
// dp4 oPos.w, r0, c14
|
|
out_position.w = dot(temp0, (WorldViewProjection._m03_m13_m23_m33));
|
|
//
|
|
|
|
return out_position;
|
|
}
|
|
|
|
// Simplest_PixelShader5 Pixel_2_0 Has PRES False
|
|
float4 Simplest_PixelShader5() : COLOR
|
|
{
|
|
float4 out_color;
|
|
// def c0, 1, 0, 0, 1
|
|
// mov oC0, c0
|
|
out_color = float4(1, 0, 0, 1);
|
|
//
|
|
|
|
return out_color;
|
|
}
|
|
|
|
// Simplest_VertexShader6 Vertex_2_0 Has PRES False
|
|
float4 Simplest_VertexShader6(float4 position : POSITION) : POSITION
|
|
{
|
|
float4 out_position;
|
|
float4 temp0;
|
|
// def c0, 1, 0, 0, 0
|
|
// dcl_position v0
|
|
// mad r0, v0.xyzx, c0.xxxy, c0.yyyx
|
|
temp0 = position.xyzx * float4(1, 1, 1, 0) + float4(0, 0, 0, 1);
|
|
// dp4 oPos.x, r0, c11
|
|
out_position.x = dot(temp0, (WorldViewProjection._m00_m10_m20_m30));
|
|
// dp4 oPos.y, r0, c12
|
|
out_position.y = dot(temp0, (WorldViewProjection._m01_m11_m21_m31));
|
|
// dp4 oPos.z, r0, c13
|
|
out_position.z = dot(temp0, (WorldViewProjection._m02_m12_m22_m32));
|
|
// dp4 oPos.w, r0, c14
|
|
out_position.w = dot(temp0, (WorldViewProjection._m03_m13_m23_m33));
|
|
//
|
|
|
|
return out_position;
|
|
}
|
|
|
|
technique Simplest
|
|
{
|
|
pass P0
|
|
{
|
|
VertexShader = compile vs_2_0 Simplest_VertexShader6(); // 18
|
|
PixelShader = compile ps_2_0 Simplest_PixelShader5(); // 19
|
|
ZEnable = 0;
|
|
ZWriteEnable = 0;
|
|
CullMode = 1;
|
|
AlphaBlendEnable = 0;
|
|
ColorWriteEnable = 15;
|
|
AlphaTestEnable = 0;
|
|
}
|
|
}
|
|
|
|
technique DynamicParameter
|
|
{
|
|
pass P0
|
|
{
|
|
VertexShader = compile vs_2_0 DynamicParameter_VertexShader4(); // 20
|
|
PixelShader = compile ps_2_0 DynamicParameter_PixelShader3(); // 21
|
|
ZEnable = 0;
|
|
ZWriteEnable = 0;
|
|
CullMode = 1;
|
|
AlphaBlendEnable = 0;
|
|
ColorWriteEnable = 15;
|
|
AlphaTestEnable = 0;
|
|
}
|
|
}
|
|
|
|
technique Textured
|
|
{
|
|
pass P0
|
|
{
|
|
VertexShader = compile vs_2_0 Textured_VertexShader2(); // 22
|
|
PixelShader = compile ps_2_0 Textured_PixelShader1(); // 23
|
|
ZEnable = 1;
|
|
ZWriteEnable = 0;
|
|
CullMode = 1;
|
|
SrcBlend = 5;
|
|
DestBlend = 6;
|
|
AlphaBlendEnable = 1;
|
|
ColorWriteEnable = 15;
|
|
AlphaTestEnable = 0;
|
|
}
|
|
}
|
|
|