@echo off
echo.
echo 		Please READ THIS CAREFULLY BEFORE PROCESSING!
echo.
echo  This script file is what you need ONLY when you're not power user (have limited (not Administrative) rights on this PC) AND cannot burn anything with UGH Burner.
echo.
echo  In this case you have to run this script WITH ADMINISTRATOR RIGHTS and then you SHOULD be able to work with UGH Burner normally.
echo.
echo This script copies 1 file to the SYSTEM32/Drivers dir and adds 1 key to the registry to provide full access to the disc drive for UGH Burner.
echo.
echo 	WARNING: THIS SCRIPT WILL REBOOT COMPUTER AT THE END! 
echo 		 SAVE ALL YOUR DATA NOW!
pause
cls
echo copying file...
copy "%~dp0StarOpen.sys" "%windir%\SYSTEM32\Drivers" /Y
if errorlevel == 1 goto errorCopy
echo Copied successfully.

echo Now we will patch the registry, please allow regedit to do its job...
pause

regedit "%~dp0StarOpen.reg"

echo   YOUR COMPUTER WILL BE RESTARTED NOW!
echo Close this window if you plan to restart the computer later.
pause

shutdown -r

echo Bye. ;-)
exit

:errorCopy
echo.
echo Failed to copy the file. Are you sure you run the script with 
echo administrative rights (As administrator)?
pause
exit