GithubHelp home page GithubHelp logo

Comments (4)

Seneral avatar Seneral commented on July 2, 2024

It's probably because of the saving system. I really have to write something up for the documentation on this topic.
It most probably happens because your references get lost when the save system clones and replaces the nodes. There is an interface consisiting of two methods in Node.cs that would be able to fix this, but first off, you may be able to avoid that all together!
So in the childNodes list, you store every connected node. Why not just access the connected inputs from the output directly? You could also make this a property accessing the output connections instead for simplicity...
For example:
Outputs[0].connections
So you don't need to take care of updating this list.

Also, pro tip: If you want the tree to be top->bottom, you can change the orientation of each knob in the Node constructor by a simple overloaded knob constructor;)

from node_editor_framework.

koniu699 avatar koniu699 commented on July 2, 2024

I've overcome the problem using similar solution You provided :P I simply get all nodes directly from Outputs[0].connections
Still in my opinion it's a bit counter intuitive to write that method, since in framework You can calculate the values every time you do something in the tree.

Thanks for the pro tip :D I was going to do that in first iteration, yet it took me some time to fix my issue, so I will probably make the change next iteration.

from node_editor_framework.

Seneral avatar Seneral commented on July 2, 2024

So, has this been resolved for you?
Sorry for not checking in for so long...

from node_editor_framework.

koniu699 avatar koniu699 commented on July 2, 2024

As I said, I access all connections of each node and then store references gathered from there. It's a simple fix and it works fine.

from node_editor_framework.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.