Skip to content

Commit

Permalink
Fix incorrect output arg.
Browse files Browse the repository at this point in the history
  • Loading branch information
qiuwch committed Oct 13, 2017
1 parent 2e2ab07 commit 8a9f08d
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions build.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,19 @@ def main():

ue4 = UE4Automation(args.UE4)

if args.output:
output_folder = args.output
else:
output_folder = None

# Build the plugin
descriptor_file = args.descriptor_file
abs_descriptor_file = os.path.abspath(descriptor_file)
if descriptor_file.endswith('.uplugin'):
output_folder = 'Plugins/UnrealCV'
if not output_folder:
output_folder = 'Plugins/UnrealCV'
abs_output_folder = os.path.abspath(output_folder)

ue4.build_plugin(abs_descriptor_file, abs_output_folder)

# Install the plugin if requested
Expand All @@ -47,7 +53,8 @@ def main():

elif descriptor_file.endswith('.uproject'):
project_name = os.path.basename(descriptor_file)
output_folder = 'Binaries/%s' % project_name
if not output_folder:
output_folder = 'Binaries/%s' % project_name
abs_output_folder = os.path.abspath(output_folder)

ue4.package(abs_descriptor_file, abs_output_folder)
Expand Down

0 comments on commit 8a9f08d

Please sign in to comment.