Console outputs a handful of errors when importing, can't run game
I've just purchased Shader Forge, and was looking forward to getting to use it immediately. However, after having imported it into my project, I'm getting a handful (25, to be precise) of errors in the console which are stopping me from being able to run my game.
Shader Forge itself works fine, but there's no way for me to launch my game with these errors.
I've tried deleting the folder, reverting to the default layout and importing it again, however that does not seem to have helped.
When closing and reopening Unity, it fails to load my custom layout, and when jumping back to the default layout, all my scripts fail to load as well as the scene view.
All of the errors are similar to the following:
Assets/ShaderForge/Editor/InternalResources/Inspectors/ShaderForgeInspector.cs(96,37): error CS0120: An object reference is required to access non-static member `object.GetType()'
Assets/ShaderForge/Editor/InternalResources/Inspectors/ShaderForgeInspector.cs(97,40): error CS1061: Type `Type' does not contain a definition for `GetConstructor' and no extension method `GetConstructor' of type `Type' could be found (are you missing a using directive or an assembly reference?)
Assets/ShaderForge/Editor/InternalResources/Inspectors/ShaderForgeInspector.cs(124,197): error CS0029: Cannot implicitly convert type `System.Type' to `Type'
New errors, including the following appear after relaunching Unity:
FileNotFoundException: Could not load file or assembly 'Assembly-CSharp-Editor' or one of its dependencies. The system cannot find the file specified.
System.AppDomain.Load (System.String assemblyString, System.Security.Policy.Evidence assemblySecurity, Boolean refonly) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System/AppDomain.cs:746)
System.AppDomain.Load (System.String assemblyString) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System/AppDomain.cs:728)
(wrapper remoting-invoke-with-check) System.AppDomain:Load (string)
System.Reflection.Assembly.Load (System.String assemblyString) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Reflection/Assembly.cs:576)
ProBuilder2.Common.pb_ProGrids_Interface.GetProGridsType ()
ProBuilder2.Common.pb_ProGrids_Interface.SubscribePushToGridEvent (System.Action`1 listener)
ProBuilder2.EditorCommon.pb_Editor.HookDelegates ()
ProBuilder2.EditorCommon.pb_Editor.OnEnable ()
UnityEditorInternal.InternalEditorUtility:LoadSerializedFileAndForget(String)
UnityEditor.WindowLayout:LoadWindowLayout(String, Boolean)
I am currently not using Shader Forge as it is impossible for me to do anything whatsoever with it installed, and would very much like to know if there is a fix for this.
Answer
SF 1.26 is 5.3+ only, you'll need to reinstall the latest compatible version! Here's a clean install guide: http://acegikmo.com/shaderforge/faq/?Q=erroronnewversion#erroronnewversion
In addition, make sure you download SF through the asset store *inside Unity itself* to make sure you get the correct version
Try the full reinstall anyhow, sometimes it can break anyway. Don't forget the layout reset!
Not including the first reinstall I did after first encountering this issue, I've just tried multiple reinstalls, resetting the layout each time, as well as restarting Unity, but I'm still getting these errors no matter what I try.
That's super odd, I'm actually not sure what could be causing this :(
Just tested it on an empty project and it worked fine.
I had a feeling it might have something to do with some assets of my main project. I'll attempt to find what exactly is causing it to act up.
It could be that you have multiple custom material or shader inspectors in your project
I experimented some, and it seems iTween was causing the issue. I'm going to try again, removing just that plugin to check.
Edit: I can indeed confirm that it was iTween causing the issue. This means I'll have to rework some of my code but Shader Forge is far more important to me than that plugin.
Actually I'm an idiot and it's just one of my own scripts...
Forgive me for the bother. ^^'
could you kindly enlighten me what could be causing the issue, this does not seem like it would be coming from another script at all. since its a conversion error.
Customer support service by UserEcho
SF 1.26 is 5.3+ only, you'll need to reinstall the latest compatible version! Here's a clean install guide: http://acegikmo.com/shaderforge/faq/?Q=erroronnewversion#erroronnewversion
In addition, make sure you download SF through the asset store *inside Unity itself* to make sure you get the correct version