On top of the exposed graph vars it mentions that the graph itself won’t change serialization but setting a graph var override on the object also changes the value in the graph itself. Hence the override is not so much an override anymore. An override on one object will reflect the changed value on all objects that have the same graph both within the graph and on the exposed graph vars that’re not set as an override.
myBool is False and myGameObject is null on both my objects – GameObject 1 and GameObject 2:
Changing these values as overrides also reflects that change in the graph and on other objects that have the same graph:
Shouldn’t an override only affect the object in question?
I really hope this bug can be fixed, it’s an excellent alternative to using c# class variables with instance overrides, and makes Flowcanvas a real viable alternative to Bolt 2 in it’s current state (since Bolt 1 has no such way of handling variables).
Here’s another example of them, when a var is overridden, it stays, but when it isn’t, the most recently override change seems to affect the graph variable, and therefore any non-overridden variables: https://streamable.com/kcjnn8
I can cofirm that there is a bug with asset graphs and prefabs, but please note that this is only a visual (GUI) bug. It will work correctly in runtime. So for example, if you have two prefab instances in the scene and you override an exposed variables in those prefab instance with different values, even though in editor the “grey out” exposed variable in the Graph Editor Blackboard will be shown wrong, as soon as you enter playmode, the correct variable override values that you set in the FlowScriptController inspector will be set and be used.
The “grey out” value displayed in the graph editor is only there for reference, however due to a bug indeed, that reference is shown wrong GUI-wise only, so it becomes confusion and this I have to fix it!, but once again, please note that it will work correctly in playmode. Please let me know if that is indeed the case for you too. You can check this out with a Debug Log Value node for example.
@Gavalakis the method of using these looks like an almost perfect workaround to c#-style class variables, unfortunately they can’t be accessed from other gameobjects :'( Is there any way that graph variables could be somehow publicly exposed, retain their defaults and overrides and also be accessed from other gameobjects, thereby giving an a perfect substitute for Bolt 2’s class-like variable structure?
“Exposed Public” graph variable can be accessed from outside, but right now this is possible only through code, via the ‘GetExposedParameterValue” and “SetExposedParameterValue” respectively, found on GraphOwner class (as well as FlowscriptController since it derives from GraphOwner).
I suspect though that you are after a way to get/set those exposed parameters with some flowscript node? If so I will have to take a look at this 🙂
Hello again “Exposed Public” graph variable can be accessed from outside, but right now this is possible only through code, via the ‘GetExposedParameterValue” and “SetExposedParameterValue” respectively, found on GraphOwner class (as well as FlowscriptController since it derives from GraphOwner). I suspect though that you are after a way to get/set those exposed parameters with some flowscript node? If so I will have to take a look at this Let me know. Thanks!
It would be *super* useful if exposed graph variables could be accessed as easily as gameobject variables, combined with overrides, it would make for a very useful class-style variables system, where instances and prefabs can use overrides and all of the variables can just be on the graph asset. Could this be considered?