Installer gothic-ii-gog

files:
- setup: N/A:Select the GOG game setup file
game:
  arch: win32
  exe: drive_c/GOG Games/Gothic 2 Gold/system/Gothic2.exe
  prefix: $GAMEDIR
installer:
- input_menu:
    description: Please choose your preferred game resolution
    id: gameresolution_ini
    options:
    - 1920x1080,32: 1920x1080 (16:9), 32-bit colour depth
    - 1368x768,32: 1368x768 (~16:9), 32-bit colour depth
    - 1366x768,32: 1366x768 (16:9), 32-bit colour depth
    - 1360x768,32: 1360x768 (~16:9), 32-bit colour depth
    - 1280x720,32: 1280x720 (16:9), 32-bit colour depth
    - 960x540,32: 960x540 (16:9), 32-bit colour depth
    - 1280x960,32: 1280x960 (4:3), 32-bit colour depth
    - 1024x768,32: 1024x768 (4:3), 32-bit colour depth
    - 800x600,32: 800x600 (4:3), 32-bit colour depth
    - 640x480,32: 640x480 (4:3), 32-bit colour depth
    preselect: 1024x768,32
- input_menu:
    description: Do you want to show the introductory company logo video(s)?
    id: showvideologo_ini
    options:
    - '0': 'No'
    - '1': 'Yes'
    preselect: '0'
- task:
    app: win7
    description: 'winetricks: win7'
    name: winetricks
    prefix: $GAMEDIR
- task:
    description: Installing Gothic 2
    executable: setup
    name: wineexec
    prefix: $GAMEDIR
- write_config:
    data:
      GAME:
        bloodDetail: 3
        playLogoVideos: $INPUT_showvideologo_ini
        scaleVideos: 1
        subTitles: 1
      PERFORMANCE:
        modelDetail: 1
        sightValue: 14
      VIDEO:
        zVidResFullscreenBPP: _lutris_resolution_bpp_
        zVidResFullscreenX: _lutris_resolution_x_
        zVidResFullscreenY: _lutris_resolution_y_
    description: Updating 'gothic.ini' file -- step 1/2
    file: $GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI
- execute:
    command: 'set -x && : && fcfg=''$GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI''
      && [ -n "${fcfg}" ] && [ -f "${fcfg}" -a -w "${fcfg}" ] && : && res_full="$INPUT_gameresolution_ini"
      && [ -n "${res_full}" ] && res_x="${res_full%%x*}" && res_y="${res_full%%,*}"
      && res_y="${res_y##*x}" && res_bpp="${res_full##*,}" && [ -n "${res_x}" ] &&
      [ -n "${res_y}" ] && [ -n "${res_bpp}" ] && [ "${res_x}" != "${res_full}" ]
      && [ "${res_y}" != "${res_full}" ] && [ "${res_bpp}" != "${res_full}" ] && :
      && sed -i.orig -e "s/_lutris_resolution_x_/${res_x}/;s/_lutris_resolution_y_/${res_y}/;s/_lutris_resolution_bpp_/${res_bpp}/"
      "${fcfg}" && ! grep -q ''\b_lutris_resolution_[xybp]*_\b'' "${fcfg}" && : &&
      cp -av "${fcfg}" "${fcfg}.lutris.orig" && :

      '
    description: Updating 'gothic.ini' file -- step 2/2
    disable_runtime: true
require-binaries: sed, grep
wine:
  overrides:
    ddraw: n,b
description: GOG installer; user-selectable resolution; fixes the "blank videos" issue
game_slug: gothic-ii
gogslug: gothic_2_gold_edition
humblestoreid: ''
installer_slug: gothic-ii-gog
name: Gothic II
notes: "* allows for install-time screen resolution setting;\r\n * fixes the \"blank\
  \ videos\" issue;\r\n * modifies game-provided config file $GAMEDIR/drive_c/GOG\
  \ Games/Gothic 2 Gold/system/GOTHIC.INI"
runner: wine
script:
  files:
  - setup: N/A:Select the GOG game setup file
  game:
    arch: win32
    exe: drive_c/GOG Games/Gothic 2 Gold/system/Gothic2.exe
    prefix: $GAMEDIR
  installer:
  - input_menu:
      description: Please choose your preferred game resolution
      id: gameresolution_ini
      options:
      - 1920x1080,32: 1920x1080 (16:9), 32-bit colour depth
      - 1368x768,32: 1368x768 (~16:9), 32-bit colour depth
      - 1366x768,32: 1366x768 (16:9), 32-bit colour depth
      - 1360x768,32: 1360x768 (~16:9), 32-bit colour depth
      - 1280x720,32: 1280x720 (16:9), 32-bit colour depth
      - 960x540,32: 960x540 (16:9), 32-bit colour depth
      - 1280x960,32: 1280x960 (4:3), 32-bit colour depth
      - 1024x768,32: 1024x768 (4:3), 32-bit colour depth
      - 800x600,32: 800x600 (4:3), 32-bit colour depth
      - 640x480,32: 640x480 (4:3), 32-bit colour depth
      preselect: 1024x768,32
  - input_menu:
      description: Do you want to show the introductory company logo video(s)?
      id: showvideologo_ini
      options:
      - '0': 'No'
      - '1': 'Yes'
      preselect: '0'
  - task:
      app: win7
      description: 'winetricks: win7'
      name: winetricks
      prefix: $GAMEDIR
  - task:
      description: Installing Gothic 2
      executable: setup
      name: wineexec
      prefix: $GAMEDIR
  - write_config:
      data:
        GAME:
          bloodDetail: 3
          playLogoVideos: $INPUT_showvideologo_ini
          scaleVideos: 1
          subTitles: 1
        PERFORMANCE:
          modelDetail: 1
          sightValue: 14
        VIDEO:
          zVidResFullscreenBPP: _lutris_resolution_bpp_
          zVidResFullscreenX: _lutris_resolution_x_
          zVidResFullscreenY: _lutris_resolution_y_
      description: Updating 'gothic.ini' file -- step 1/2
      file: $GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI
  - execute:
      command: 'set -x && : && fcfg=''$GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI''
        && [ -n "${fcfg}" ] && [ -f "${fcfg}" -a -w "${fcfg}" ] && : && res_full="$INPUT_gameresolution_ini"
        && [ -n "${res_full}" ] && res_x="${res_full%%x*}" && res_y="${res_full%%,*}"
        && res_y="${res_y##*x}" && res_bpp="${res_full##*,}" && [ -n "${res_x}" ]
        && [ -n "${res_y}" ] && [ -n "${res_bpp}" ] && [ "${res_x}" != "${res_full}"
        ] && [ "${res_y}" != "${res_full}" ] && [ "${res_bpp}" != "${res_full}" ]
        && : && sed -i.orig -e "s/_lutris_resolution_x_/${res_x}/;s/_lutris_resolution_y_/${res_y}/;s/_lutris_resolution_bpp_/${res_bpp}/"
        "${fcfg}" && ! grep -q ''\b_lutris_resolution_[xybp]*_\b'' "${fcfg}" && :
        && cp -av "${fcfg}" "${fcfg}.lutris.orig" && :

        '
      description: Updating 'gothic.ini' file -- step 2/2
      disable_runtime: true
  require-binaries: sed, grep
  wine:
    overrides:
      ddraw: n,b
slug: gothic-ii-gog
steamid: 39510
version: GOG
year: 2003
{
  "game_slug": "gothic-ii",
  "version": "GOG",
  "description": "GOG installer; user-selectable resolution; fixes the \"blank videos\" issue",
  "notes": "* allows for install-time screen resolution setting;\r\n * fixes the \"blank videos\" issue;\r\n * modifies game-provided config file $GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI",
  "name": "Gothic II",
  "year": 2003,
  "steamid": 39510,
  "gogslug": "gothic_2_gold_edition",
  "humblestoreid": "",
  "runner": "wine",
  "slug": "gothic-ii-gog",
  "installer_slug": "gothic-ii-gog",
  "script": {
    "files": [
      {
        "setup": "N/A:Select the GOG game setup file"
      }
    ],
    "game": {
      "arch": "win32",
      "exe": "drive_c/GOG Games/Gothic 2 Gold/system/Gothic2.exe",
      "prefix": "$GAMEDIR"
    },
    "installer": [
      {
        "input_menu": {
          "description": "Please choose your preferred game resolution",
          "id": "gameresolution_ini",
          "options": [
            {
              "1920x1080,32": "1920x1080 (16:9), 32-bit colour depth"
            },
            {
              "1368x768,32": "1368x768 (~16:9), 32-bit colour depth"
            },
            {
              "1366x768,32": "1366x768 (16:9), 32-bit colour depth"
            },
            {
              "1360x768,32": "1360x768 (~16:9), 32-bit colour depth"
            },
            {
              "1280x720,32": "1280x720 (16:9), 32-bit colour depth"
            },
            {
              "960x540,32": "960x540 (16:9), 32-bit colour depth"
            },
            {
              "1280x960,32": "1280x960 (4:3), 32-bit colour depth"
            },
            {
              "1024x768,32": "1024x768 (4:3), 32-bit colour depth"
            },
            {
              "800x600,32": "800x600 (4:3), 32-bit colour depth"
            },
            {
              "640x480,32": "640x480 (4:3), 32-bit colour depth"
            }
          ],
          "preselect": "1024x768,32"
        }
      },
      {
        "input_menu": {
          "description": "Do you want to show the introductory company logo video(s)?",
          "id": "showvideologo_ini",
          "options": [
            {
              "0": "No"
            },
            {
              "1": "Yes"
            }
          ],
          "preselect": "0"
        }
      },
      {
        "task": {
          "app": "win7",
          "description": "winetricks: win7",
          "name": "winetricks",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "task": {
          "description": "Installing Gothic 2",
          "executable": "setup",
          "name": "wineexec",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "write_config": {
          "data": {
            "GAME": {
              "bloodDetail": 3,
              "playLogoVideos": "$INPUT_showvideologo_ini",
              "scaleVideos": 1,
              "subTitles": 1
            },
            "PERFORMANCE": {
              "modelDetail": 1,
              "sightValue": 14
            },
            "VIDEO": {
              "zVidResFullscreenBPP": "_lutris_resolution_bpp_",
              "zVidResFullscreenX": "_lutris_resolution_x_",
              "zVidResFullscreenY": "_lutris_resolution_y_"
            }
          },
          "description": "Updating 'gothic.ini' file -- step 1/2",
          "file": "$GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI"
        }
      },
      {
        "execute": {
          "command": "set -x && : && fcfg='$GAMEDIR/drive_c/GOG Games/Gothic 2 Gold/system/GOTHIC.INI' && [ -n \"${fcfg}\" ] && [ -f \"${fcfg}\" -a -w \"${fcfg}\" ] && : && res_full=\"$INPUT_gameresolution_ini\" && [ -n \"${res_full}\" ] && res_x=\"${res_full%%x*}\" && res_y=\"${res_full%%,*}\" && res_y=\"${res_y##*x}\" && res_bpp=\"${res_full##*,}\" && [ -n \"${res_x}\" ] && [ -n \"${res_y}\" ] && [ -n \"${res_bpp}\" ] && [ \"${res_x}\" != \"${res_full}\" ] && [ \"${res_y}\" != \"${res_full}\" ] && [ \"${res_bpp}\" != \"${res_full}\" ] && : && sed -i.orig -e \"s/_lutris_resolution_x_/${res_x}/;s/_lutris_resolution_y_/${res_y}/;s/_lutris_resolution_bpp_/${res_bpp}/\" \"${fcfg}\" && ! grep -q '\\b_lutris_resolution_[xybp]*_\\b' \"${fcfg}\" && : && cp -av \"${fcfg}\" \"${fcfg}.lutris.orig\" && :\n",
          "description": "Updating 'gothic.ini' file -- step 2/2",
          "disable_runtime": true
        }
      }
    ],
    "require-binaries": "sed, grep",
    "wine": {
      "overrides": {
        "ddraw": "n,b"
      }
    }
  }
}
Back to game