Open Source Tomb Raider Engine
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

setup_mac.sh 1.5KB

1234567891011121314151617181920212223242526272829303132
  1. #!/bin/sh
  2. cd `dirname $0`
  3. if [ ! -d "${HOME}/.OpenRaider" ]; then
  4. echo "Setting up OpenRaider for user $USER..."
  5. mkdir -p ~/.OpenRaider
  6. cp ../Resources/defaults/OpenRaider.init ~/.OpenRaider/
  7. cp ../Resources/defaults/custom.cfg ~/.OpenRaider/
  8. mkdir -p ~/.OpenRaider/paks
  9. mkdir -p ~/.OpenRaider/music
  10. mkdir -p ~/.OpenRaider/data
  11. mkdir -p ~/.OpenRaider/sshots
  12. cp ../Resources/defaults/*.tga ~/.OpenRaider/data
  13. cp ../Resources/defaults/*.wav ~/.OpenRaider/data
  14. cp ../Resources/defaults/*.ttf ~/.OpenRaider/data
  15. echo "DONE"
  16. osascript -e 'tell app "System Events" to display alert "Initial Configuration stored in ~/.OpenRaider\n\nView and edit OpenRaider.init to your needs..."'
  17. fi
  18. if [[ ! -n `find "${HOME}/.OpenRaider/paks" -type f -exec echo Found {} \;` ]]; then
  19. echo "Missing level files!"
  20. osascript -e 'tell app "System Events" to display alert "No level files stored in ~/.OpenRaider/paks\n\nPlace level files there and edit ~/.OpenRaider/OpenRaider.init"'
  21. else
  22. if [[ ! `diff "${HOME}/.OpenRaider/OpenRaider.init" "../Resources/defaults/OpenRaider.init"` ]]; then
  23. if [[ ! `diff "${HOME}/.OpenRaider/custom.cfg" "../Resources/defaults/custom.cfg"` ]]; then
  24. echo "Unconfigured user!"
  25. osascript -e 'tell app "System Events" to display alert "Please edit ~/.OpenRaider/OpenRaider.init or ~/.OpenRaider/custom.cfg"'
  26. else
  27. ./OpenRaider
  28. fi
  29. else
  30. ./OpenRaider
  31. fi
  32. fi