Functions not permitted in Custom Expressions?

If I enter:
float4 getRed()
{
return float4(1,0,0,1);
}
return getRed();

I get:
[SM5] error X3000: syntax error: unexpected token '('

No, the code you inputted in custom is pasted directly to function and you can’t have function in function, you need to do some hacks with inputs to replace functions work.

In UDK i did hacks using generated code (which you could view in UE3), where you could call any function, including once that contain custom expressions, but it’s too unstable and hackish to use it with real deal project.

Ah, ok, thanks Shadowriver.
Shouldn’t be a problem to open up functions and pack the code into one complete procedure.