-
Notifications
You must be signed in to change notification settings - Fork 36
[WIP] [com.blizzard.Diablo3] Initial Diablo III flatpak #73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
johnramsden
wants to merge
3
commits into
winepak:master
Choose a base branch
from
johnramsden:com.blizzard.Diablo3
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| # Diablo III | ||
|
|
||
| Massively-multiplayer online role-playing game | ||
|
|
||
| ## Status | ||
|
|
||
| | Arch | Installs | Runs | Notes | | ||
| | ----- | -------- | ---- | ----- | | ||
| | 32bit | N/A | N/A | | | ||
| | 64bit | Yes | Yes | Installs & runs. | | ||
|
|
||
| ## Build & Install | ||
| ### Repo | ||
| #### 32bit | ||
|
|
||
| flatpak-builder --arch=i386 --force-clean builds --repo=winepak com.blizzard.Diablo3.yml | ||
| flatpak --user install winepak com.blizzard.Diablo3 | ||
|
|
||
| #### 64bit | ||
|
|
||
| flatpak-builder --arch=x86_64 --force-clean builds --repo=winepak com.blizzard.Diablo3.yml | ||
| flatpak --user install winepak com.blizzard.Diablo3 | ||
|
|
||
| ### Direct | ||
| #### 32bit | ||
|
|
||
| flatpak-builder --user --arch=i386 --force-clean --install builds com.blizzard.Diablo3.yml | ||
|
|
||
| #### 64bit | ||
|
|
||
| flatpak-builder --user --arch=x86_64 --force-clean --install builds com.blizzard.Diablo3.yml | ||
|
|
||
| ## Run | ||
|
|
||
| flatpak run com.blizzard.Diablo3 | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| <?xml version="1.0" encoding="UTF-8"?> | ||
| <component type="desktop"> | ||
| <id>com.blizzard.Diablo3.desktop</id> | ||
| <metadata_license>CC0-1.0</metadata_license> | ||
| <project_license>LicenseRef-proprietary</project_license> | ||
| <name>Diablo III</name> | ||
| <summary>Action role-playing game</summary> | ||
| <description> | ||
| <p>The demonically-besieged world of Sanctuary needs heroes. Will you heed the call? Diablo III is an action role-playing game from Blizzard Entertainment for the PC and Mac.</p> | ||
| </description> | ||
|
|
||
| <project_group>winepak</project_group> | ||
| <developer_name>Blizzard Entertainment</developer_name> | ||
|
|
||
| <url type="homepage">https://diablo3.com</url> | ||
| <url type="help">https://us.battle.net/support/en/games/diablo3</url> | ||
| <url type="bugtracker">https://us.battle.net/forums/en/d3/3354739/</url> | ||
|
|
||
| <categories> | ||
| <category>Game</category> | ||
| <category>ActionRolePlaying</category> | ||
| </categories> | ||
|
|
||
| <recommends> | ||
| <memory>1024</memory> | ||
| </recommends> | ||
|
|
||
| <releases> | ||
| <release date="2018-07-14" version="0.1.0"> | ||
| <description> | ||
| <ul> | ||
| <li>Initial release of Diablo III via winepak.</li> | ||
| </ul> | ||
| </description> | ||
| </release> | ||
| </releases> | ||
| </component> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| [Desktop Entry] | ||
| Name=Diablo III | ||
| Comment=Action role-playing game | ||
| Icon=com.blizzard.Diablo3.svg | ||
| Exec=diablo3 %U | ||
| StartupNotify=true | ||
| Terminal=false | ||
| Type=Application | ||
| MimeType=application/x-ms-dos-executable;application/x-msi;application/x-ms-shortcut; | ||
| Categories=Game;RolePlaying; | ||
| Keywords=DiabloIII;Blizzard;ARPG; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,188 @@ | ||
| app-id: com.blizzard.Diablo3 | ||
| branch: stable | ||
|
|
||
| runtime: org.winepak.Platform | ||
| runtime-version: 3.0 | ||
| sdk: org.winepak.Sdk | ||
|
|
||
| base: com.blizzard.BattleNet.BaseApp | ||
| base-version: stable | ||
|
|
||
| command: diablo3 | ||
|
|
||
| inherit-extensions: | ||
| - org.winepak.Platform.Compat32 | ||
| - org.winepak.Platform.Extension.corefonts | ||
| - org.winepak.Platform.Extension.vcrun2015 | ||
|
|
||
| add-extensions: | ||
| org.winepak.Platform.Wine: | ||
| directory: lib/wine | ||
| version: 3.10-staging | ||
| add-ld-path: lib | ||
| no-autodownload: false | ||
|
|
||
| org.winepak.Platform.Wine.Compat32: | ||
| directory: lib/wine-32bit | ||
| version: 3.10-staging | ||
| add-ld-path: lib | ||
| no-autodownload: false | ||
|
|
||
| tags: | ||
| - proprietary | ||
|
|
||
| finish-args: | ||
| - --socket=x11 | ||
| - --socket=pulseaudio | ||
| - --share=ipc | ||
| - --share=network | ||
| - --device=dri | ||
| - --filesystem=xdg-documents | ||
| - --allow=multiarch | ||
| # --allow=devel is required to launch Diablo III | ||
| # | ||
| # Without it the game will partily launch then crash. | ||
| # | ||
| # Ideally flatpak applications shouldn't have --allow=devel, so this needs to | ||
| # be investigated. | ||
| - --allow=devel | ||
| - --env=MESA_GLTHREAD=true | ||
| - --env=__GL_THREADED_OPTIMIZATIONS=1 | ||
|
|
||
| modules: | ||
| - name: setup-wine | ||
| buildsystem: simple | ||
| build-commands: | ||
| - mkdir -p /app/lib/wine | ||
|
|
||
| - name: setup-wine-compat32 | ||
| buildsystem: simple | ||
| build-commands: | ||
| - mkdir -p /app/lib/wine-32bit | ||
|
|
||
| - name: setup-vcrun2015 | ||
| buildsystem: simple | ||
| build-commands: | ||
| - mkdir -p /app/lib/extension/vcrun2015 | ||
|
|
||
| - name: diablo3 | ||
| only-arches: | ||
| - x86_64 | ||
| buildsystem: simple | ||
| build-commands: | ||
| - install -d /app/bin | ||
| - install diablo3-installer /app/bin | ||
| - install diablo3 /app/bin | ||
| - install -Dm644 com.blizzard.Diablo3.appdata.xml /app/share/appdata/com.blizzard.Diablo3.appdata.xml | ||
| - install -Dm644 com.blizzard.Diablo3.desktop /app/share/applications/com.blizzard.Diablo3.desktop | ||
| - install -Dm664 com.blizzard.Diablo3.svg /app/share/icons/hicolor/scalable/apps/com.blizzard.Diablo3.svg | ||
| sources: | ||
| - type: script | ||
| dest-filename: diablo3-installer | ||
| commands: | ||
| - if [ -z "$WINEPREFIX" ] ; then | ||
| - ' echo "No wine prefix set or is empty, abort."' | ||
| - ' exit 1' | ||
| - fi | ||
| - | ||
| - source /app/bin/battlenet-installer "battlenet://D3" | ||
| - | ||
| - if [[ $? != 0 ]] ; then | ||
| - ' echo "Battle.net installer failed, abort."' | ||
| - ' exit 1' | ||
| - fi | ||
| - | ||
| - echo "Performing tweak(s)..." | ||
| - echo "Disable winemenubuilder.exe..." | ||
| - wine64 reg add 'HKEY_CURRENT_USER\Software\Wine\DllOverrides' /v winemenubuilder.exe /d '' /f | ||
| - | ||
| - echo "Set DirectDrawRenderer to opengl..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\Direct3D" /v "DirectDrawRenderer" /d "opengl" /f | ||
| - | ||
| - echo "Disable Multisampling..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\Direct3D" /v "Multisampling" /d "disabled" /f | ||
| - | ||
| - echo "Set OffScreenRenderingMode to pbuffer..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\Direct3D" /v "OffScreenRenderingMode" /d "pbuffer" /f | ||
| - | ||
| - echo "Enable GLSL..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\Direct3D" /v "UseGLSL" /d "enabled" /f | ||
| - | ||
| - echo "Set VertexShaderMode to hardware..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\Direct3D" /v "VertexShaderMode" /d "hardware" /f | ||
| - | ||
| - echo "Enable DXVA2..." | ||
| - wine64 reg add "HKEY_CURRENT_USER\Software\Wine\DXVA2" /v "backend" /d "va" /f | ||
| - | ||
| - echo "Disable UseXVidMode" | ||
| - wine64 reg add 'HKEY_CURRENT_USER\Software\Wine\X11 Driver' /v UseXVidMode /d N /f | ||
| - | ||
| - echo "Clear Windows Version" | ||
| - wine64 reg delete 'HKLM\Software\Microsoft\Windows\CurrentVersion' /v SubVersionNumber /f | ||
| - wine64 reg delete 'HKLM\Software\Microsoft\Windows\CurrentVersion' /v VersionNumber /f | ||
| - wine64 reg delete 'HKLM\Software\Microsoft\Windows NT\CurrentVersion' /v CSDVersion /f | ||
| - wine64 reg delete 'HKLM\Software\Microsoft\Windows NT\CurrentVersion' /v CurrentBuildNumber /f | ||
| - wine64 reg delete 'HKLM\Software\Microsoft\Windows NT\CurrentVersion' /v CurrentVersion /f | ||
| - wine64 reg delete 'HKLM\System\CurrentControlSet\Control\ProductOptions' /v ProductType /f | ||
| - wine64 reg delete 'HKLM\System\CurrentControlSet\Control\ServiceCurrent' /v OS /f | ||
| - wine64 reg delete 'HKLM\System\CurrentControlSet\Control\Windows' /v CSDVersion /f | ||
| - wine64 reg delete 'HKCU\Software\Wine' /v Version /f | ||
| - wine64 reg delete 'HKLM\System\CurrentControlSet\Control\ProductOptions' /v ProductType /f | ||
| - | ||
| - echo "Set Windows Version to 10" | ||
| - wine64 reg add 'HKLM\System\CurrentControlSet\Control\ProductOptions' /v ProductType /d 'WinNT' /f | ||
| - wine64 reg add 'HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion' /v CSDVersion /d '' /f | ||
| - wine64 reg add 'HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion' /v CurrentBuildNumber /d '10240' /f | ||
| - wine64 reg add 'HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion' /v CurrentVersion /d '10.0' /f | ||
| - wine64 reg add 'HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Windows' /v CSDVersion /t REG_DWORD /d 00000000 /f | ||
| - | ||
| # This doesn't seem to persist | ||
| # - echo "Setting battlenet launcher to 32bit mode" | ||
| # - mkdir -p "${WINEPREFIX}/dosdevices/c:/users/${USER}/Application Data/Battle.net" | ||
| # - 'cat <<EOF > "${WINEPREFIX}/dosdevices/c:/users/${USER}/Application Data/Battle.net/Battle.net.config"' | ||
| # - '{ ' | ||
| # - ' "Client": { ' | ||
| # - ' "HardwareAcceleration": false,' | ||
| # - ' "Sound": { ' | ||
| # - ' "Enabled": false ' | ||
| # - ' } ' | ||
| # - ' }, ' | ||
| # - ' "Games": { ' | ||
| # - ' "diablo3": { ' | ||
| # - ' "Run64Bit": false, ' | ||
| # - ' "Run64BitSet": true ' | ||
| # - ' } ' | ||
| # - ' } ' | ||
| # - '} ' | ||
| # - 'EOF' | ||
| - | ||
| - echo "Installer finished" | ||
| - type: script | ||
| dest-filename: diablo3 | ||
| commands: | ||
| - export WINEARCH=win64 | ||
| - export __GL_SHADER_DISK_CACHE=1 | ||
| - export __GL_SHADER_DISK_CACHE_PATH=${WINEPREFIX} | ||
| - | ||
| - if ! [ -e "${WINEPREFIX}/dosdevices/c:/Program Files (x86)/Battle.net" ] ; then | ||
| - ' source /app/bin/diablo3-installer' | ||
| - ' if [[ $? != 0 ]] ; then' | ||
| - ' echo "Installation failed, abort."' | ||
| - ' exit 1' | ||
| - ' fi' | ||
| - fi | ||
| - | ||
| - echo "Verify \"Battle.net Helper.exe\" doesn't launch..." | ||
| - if [ -f "${WINEPREFIX}/dosdevices/c:/Program Files (x86)/Battle.net/Battle.net*/Battle.net Helper.exe" ] ; then | ||
| - ' mv "${WINEPREFIX}/dosdevices/c:/Program Files (x86)/Battle.net/Battle.net*/Battle.net Helper.exe" "${WINEPREFIX}/dosdevices/c:/Program Files (x86)/Battle.net/Battle.net*/Battle.net Helper.exe.bak"' | ||
| - fi | ||
| - | ||
| - wine64 "${WINEPREFIX}/dosdevices/c:/Program Files (x86)/Battle.net/Battle.net Launcher.exe" "battlenet://D3" | ||
| - type: file | ||
| path: com.blizzard.Diablo3.appdata.xml | ||
| - type: file | ||
| path: com.blizzard.Diablo3.desktop | ||
| - type: file | ||
| path: com.blizzard.Diablo3.svg | ||
|
|
||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're basing off the base app but not using the battlenet-installer, can you please update the manifest to mirror the style of the StarCraft2 module: https://github.com/winepak/applications/blob/master/com.blizzard.StarCraft2/com.blizzard.StarCraft2.yml#L53
The battlenet:// shortcut is
battlenet://D3Source: b1f2837