Struct Problems After Altering Variables

I’m encountering some issues with Structs and making changes after they’ve been utilized in BPs. The Structs I’ve changed have not had any variables removed that were used, just unused ones or adding new variables. Is this possible to do without it being a nightmare?

Every time I load my project now, I receive messages like “Failed to load “…S_XXX.S_XXX” Referenced by XYZ”. The structs I’ve changed are saved and error free, with the checkmark next to +Add Variable that says “good to go” in the hover tooltip.

The blueprints that allegedly failed to load the structs are also compiling and functioning fine as far as I can tell. All the nodes are properly connected and the added struct variables are not interfering in any way. Does this mean the error is a false alarm? Is there a way to resolve the error besides flat out remaking my blueprints from scratch?

Also, will this result in problems later on when attempting to package my project?

Thank you for your time and help!

try checking the locations where the struct is used. I’ve noticed that if you change the base struct, the content where these structs are used gets reset. The content vanishes.

I’ve checked. Fortunately, all of the nodes and content are still there along with anything related to the struct supposedly having issues. Compiles like normal. It’s very weird. I’ve even gone so far as to delete the entire functions utilizing the struct and remaking them from scratch. As soon as I use the struct again, the error reappears on opening the project.



1 Like

maybe try to delete all the intermediary files and the rest the engine create for the project? there are some folders that can be deleted which will then be recreated when opening the project. I don’t want to create issues as I don’t know exactly which one can be deleted or not. Do some research, make a backup of the game, archive the entire thing if is not too big. Then delete those folders

I’ll definitely look into this. Think I’ll also try to package the game and see if it suddenly has issues that weren’t appearing in the editor window when testing. Thank you.

For the future, is there some way to alter structs that are in use without problems? Or are you typically supposed to leave structs alone after they’ve been made and used in your project?

No luck on deleting all the intermediary files. I backed up, and went so far as to delete every single folder besides content and the .uproject file. Deleted the “Developers” folder inside my content folder too. Opened with the .uproject, had it rebuild all the other project files/folders. Still having the same error pop up :frowning:

I’ve had an issue with a data asset which I’ve renamed or maybe moved to a different folder. All worked fine in the editor, but it didn’t want to package the project. Always failed because he was not able to find that data asset.

In the end I’ve create a new data asset, recreated the variables identically, then I’ve replaced everything where was used. Fortunately there were few of these places because I’m doing some test and i don’t have a lot of data.

Then it builded correctly.

This is just very weird. I can’t imagine I’m the first person ever to make changes to a struct down the line in a project. Feels like a very reasonable thing to want to do as your project evolves.

Looks like I’m in the same spot. Tried to build and package. It couldn’t find the struct despite me trying everything I could think of to resolve the problem… Lots of wasted days and going to take a lot more to fix given how widely used my two structs were (iteminfo and slotinfo so you can imagine it’s in everything)… Unfortunate.

Note to anyone who ever reads: Don’t move or alter your structs once made and used in blueprints. It will cause you nightmares to fix. Add variables to the struct from the start that you may never even use in the end, because going back to add them can break things.

I’ve used that solution because I’ve had like 5 locations to update. It made more sense to just remake everything instead of finding a real solution

1 Like