Hello there. I’m working on a plugin. It is finished and everything works fine. It works in editor, it launches as standalone game. Even when I package project it says “build successful”. But when I try to launch created .exe file - it crashes. It crashes no matter what settings I choose for packaging. It crashes with this error:
Are you still working within 4.8.3? If so, could you try to create a copy of your project you’re working on the plugin within and test it out in 4.9? Are you receive any other errors besides the assertion failure? Also, does this only occur when you’re trying to run the packaged game?
Please provide reproduction steps in order to bug this issue.
Yes, I tried to convert project to 4.9 and still got an error. But a little bit different:
I can’t just publicly share c++ plugin but I’ve talked previously with marketplace staff and have already sent them project (that works fine but if I package it - .exe crashes).
And yes, this occur only when I try to run packaged game. Play in editor and launch as standalone game works fine without any errors
I understand not wanting to share information from your plugin, especially since you plan on placing it within the Marketplace. With that being said, could you please upload your crash and .dmp file? They should be within your Saved folder, where your .exe resides.
Within both of your , it looks like you have an issue with USTRUCT(). Please check and see if this has been deleted, renamed or moved.
[2015.09.02-07.47.35:945][ 0]LogProperty:Error: Struct type unknown for property 'StructProperty /Game/QDSystem/UMG/ExampleHUD.ExampleHUD_C:Get_Text_Experience_Text_0.CallFunc_GetVariable_ExtVariable'; perhaps the USTRUCT() was renamed or deleted?
Once this issue is resolved, please try again. If you run into any other errors, please provide the full for review.
Thanks for providing this information. Unfortunately, we can’t look at your plugin specifically due to it being packaged. With that being said, the error that I posted is referencing a function that is trying to access a struct. With the limited information that we have, we can’t be for certain if “CallFunc_GetVariable_ExtVariable” is looking for a struct named “ExtVariable” or “ExternalVariable”.
Please look at the bottom of my screenshot again, maybe you missed it. There is that function “GetVariable” with second argument “ExtVariable” being of type “FExternalVariable”. I have only one function and one struct with such names.
Okay, I just deleted that blueprint node since it is not very important. Crash still occurs but log is different. I mean errors. How can I fix them? I guess something is wrong with how plugin gets loaded. But why it occurs only in packaged state I don’t know.
.log and .dmp:
[link text][1]
I had a quick question for you. When we were testing this, we did so with a basic plugin setup. In particular the module was configured with the type “Developer” and Loading Phase was set to “Default.” Since this is a runtime plugin, these settings were not correct. They should have been set to “Runtime” and “PreDefault” respectively, and when we changed them and packaged the project, we were able to launch the packaged project successfully. Could you please check in your .uplugin file to see if these settings are correct in your plugin?
Yes, it worked! Actually I had to repair some things in code after that and some things now are wrecked. But it doesn’t matter, now it at least launches after package. Everything else should be fixable.
Thanks!
I have a plugin in review for the marketplace, and am getting the same error. No matter if I delete/recreate the offending blueprint variables, I always get the error relating to an unknown struct for the variable, which is of a struct type defined in my plugin code.
I have set the module loading phase to ‘PreDefault’ as suggested, but this made no difference. In fact another one of my plugins has all its modules set to ‘Default’ and yet does not exhibit the error. Also, do these definitions even have any effect when the project is being built in monolithic mode (as is the default for packaged builds)?
Do you have any suggestions of where to look/debug in order to determine why the struct property has not been able to load properly?
I added your plugin to a new, clean project and tried both building and packaging the project and had no problems with the plugin. Do you see this happening yourself in a new, clean project? If so, would it be possible to get a copy of that project to look at? If that is possible, could you please [send me a PM][1] on the forums with a link to the project?
To confirm, you mean the IngameDateTime plugin - presumably you grabbed the latest version from my submission? Also just to be clear, there is no packaging error, but a crash when running a packaged build. This happens during map load, so you’d need to set one of the maps in the plugin content as your project’s game startup map.
Well anyway, I can’t really work this out. The output log and call stack attached above were from exactly that - a new, empty code project to which I added the plugin (as a project plugin, in binary form), and selected the ‘Gregorian’ map as the game startup map. That said, having rebuilt and packaged that project since, it now seems to work fine. I am not aware of having changed anything. My original test project on the other hand, continues to crash despite using the same build of the plugin.
Can you confirm that you’re using one of the included maps and the packaged version runs without issue? If I can’t reproduce this regularly in a new project I guess I’ll just move forward with the submission.
Yes, I was using your IngameDateTime plugin, and I believe the link I was given was for the latest version of the plugin. I was not initially trying with one of the included levels, but I just tried again using both of the example maps that were included in the plugin. In both cases, I was able to successfully package the project and launch it from the created executable (in 4.11).
I’m not sure what would cause this to work in one project but not in another. If the project you have where it is not working isn’t too big, could you zip that up so I could take a look and try to compare it to what I have here to see if I can determine what may be triggering the packaged project to fail on launch?