Unity3.0 Surface shader

hi,

I’m trying to convert a Unity2.6 shader to Unity3.0beta Surface Shader. The Unity2.6 shader renders black in Unity3.0. The main pixel shader has converted and works as expected but my issue is that I need to modify the vertex shader vertex position. Is this possible? My attempts so far result in the shader not compiling. adding
#pragma vertex vert
void vert (inout appdata_full v)
{
}
gets me close, if finds the ‘vert’ function apparently. but still produces errors. “Program ‘surf’ syntax error, unexpected reserved word “float””
The old 2.6 way of adding
vertex2Frag vert(appdata_full v)
{
}
Complains “Surface shader vertex function ‘vert’ not found”

Thanks

well further to this problem

void vert(inout appdata_full v)
{
}

now compiles?? I cant see I changed anything but the last was a syntax error? maybe it was something I did.

The following does not compile though? again it appears to be syntax related, but

void vert(inout appdata_full v)
{
appdata_full.vertex.xyz += half3(1,1,1);
}

anyhow I’m not sure I’m on the right lines.

Any one spot anything obvious? I’m pressuming I can modify appdata_full?

Thanks

Well yes it was something obvious
try
void vert(inout appdata_full v)
{
v.vertex.xyz += half3(1,1,1);
}

Doh! school boy error.

thanks for listening, I’ll go and have a rest now