@echo off
echo School-Doom WAD installing...
echo ...have a cup of coffee...
echo ...we'll wake you up when it's ready!

deusf -app schoold2.wad

if exist dehacked.exe goto thisdir
if exist dehacked\dehacked.exe goto dehdir

echo Patch not installed
doom2 -file schoold2.wad
goto end

:thisdir
dehacked -reload
dehacked -load schoold2.deh
doomhack -file schoold2.wad
goto end

:dehdir
dehacked\dehacked -reload
dehacked\dehacked -load schoold2.deh
doomhack -file schoold2.wad

:end
