When refactoring old complicated shader graph I’m adding reroutes a lot (it’s great for readability). It’s repetitive process - adding reroute, rewiring old connections to reroute instance (not to declaration) and maybe making a separate reroute instance for each connection for more readability.
If any parts of this process could be automated - it would make a life a bit easier for sure.
Try removing all files under “NodeGraphAssistant\Source\Private\EngineCppFiles” and compile again,also make sure you have all engine cpp file on your computer.
Since it’s not possible to have both Electronic Nodes and Node Graph Assistant enabled at the same time, could you please add a 45 degree wire style and a Left/Middle/Right option so we can choose what end of the wire the bend takes place?
I too would like this. It’s unfortunate that Electronic Nodes and NGA are incompatible with each other, but the features of NGA has helped out a lot. But EN’s Subway 45 degree wiring style makes blueprints both much more visually pleasing but also way easier to read. I’m not a fan of the current wiring styles NGA provides, so I would love it if a similar style came to NGA
I’m running into an annoying issue in 5.1 with the plugin. Worked great in 4.26 in my main project, but when I upgraded to 5.1 I found that now nodes with multiple inputs, like a multiplication math node, for example, will now automatically connect the second input to whatever the first input is connected to. This is incredibly annoying when I’m working with a tight space and using math nodes with hard coded numbers. Every time I accidentally drag it too close to the node it’s already connected to, it tries to snap the node into both outputs.
I was wondering if there’s an option to turn this off, an update to modify it or add such an option coming eventually, or if this is now the intended behavior and I should just get used to it.
Here are two links to two different gifs that show the new behavior vs the old behavior:
Try to decrease the auto connect radius in Editor Preferences:
This is not a viable solution as it impacts all auto connect behavior. The bug isn’t a distance-based one; the plugin should not try to connect already connected pins.
In the gif they are not connected, it’s just a value, if you want to avoid that use “make literal float” instead of using a value. Decreasing the snap distance worked for me, I’ve never had an issue since I changed that option
Oh, I didn’t realize you were pointing at that! Thank you for explaining that!
IMHO it would be easier (to implement) not to connect a pin if the value is not the default one (For example if I set a multiply node to 2, I don’t want to be replaced by connecting another value, especially in UE5 where you can plug several types of variables in math nothes)
I suppose that would be a viable solution. Perhaps something changed in how Unreal handles connections, but the desired functionality was working just fine in previous versions. Auto connect is extremely frustrating now thanks to this double snapping.
EDIT: I just wanted to point out that for some reason my second gif has a long delay at the start that I didn’t notice when originally posting. If you give it 3 or so seconds you’ll see the behavior I’m concerned about compared to it not happening in the first link from 4.26
For example, the blueprint creates five static model components, and then drag it to the time icon, hit a node that hides the static model, and then select the five static model components and hidden models, and press Alt+C to link only one at a time, previously it was possible to link on the five by clicking on them
I was able to fix the auto connect issue with 2 lines of code, at least to get the behavior I personally want (which is “don’t ever attempt to connect any pins that already have a connection”)
Here is a perfect example of why the above desired behavior is sane: Imgur: The magic of the Internet. There are many times where BP formatting/cleaning simply just prevents the nodes from being spaced too close. The “radius” setting can prevent this, but it’s just a workaround. At a minimum, I believe the proposed change below should be at least a setting if not just built in.
Before: Imgur: The magic of the Internet (I’m not sure why I can’t reproduce the specific example by Azaii (maybe there was an engine update), but, you can see the variable is still trying to attach to the empty For Loop pin despite First Index is connected.
After: Imgur: The magic of the Internet
Here is the diff:
diff NodeHelper.cpp.old NodeHelper.cpp
65c65
<
---
>
1104c1104
< if (DirtyPins.Contains(sourceNodePin))
---
> if (DirtyPins.Contains(sourceNodePin) || sourceNodePin->IsConnected())
1137c1137
< if (DirtyPins.Contains(targetNodePin))
---
> if (DirtyPins.Contains(targetNodePin) || targetNodePin->IsConnected())
I finally decided to follow your advice and add it to the settings (Because sometimes I need it and sometimes it’s annoying…)
For anyone interested, here’s the code:
Add a variable in NodeGraphAssistantConfig.h
/** If true, allow automatic node connection even if a wire is already connected */
UPROPERTY(EditAnywhere, config, Category = Features)
bool AutoConnectIfAlreadyConnected = true;
Replace if (DirtyPins.Contains(sourceNodePin)) in NodeHelper.cpp
if (GetDefault<UNodeGraphAssistantConfig>()->AutoConnectIfAlreadyConnected)
{
if (DirtyPins.Contains(sourceNodePin))
{
continue;
}
}
else
{
if((DirtyPins.Contains(sourceNodePin) || sourceNodePin->IsConnected()))
{
continue;
}
}
Replace if (DirtyPins.Contains(targetNodePin)) in NodeHelper.cpp
if (GetDefault<UNodeGraphAssistantConfig>()->AutoConnectIfAlreadyConnected)
{
if (DirtyPins.Contains(targetNodePin))
{
continue;
}
}
else
{
if((DirtyPins.Contains(targetNodePin) || targetNodePin->IsConnected()))
{
continue;
}
}