Announcement

Collapse
No announcement yet.

CoreRedirects to migrate blueprints from project to plugin

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    CoreRedirects to migrate blueprints from project to plugin

    I know there are some questions about CoreRedirects, but no one has solve my problem and I worried about:

    I'm trying to migrate some code from a C++ project to a Plugin development project, the code is migrated properly, but when I try to migrate the blueprint classes childs of my C++ code, that classes are broken because has no parent class reference, so I have to use CoreRedirects to point them to the right class in the plugin code.

    I have tried a lot of combinations of CoreRedirects paths and I have tried also to set those redirects in the project DefaultEngine.ini and in myPlugin.ini, but nothing seems to solve the issue.

    I'm not sure if the problem is even solvable, so please, help me because rewrite all the blueprints is unafordable.

    #2
    Should be working, if class path syntax is correct. Check if you are linking new modules from plugin, try to create blueprint from classes of plugin modules.

    Comment


      #3
      Yeah, that's was one of my first attempts, and it works.

      Digging in the source code I realized that my plugin needs to be in "LoadingPhase": "PreDefault" to read the .ini, if not, it is ignored, but still not working.

      Comment


        #4
        A little update, I have made it works with my test class, but not with the main code, so I have to keep trying.

        To make it works, I mandatory have to add /Script/OldModule. to the ClassName as shown:
        Code:
        //I was trying
        +ClassRedirects=(OldName="MyActor",NewName="/Script/PluginModule.MyPluginActor",MatchSubstring=True)
        //And it works as:
        +ClassRedirects=(OldName="/Script/OldProjectModule.MyActor",NewName="/Script/PluginModule.MyPluginActor",MatchSubstring=True)
        It is supposed to work in a similar way, but I don't understand why not.

        In addition I have try it with a test class created in the same project and with a test class created in other project and migrated, it works with both.

        Comment


          #5
          LAST UPDATE

          I have to say that finally it works and also I have to recognize that the solution is quite embarrasing, debugging why it wasn't working I realize that some errors says "can't find file /Script/SpacesVRVR" when applying the following redirect:
          Code:
          +ClassRedirects=(OldName="/Script/Spaces.MyActor",NewName="/Script/SpacesVR.MyPluginActor",MatchSubstring=True)
          So I've decided to clone the original project changing the module name to TestSpaces instead of Spaces and migrate and redirect from this new module:
          Code:
          +ClassRedirects=(OldName="/Script/TestSpaces.MyActor",NewName="/Script/SpacesVR.MyPluginActor",MatchSubstring=True)
          And it solves the problems, letting me to resave all the blueprints and remove the redirects.

          Comment

          Working...
          X