Packaged game crash on startup

I managed to package my game successfully with no errors, but when I tried to start it up it immediately crashed. When I checked the logs I found this:

[2018.09.27-12.35.49:661][  0]LogWindows:Error: Fatal error: [File:D:\Build\++UE4+Release-4.14+Compile\Sync\Engine\Source\Runtime\Engine\Private\GlobalShader.cpp] [Line: 339] 
[2018.09.27-12.35.49:661][  0]LogWindows:Error: Missing global shader FPixelShaderDeclaration, Please make sure cooking was successful.

How do I fix this?

My packaging was set to development mode instead of shipping, it works now.