Wouterdek/NodeNetwork

Problem with Custom Input Editor

SawmillTurtle opened this issue · 0 comments

Have been attempting to follow your tutorials. Got as far as Custom Input Editors. I exactly as specified, going so far as to copy every block of sample code verbatim using cut and paste. I received an error when attempting to add the node to the network that reads as follows:

Error CS0411 The type arguments for method 'SourceListEditConvenienceEx.Add(ISourceList, T)' cannot be inferred from the usage. Try specifying the type arguments explicitly. NodeNetworkTestApp

I have approached it from every angle, even going so far as to implement it using the same method you used in the Shader example project, by adding it to a custom MainViewModel class that inherits from ReactiveObject. Even using this method, I received the same error. I'm not sure if this is a bug or what. I don't understand why this works for you and not for me. I have tried everything from casting (which generated more errors), to providing the type as

network.Nodes.Add<StringValueEditorViewModel>(new StringValueEditorViewModel())

and even

network.Nodes.Add<string>(new StringValueEditorViewModel())

and all of these created more errors. I'm not sure what else I can try after copying the code verbatim and using the same type of custom ReactiveObject class you used.

Is this a bug or am I overlooking something?

UPDATE: Not a bug. Solved the problem on my own. It was entirely my fault. Please accept my apologies.