Skip to content

Instantly share code, notes, and snippets.

@soundyogi
Created November 22, 2020 21:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soundyogi/6c8b013032a2b0fa054fc3471736fc56 to your computer and use it in GitHub Desktop.
Save soundyogi/6c8b013032a2b0fa054fc3471736fc56 to your computer and use it in GitHub Desktop.

The solution I'm using is the following:

Compile the plugin using the command line:

"ENGINE_DIR\UE_4.22\Engine\Build\BatchFiles\RunUAT.bat" BuildPlugin -Plugin="PATH_TO_MY_PLUGIN\MyPlugin.uplugin" -Package="PATH_TO_BUILD_FOLDER" -TargetPlatforms=Win64 -Rocket -precompile

Obviously replace ENGINE_DIR, PATH_TO_MY_PLUGIN, MyPlugin, PATH_TO_BUILD_FOLDER

Note that you should either add -precompile to the argument (as above) or put bPrecompile=true into your build.cs files

After building the plugin is done add/replace bPrecompile=true with bUsePrecompiled = true

Delete all the .cpp files (in the source and intermediate folders) (Untested: you can even delete the header files but then you can't extend the cpp classes anymore)

Your plugin is now ready to use without the source code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment