Hey folks,
today I looked into packaging a game and noticed two odd blueprint behaviors (dealing with them lead to a lot of frustration), and I am not quite sure whether I should credit my own incompetence or UE4 bugs. Maybe you can help solve some of the mysteries, or I can at least share my experience (and solutions) with people who might have similar problems. Here goes!
First issue: Input
The first issue was a quite annoying one: there was no input in the packaged version. The most I could do was click UMG buttons, but anything apart from that did not work. After hours of looking into it I finally figured out that having the movement/input actions (e.g. character jump, axis input etc.) in the PlayerCharacter BP does work in the editor, but it does not in the packaged game. After moving all input related stuff to the PlayerController BP everything worked like a charm.
So did I just miss an option which should have been set (mind you, I looked and tried everything I could possibly think of for hours!)?
What’s really bothering me is that most UE4 Templates (started off with Third Person BP Template) put all the input related logic into the PlayerCharacter BP which does not seem to work in a packaged game.
Second issue: Collision Events
In my game I have a PlayerCharacter, basically just a sphere and a capsule component with basic collision settings (Pawn, Generate Overlap Events, Simulation Generates Hit Events) and another actor BP which can be collected (capsule component for collision, OverlapAllDynamic). The player would check for overlapping events, and in turn call a method on the overlapped actor. Once again this worked fine in the editor. In the packaged game however there was no event. I made sure of that. The Overlap Event did not fire. I then decided to turn things around and let the other actors check for overlap events with the PlayerCharacter - and to my surprise - they fired and everything was working like it was supposed to.
What went wrong here? Why did the first setup work in the editor but not in the packaged game, and why does the second setup work in both?
Almost forgot, I am using UE 4.6.1.