Is there a find and replace for variables in blueprints?

I am working on an inventory system. What I’m doing to create in the inventory system requires a very repetitive process of replacing variables with other variables, which got me wondering if there is a mode or system built into unreal engine 4 blueprints, where I can select an area of blueprints and do a find and replace. I.e.:

Find Get Variable Integer “Texture1”
Replace All Instances of Get Variable Integer “Texture1” With “Texture2”

Just curios if there is something like that! (I know that there is a find references but that’s not what I am looking for here. )

You can drag & drop variables on top of one another → this will replace them.

There’s also this:

Perhaps it’s a logical problem; while setting blueprints can be mundane, it can be often solved with setting up macros, select nodes and switches to automate the process.

There is an experimental editor feature: Replace all variable references - Feedback for Unreal Engine team - Unreal Engine Forums

Nice. This works really well for me with 4.24. It does say tab unrecognised at first but I just had to restart the editor.

1 Like

I have a similar issue where I want to replace all of the HILIGHTED variables with a specific variable type, instead of doing it one-by-one:

If there is no way to do this, that’s crazy to me, because I need unique variables of the same type that do different things.

Am I wrong, and it is possible?

For anyone interested, I figured out if you create a “dummy” Blueprint, you can fill that Blueprint with whatever code variables you plan to amend (with the surrounding code, of course), change the name there, and then copy it back into your original Blueprint. (You’ll be prompted to “create variable”.)

@Everynone , you may have figured this out by now, but I could find no one else offering such a solution.

Headache averted.

1 Like

im too lazy to do all those bools :sweat_smile:
so i use GameplayTags that represent bools and then just check if it HasTag

AURAN

Oh, buddy, I WISH I could do that, but trust me, given that the system I’m making has dozens of conditions for the most SIMPLE of tasks, this was the cleanest way I could think of (without using loops, but again, the functions are so complicated, I needed to see them to make sure I wrote them correctly).

1 Like