Installer battlefield-4-dxvk

files:
- client: https://download.dm.origin.com/origin/live/OriginThinSetup.exe
- updater: https://lutris.nyc3.cdn.digitaloceanspaces.com/games/origin/updateorigin.sh
- pbuster: http://websec.evenbalance.com/downloads/W/gui/pbsetup.zip
game:
  arch: win64
  exe: drive_c/Program Files (x86)/Origin/Origin.exe
  prefix: $GAMEDIR
installer:
- task:
    arch: win64
    description: Creating Wine prefix
    name: create_prefix
    prefix: $GAMEDIR
- execute:
    command: mkdir "$GAMEDIR/nv-shaders"
- input_menu:
    description: 'Setting DXVK workarounds please choose your GPU:'
    id: GPU
    options:
    - Not needed for AMD. Ignore this.: AMD
    - ? 'dxgi.customVendorId = 10de

        dxgi.nvapiHack = False'
      : Nvidia
    preselect: Not needed for AMD. Ignore this.
- write_file:
    content: $INPUT_GPU
    file: $GAMEDIR/dxvk.conf
- task:
    app: nocrashdialog arial vcrun2010 vcrun2013 vcrun2015 win81
    arch: win64
    name: winetricks
    prefix: $GAMEDIR
- task:
    arch: win64
    args: /silent
    description: Installing Origin... Login window might pop-up and close.
    exclude_processes: Origin.exe OriginClientService.exe OriginWebHelperService.exe
      QtWebEngineProcess.exe
    executable: client
    name: wineexec
    prefix: $GAMEDIR
- task:
    name: winekill
    prefix: $GAMEDIR
- chmodx: updater
- merge:
    dst: $GAMEDIR/drive_c/Program Files (x86)/Origin
    src: updater
- extract:
    dst: $GAMEDIR
    file: pbuster
system:
  env:
    DXVK_CONFIG_FILE: $GAMEDIR/dxvk.conf
    STAGING_SHARED_MEMORY: 0
    __GL_SHADER_DISK_CACHE: 1
    __GL_SHADER_DISK_CACHE_PATH: $GAMEDIR/nv-shaders
  exclude_processes: QtWebEngineProcess.exe ActivationUI.exe OriginWebHelperService.exe
  pulse_latency: true
wine:
  overrides:
    OriginThinSetupInternal.exe: disabled
    nvapi,nvapi64: disabled
description: Only sets up Origin and DXVK you'll need to download Battlefield 4 manually.
game_slug: battlefield-4
gogslug: ''
humblestoreid: ''
installer_slug: battlefield-4-dxvk
name: Battlefield 4
notes: "Please read before installing: https://github.com/lutris/docs/blob/master/Origin.md\r\
  \n\r\nRun the /home//Games/battlefield-4/drive_c/Program Files (x86)/Origin Games/Battlefield\
  \ 4/pbsvc.exe with wine, after downloading Battlefield 4 from Origin to make multiplayer\
  \ work.\r\n\r\nTo fix 1 second microstutters in the game, remove write permissions\
  \ for the Origin folder:\r\nchmod -w -R ~/Games/battlefield-4/drive_c/users//AppData/Local/Origin"
runner: wine
script:
  files:
  - client: https://download.dm.origin.com/origin/live/OriginThinSetup.exe
  - updater: https://lutris.nyc3.cdn.digitaloceanspaces.com/games/origin/updateorigin.sh
  - pbuster: http://websec.evenbalance.com/downloads/W/gui/pbsetup.zip
  game:
    arch: win64
    exe: drive_c/Program Files (x86)/Origin/Origin.exe
    prefix: $GAMEDIR
  installer:
  - task:
      arch: win64
      description: Creating Wine prefix
      name: create_prefix
      prefix: $GAMEDIR
  - execute:
      command: mkdir "$GAMEDIR/nv-shaders"
  - input_menu:
      description: 'Setting DXVK workarounds please choose your GPU:'
      id: GPU
      options:
      - Not needed for AMD. Ignore this.: AMD
      - ? 'dxgi.customVendorId = 10de

          dxgi.nvapiHack = False'
        : Nvidia
      preselect: Not needed for AMD. Ignore this.
  - write_file:
      content: $INPUT_GPU
      file: $GAMEDIR/dxvk.conf
  - task:
      app: nocrashdialog arial vcrun2010 vcrun2013 vcrun2015 win81
      arch: win64
      name: winetricks
      prefix: $GAMEDIR
  - task:
      arch: win64
      args: /silent
      description: Installing Origin... Login window might pop-up and close.
      exclude_processes: Origin.exe OriginClientService.exe OriginWebHelperService.exe
        QtWebEngineProcess.exe
      executable: client
      name: wineexec
      prefix: $GAMEDIR
  - task:
      name: winekill
      prefix: $GAMEDIR
  - chmodx: updater
  - merge:
      dst: $GAMEDIR/drive_c/Program Files (x86)/Origin
      src: updater
  - extract:
      dst: $GAMEDIR
      file: pbuster
  system:
    env:
      DXVK_CONFIG_FILE: $GAMEDIR/dxvk.conf
      STAGING_SHARED_MEMORY: 0
      __GL_SHADER_DISK_CACHE: 1
      __GL_SHADER_DISK_CACHE_PATH: $GAMEDIR/nv-shaders
    exclude_processes: QtWebEngineProcess.exe ActivationUI.exe OriginWebHelperService.exe
    pulse_latency: true
  wine:
    overrides:
      OriginThinSetupInternal.exe: disabled
      nvapi,nvapi64: disabled
slug: battlefield-4-dxvk
steamid: null
version: DXVK
year: 2013
{
  "game_slug": "battlefield-4",
  "version": "DXVK",
  "description": "Only sets up Origin and DXVK you'll need to download Battlefield 4 manually.",
  "notes": "Please read before installing: https://github.com/lutris/docs/blob/master/Origin.md\r\n\r\nRun the /home//Games/battlefield-4/drive_c/Program Files (x86)/Origin Games/Battlefield 4/pbsvc.exe with wine, after downloading Battlefield 4 from Origin to make multiplayer work.\r\n\r\nTo fix 1 second microstutters in the game, remove write permissions for the Origin folder:\r\nchmod -w -R ~/Games/battlefield-4/drive_c/users//AppData/Local/Origin",
  "name": "Battlefield 4",
  "year": 2013,
  "steamid": null,
  "gogslug": "",
  "humblestoreid": "",
  "runner": "wine",
  "slug": "battlefield-4-dxvk",
  "installer_slug": "battlefield-4-dxvk",
  "script": {
    "files": [
      {
        "client": "https://download.dm.origin.com/origin/live/OriginThinSetup.exe"
      },
      {
        "updater": "https://lutris.nyc3.cdn.digitaloceanspaces.com/games/origin/updateorigin.sh"
      },
      {
        "pbuster": "http://websec.evenbalance.com/downloads/W/gui/pbsetup.zip"
      }
    ],
    "game": {
      "arch": "win64",
      "exe": "drive_c/Program Files (x86)/Origin/Origin.exe",
      "prefix": "$GAMEDIR"
    },
    "installer": [
      {
        "task": {
          "arch": "win64",
          "description": "Creating Wine prefix",
          "name": "create_prefix",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "execute": {
          "command": "mkdir \"$GAMEDIR/nv-shaders\""
        }
      },
      {
        "input_menu": {
          "description": "Setting DXVK workarounds please choose your GPU:",
          "id": "GPU",
          "options": [
            {
              "Not needed for AMD. Ignore this.": "AMD"
            },
            {
              "dxgi.customVendorId = 10de\ndxgi.nvapiHack = False": "Nvidia"
            }
          ],
          "preselect": "Not needed for AMD. Ignore this."
        }
      },
      {
        "write_file": {
          "content": "$INPUT_GPU",
          "file": "$GAMEDIR/dxvk.conf"
        }
      },
      {
        "task": {
          "app": "nocrashdialog arial vcrun2010 vcrun2013 vcrun2015 win81",
          "arch": "win64",
          "name": "winetricks",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "task": {
          "arch": "win64",
          "args": "/silent",
          "description": "Installing Origin... Login window might pop-up and close.",
          "exclude_processes": "Origin.exe OriginClientService.exe OriginWebHelperService.exe QtWebEngineProcess.exe",
          "executable": "client",
          "name": "wineexec",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "task": {
          "name": "winekill",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "chmodx": "updater"
      },
      {
        "merge": {
          "dst": "$GAMEDIR/drive_c/Program Files (x86)/Origin",
          "src": "updater"
        }
      },
      {
        "extract": {
          "dst": "$GAMEDIR",
          "file": "pbuster"
        }
      }
    ],
    "system": {
      "env": {
        "DXVK_CONFIG_FILE": "$GAMEDIR/dxvk.conf",
        "STAGING_SHARED_MEMORY": 0,
        "__GL_SHADER_DISK_CACHE": 1,
        "__GL_SHADER_DISK_CACHE_PATH": "$GAMEDIR/nv-shaders"
      },
      "exclude_processes": "QtWebEngineProcess.exe ActivationUI.exe OriginWebHelperService.exe",
      "pulse_latency": true
    },
    "wine": {
      "overrides": {
        "OriginThinSetupInternal.exe": "disabled",
        "nvapi,nvapi64": "disabled"
      }
    }
  }
}
Back to game