Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- # GOG.com (www.gog.com)
- # Mount And Blade - Warband
- # Initialization
- CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
- cd "${CURRENT_DIR}"
- source support/gog_com.shlib
- # Game info
- GAME_NAME="$(get_gameinfo 1)"
- VERSION="$(get_gameinfo 2)"
- VERSION_DEV="$(get_gameinfo 3)"
- # Actions
- run_game() {
- echo "Running ${GAME_NAME}"
- local bin32_name="mb_warband.sh"
- local bin64_name="$bin32_name"
- local bin_path32="$CURRENT_DIR/game/"
- local bin_path64="$bin_path32"
- local lib_path32="$CURRENT_DIR/game/"
- local lib_path64="$lib_path32"
- execute_game "${bin32_name}" "${bin64_name}" "${bin_path32}" "${bin_path64}" "${lib_path32}" "${lib_path64}"
- }
- run_config() {
- echo "Running ${GAME_NAME} config"
- local bin32_name="mbw_config.sh"
- local bin64_name="$bin32_name"
- local bin_path32="$CURRENT_DIR/game/"
- local bin_path64="$bin_path32"
- local lib_path32="$CURRENT_DIR/game/"
- local lib_path64="$lib_path32"
- execute_game "${bin32_name}" "${bin64_name}" "${bin_path32}" "${bin_path64}" "${lib_path32}" "${lib_path64}"
- }
- default() {
- run_game
- }
- # Options
- define_option "-s" "--start" "start ${GAME_NAME}" "run_game" "$@"
- define_option "-g" "--config" "start ${GAME_NAME} config" "run_config" "$@"
- # Defaults
- standard_options "$@"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement