Without going into a rant, let me be blunt: Unreal Engine 4’s Reference/Dependency system is horrible.
Redirectors work… sometimes… when they fail, it completely breaks your project in a way that is unrecoverable in some cases.
Moving folders/files work… sometimes… when it fails it leads to duplicated assets and broken references(see above), and if not caught can screw up source control.
Deleting assets works…sometimes… when it fails the problems are pretty much the same as when you move folders/files.
Fixupredirector works… sometimes… when it fails it fails spectacularly.
Bottom Line: The Engine should not actively prevent asset management/cleanup/maintanence. Currently, that is exactly what it does.
The solution is so obvious that it has probably been overlooked, and it comes in the form of a simple text file.
- Keep your redirect system.
- On top of this redirect system, have a simple assetregistry.txt file. In this file, keep two sections of data: current state and pending changes. When files are moved/copied/deleted/etc, add an entry to the pending changes. When the engine is shut down (or at start up if that works better), and pending changes are migrated to the current state, redirectors are deleted, any klingon files/folders are deleted, and the pending changes section is cleaned out. Any changes that couldn’t take place for whatever reason remain in the pending changes section and raise a flag when the engine loads.
- Add a rereference script/command/menu button that reads loads the file into memory, then checks through every single file in the project and fixes any missing/invalid references.
It’s human readable. If the engine screws it up humans can fix it without losing massive amounts of time.
Migrating/importing between projects with different project file structures becomes easier to manage.
Users regain control of their file system.