Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local graphs backtrack #16

Open
MephestoKhaan opened this issue Apr 6, 2020 · 6 comments
Open

Local graphs backtrack #16

MephestoKhaan opened this issue Apr 6, 2020 · 6 comments

Comments

@MephestoKhaan
Copy link
Owner

Allow localgraphs to not only show events leaving the target, but arriving to it.

@thestonefox
Copy link

thestonefox commented Apr 14, 2020

Is this the concept of you can select a GameObject in the Unity hierarchy and for a component on there it will show what events are calling methods on that component?

I (think) it's not possible to start from that component and go upstream via code, but if you have a map of the downstream already then you can use that map to do that upstream lookup.

if this issue is related to the feature I outlined then that would be so useful! Because there's no real way of doing this in the Unity inspector.

You can start at a component and keep clicking on the event listeners to follow the flow downstream but you can't start on a component and see what event listeners are calling methods on that component.

@MephestoKhaan
Copy link
Owner Author

Correct! going upstream is the goal here.
I do have the map, huge on VRTK for example but the "price" comes from painting it entirely really. So it should be achievable to do a search on what nodes are calling the selected GO.

@thestonefox
Copy link

That would be so useful for VRTK. The amount of times i know where I end up but I wanna see how I got there

@MephestoKhaan
Copy link
Owner Author

MephestoKhaan commented Apr 19, 2020

Some progress!!
https://gyazo.com/bf171458811555edb0935184c314874e

So, searching all events in the scene (28k events) take like 30 seconds, but you really need to do that "once" unless you change the hierarchy.

Then showing ALL events is pretty much impossible (and unusable) but searching in the cached set for the ones around (sending or receiving calls) is very fast. So you can traverse the tree up and down.

I will make it a bit more usable (adding the new boxes but not removing the old ones so it keeps thing in place) plus adding some more interesting menus and hopefully upload it next week or so

Not how the "random" colours of the edges kept unaltered

@MephestoKhaan
Copy link
Owner Author

Thinking about how to do this, probably the buttons will change to:

"Cache all events" <== mark as dirty when hierarchy changes, add a loader
"Refresh" <=== updates for when changing maybe links but not necesarily the hierarchy (or play/stop)
"Add self" <=== adds all events coming and going from the selected GO
"Add hierarchy" <==== same as above but for the whole hierarchy (really needed?)
"Remove node" <==== removes them from the graph

@thestonefox
Copy link

Being able to jump back up through the possible events that called your method will be so useful for vrtk debugging!

MephestoKhaan added a commit that referenced this issue Jun 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants