-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBuild.bat
45 lines (34 loc) · 940 Bytes
/
Build.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
@echo off
setlocal EnableDelayedExpansion
set ROOTPATH=%~dp0
pushd %ROOTPATH%
REM Default to the latest Unreal Engine 5 version but can be overriden by any other version, a source build from Github, or even UE4
if [%1] == [] (
set ENGINE=5.5
) else (
set ENGINE=%1
)
if "%ENGINE%" == "S" (
REM Source code Engine
set ENGINEPATH=C:\Workspace\UnrealEngine
) else (
set ENGINEPATH=C:\Program Files\Epic Games\UE_%ENGINE%
)
set UBT="%ENGINEPATH%\Engine\Build\BatchFiles\Build.bat"
if not exist %UBT% (
echo %UBT% not found
exit /b
)
echo Unsing Unreal Engine %ENGINE% from "%ENGINEPATH%"
for %%a in (*.uproject) do set UPROJECT="%CD%\%%a"
if not defined UPROJECT (
echo *.uproject file not found
exit /b
)
for %%i in (%UPROJECT%) do (
set PROJECT=%%~ni
)
echo Build %UPROJECT% (project '%PROJECT%')
echo on
%UBT% %UPROJECT% Win64 Development %PROJECT%Editor
@echo off