So I have a couple of custom actor components in my project, they work as intended without errors, and have no issue adding them or removing them or anything like that.
However, every time I open the editor, all of the actors in the level, and all of the blueprint actors have all of the custom components removed completely, I can still find them in the content drawer, but they aren’t on the objects any more. Nothing else seems to reset or change, other than these components being removed. (Screenshots below)
There’s been a couple of similar issues on this and other forums, with the three solutions that I can find being to turn off live coding, build in my IDE after closing the editor, and to edit the loading phase in the .UProject. But none of these solutions have worked for me, even in combination, with the last solution not even allowing the project to open.
I’m primarily a Unity Dev and have only started using Unreal over the last couple of weeks so it’s possible that it’s something simple that I’ve missed, but I have a few friends who work with Unreal, none of whom have been able to find a solution yet.
Any help is appreciated thanks!
An actor in scene with the component added
A blueprint with the same component added, both of these are compiled and saved with no errors.
The same actor and blueprint after closing the editor and reopening through VS2022
This doesn’t actually work but I’m leaving it up to keep track
So with the help of a friend helping me troubleshoot I found that the issue was in fact the live coding. However, what all of the other questions and solutions didn’t mention (and why I initially thought that it wasn’t the problem) is that the problem isn’t anything to do with having live coding on while adding the component or making any changes, but instead it needs to be off when the class is initially created.
So what worked for me was copying the classes I had into new ones made with live coding turned off.
Syke, it was actually that I had put the classes into folders, for some reason even if the editor recognises the classes in their folders in the content browser, they are removed even with the solution I posted earlier. I’ll keep updating if I find a way to get it to work with the folders.
Update, just got folders to work if I mark the class as public or private when generating it, then continuing as before, you also need live coding off when you make the class. Finally it seems that any names of files that you’ve had this problem with won’t work anymore.
If anyone has a way to allow this to work so that I can use the broken file names again it would be appreciated, the names that have been blocked off for me are reasonably important