@ECHO OFF
echo.
echo Locating where Unreal Engine is installed by checking the Windows registry...
FOR /F "tokens=2*" %%A IN ('reg query "HKEY_LOCAL_MACHINE\SOFTWARE\EpicGames\Unreal Engine\4.20" /v "InstalledDirectory"') DO (
SET "UnrealEngineDir=%%B"
)
IF "%UnrealEngineDir%"=="" GOTO CannotFindUnrealEngine
echo.
echo Using Unreal Engine directory: "%UnrealEngineDir%\Engine\Binaries\Win64"
:Done
echo.
--xcopy "EngineDLL\UE4Editor-AnimationEditor.dll" "%UnrealEngineDir%\Engine\Binaries\Win64\" /e /i /y
echo.
goto TheEnd
:CannotFindUnrealEngine
echo.
echo 無法找到虛幻引擎安裝目錄,請聯繫作者
echo.
pause
:TheEnd
exit