Exemple #1
0
 public void Parse(ref string[] program)
 {
     _DistanceFunction = ParseUtils.GetToken(ref program);
     if (WooScript.IsShader(_DistanceFunction))
     {
         _ShaderMode = true;
     }
     else
     {
         _ShaderMode = false;
     }
 }
Exemple #2
0
        public void Parse(ref string[] program)
        {
            string token = ParseUtils.GetToken(ref program);

            if (token.Length > 0)
            {
                _MaterialFunction = token;
                if (!WooScript.IsShader(_MaterialFunction))
                {
                    throw new ParseException("materialfunction call expected a shader, sadly " + _MaterialFunction + " isn't one...");
                }
            }
            else
            {
                _MaterialFunction = "";
            }
        }