The point of making it a parameter is to allow that node value to be updated at runtime by Haxe or nodes. I think it has to compile the shader differently to allow for that, so that is why it needs the checkbox.
The Name of the material parameter node is then used used to change the value of the parameter through logic nodes.
It helps to think about what Armory is doing “behind the scenes.” Your game turns into a Haxe program. The logic-nodes are a visual way to construct that programming … letting Armory do most of the work of building a program in a language that’s probably not familiar to you (if you have any experience in writing computer source-code at all, which you might or might not). The “core” of Armory – also written in Haxe – runs the show, invoking the game-specific logic that you’ve specified, using either logic-nodes or Haxe source code that you’ve written yourself to specify it.
Haxe then magically turns that source-code into whatever-it-is that actually runs on your target(s), using the native tools associated with that target as necessary.
Did you only copy the node tree at the bottom of @zicklag’s post, or did you also select the RGB node, name it “RGB” in the node properties and tick the “Parameter” checkbox in “Armory Material Node”? The last parts are necessary for the logic nodes to be able to access the RGB material node.
I did not copy anything - as I understand the concept, I recreate it. And yes I have that checks needed. The object and material is returned, but as I have multiple ones assigned to object, I only get first
Maybe it’s 0.5 incomplete feature?
There’s a trait “MyTrait” but I do not see that it’s bound to any object. Can anybody tell me why this trait is working anyway?
When having a look the logic node editor, I see “Armory Material Node”. But it’s empty. Is this supposed to be like that (got latest SDK today)? What’s the use of this? How can I make a parameter out it?!
In general, I do not understand how this script works. What’s iron.object.Uniforms and what is it used for?
Any help or links to help are greatly appreciated.