浏览代码

Update shader error message

/main
Peter Bay Bastian 7 年前
当前提交
ea126eba
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 2
      MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/PreviewManager.cs

2
MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/PreviewManager.cs


{
var errors = MaterialGraphAsset.GetShaderErrors(m_UberShader);
var message = new ShaderStringBuilder();
message.AppendLine("Uber shader has {0} error{1}:", errors.Length, errors.Length != 1 ? "s" : "");
message.AppendLine(@"Preview shader for graph has {0} error{1}:", errors.Length, errors.Length != 1 ? "s" : "");
foreach (var error in errors)
{
message.AppendLine("{0} at line {1} (on {2})", error.message, error.line, error.platform);

正在加载...
取消
保存