diff --git a/Run.sh b/Run.sh old mode 100644 new mode 100755 index 890b2f6..1758bf7 --- a/Run.sh +++ b/Run.sh @@ -7,6 +7,10 @@ function install() { echo install ok } +function getmodprefix() { + basename $(find $SCRIPT_DIR/mods/ -maxdepth 1 -mindepth 1 -type d | head -z -n 1) +} + function show_help() { echo echo "Usage: $0 { install } " @@ -24,7 +28,10 @@ function check_game_dir() { } case "$1" in - + 'getmodprefix') + check_game_dir + getmodprefix + ;; 'install') check_game_dir install @@ -34,4 +41,4 @@ case "$1" in exit 1 ;; esac -exit 0 \ No newline at end of file +exit 0