Hi all!
Once again, there's a shader noob who is not capable of converting his (assembler-)shaders to dx9 so that they run under A6.31
I tried my very best but didnt get it to work:
1) First one: the ffp overlay effect by ventilator:
Code:
 
texture mtlSkin1;
dword mtlSkill1;
technique vegetation
{
pass p0
{
texture[0]=<mtlSkin1>;
zWriteEnable=true;
alphaTestEnable=true;
alphaRef=<mtlSkill1>;
alphaFunc=greater;
//cullMode=none;
colorArg1[0]=Texture;
colorOp[0]=modulate2x;
colorArg2[0]=diffuse;
}
}
technique fallback
{
pass p0
{
}
}



2) Second: One of Steempipe's ffp water effects
Code:
 
matrix matWorldViewProj;
matrix matProj;
matrix matViewInv;
vector vecDiffuse;
vector vecAmbient;
vector vecSkill41;
vector vecSunDir;
vector vecLight;
vector vecSpecular;
vector vecViewDir;
texture mtlSkin1;
texture mtlSkin2;
technique makewater
{
pass p0
{
zwriteenable=true;
zenable=true;
zfunc=less;
//zbias=0.0;
ditherenable=false;
specularenable=true;
lighting=false;
specularmaterialsource=color2;
diffusematerialsource=Color1;
NormalizeNormals=false;
LocalViewer=True;
alphafunc=less;
AlphaBlendEnable=false;
alphatestenable=false;
alpharef=0x0;
SrcBlend = one;
DestBlend = zero;
blendop=add;
fillmode=solid;
fogenable=false;
cullmode=ccw;
clipping=true;
Texture[0] = <mtlSkin1>;
magFilter[0]=linear;
minFilter[0]=linear;
mipFilter[0]=linear;
AddressU[0]=wrap;
AddressV[0]=wrap;
ColorArg1[0] = Texture;
ColorOp[0] = BUMPENVMAPLUMINANCE;//colorop[0]=bumpenvmap;
ColorArg2[0] = current;
BUMPENVLSCALE[0]=0.8;
BUMPENVLOFFSET[0]=0.0;
TextureTransformFlags[0]=count2;
TexCoordIndex[0]=0;
Texture[1] = <mtlSkin2>;
magFilter[1]=linear;
minFilter[1]=linear;
mipFilter[1]=linear;
ColorArg1[1] = Texture;
ColorOp[1] = selectarg1;
TextureTransformFlags[1]=count2;
TexCoordIndex[1]=1;
colorop[2]=disable;
alphaop[2]=disable;
vertexShaderConstant[0]=<matProj>; ////////////////////////////////////////////////////////////////
vertexShaderConstant[4]=<matViewInv>;
//scroll speed
VertexShaderConstant[11]={0.0f, 0.2f, 0.0f, 0.0f};
VertexShaderConstant[12]={-0.5f, -0.5f, 0.0f, 0.0f};
//scale
VertexShaderConstant[14]={38.4f, 57.6f, 0.0f, 0.0f};
VertexShaderConstant[15]={19.2f, 28.8f, 0.0f, 0.0f};
vertexShaderConstant[16]=<vecSunDir>;
vertexShaderConstant[17]=<vecDiffuse>;
vertexShaderConstant[19]=<vecLight>;
vertexShaderConstant[18]=<vecSpecular>;
vertexShaderConstant[19]=<vecAmbient>;
//time
VertexShaderConstant[41]=<vecSkill41>;
vertexShader=
asm
{
vs.1.1
dcl_position v0
dcl_normal v3
dcl_texcoord0 v7
m4x4 oPos,v0,c0
dp3 r0.x, v3, c4
dp3 r0.y, v3, c5
dp3 r0.z, v3, c6
dp3 r0.w, r0, r0
rsq r0.w, r0.w
mul r0, r0, r0.w
dp3 r0,r0,-c16
mul r0.xyz,r0,c17
add oD0.xyz,r0,c19
mov oD1, c18
mov r0, c41.x
mul r1, r0, c12
frc r1.xy, r1
mad oT1.xy, v7.xy, c15.xy, r1.xy
mul r1, r0, c11
frc r1.xy, r1
mad oT0.xy, v7.xy, c14.xy, r1.xy
};
}
}
technique fallback
{
pass p0
{
}
}



3)Third: the ps1.3 / vs1.1 multitex shader by ventilator that can be found on the wiki:
Code:
 
texture entSkin1;
texture entSkin2;
texture entSkin3;
matrix matWorldViewProj;
matrix matWorld;
matrix matWorldView;
vector vecSunDir;
vector vecDiffuse;
vector vecAmbient;
vector vecLight;
vector vecFog;
vector vecSkill41;
technique multitexture
{
pass p
{
texture[0]=<entSkin1>; // colormap 1
texture[1]=<entSkin2>; // colormap 2
texture[2]=<entSkin3>; // blending map
magFilter[2]=linear;
minFilter[2]=linear;
mipFilter[2]=linear;
zWriteEnable=true;
vertexShaderConstant[0]=<matWorldViewProj>;
vertexShaderConstant[4]=<matWorld>;
vertexShaderConstant[8]=<matWorldView>;
vertexShaderConstant[16]=<vecSunDir>;
vertexShaderConstant[17]=<vecDiffuse>;
//vertexShaderConstant[18]=<vecAmbient>;
//vertexShaderConstant[19]=<vecLight>;
vertexShaderConstant[20]=<vecFog>;
vertexShaderConstant[64]={64.0f,64.0f,64.0f,64.0f}; // u_scale1,v_scale1,u_scale2,v_scale2
vertexShaderConstant[95]={0.0f,0.0f,0.0f,0.0f};
vertexShader=
asm
{
vs.1.1
dcl_position v0
dcl_normal v3
dcl_texcoord0 v7
m4x4 oPos,v0,c0
mul oT0.xy,v7.xy,c64.xy
mul oT1.xy,v7.xy,c64.zw
mov oT2.xy,v7.xy
m3x3 r0,v3,c4
dp3 r0.w,r0,r0
rsq r0.w,r0.w
mul r0,r0,r0.w
dp3 r0,r0,-c16
mul r0.xyz,r0,c17
add oD0.xyz,r0,c19
mov r1.w,c20.w
dp4 r0,v0,c10
add r0,r0,-c20.x
mad r0.x,-r0.x,c20.z,r1.w
max oFog.x,r0.x,c95.w
};
pixelShader=
asm
{
ps.1.3
def c0,0,0,0,1
tex t0
tex t1
tex t2
lrp r0.rgb,t2.a,t0,t1
+mov r0.a,c0
mul r0.rgb,r0,v0
};
}
}



Please... is anyone able to help me here?


Formerly known as The Matrix - ICQ 170408644 I've been here for much longer than most people think. So where's my "Expert" status?