From 2328c77e509fe93dc85542d95855e7472234dcd2 Mon Sep 17 00:00:00 2001 From: Jake Smarter Date: Sun, 3 Mar 2024 23:59:59 +0000 Subject: [PATCH] =?UTF-8?q?Drop=20local=20AppStream=20meta=20data=20in=20f?= =?UTF-8?q?avor=20of=20upstream=20Externalize=20launch=20script=20into=20a?= =?UTF-8?q?=20separate=20file=20Enable=20Wayland=20support=20following=20l?= =?UTF-8?q?uciusDXL/TheForceEngine#386=20Move=20installing=20the=20launch?= =?UTF-8?q?=20script=20into=20a=20separate=20`module`=20Use=20Flatpak=20Bu?= =?UTF-8?q?ilder=20environment=20variables=20where=20applicable=20Fix=20gi?= =?UTF-8?q?t=20tag=20pattern=20checker=20Change=20`buildsystem`=20to=20`cm?= =?UTF-8?q?ake`=20Move=20editing=20the=20Desktop=20Entry=20file=20to=20`po?= =?UTF-8?q?st-install`=20step=20Add=20Flatpak=20extension=20support=20for?= =?UTF-8?q?=20mods=20following=20luciusDXL/TheForceEngine#393=20Externaliz?= =?UTF-8?q?e=20the=20default=20=E2=80=9CAdjustableHud=E2=80=9D=20mod=20int?= =?UTF-8?q?o=20a=20separate=20but=20bundled=20Flatpak=20`.Mod`=20extension?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- io.github.theforceengine.tfe.metainfo.xml | 110 ---------------------- io.github.theforceengine.tfe.sh | 14 +++ io.github.theforceengine.tfe.yml | 88 +++++++++-------- 3 files changed, 64 insertions(+), 148 deletions(-) delete mode 100644 io.github.theforceengine.tfe.metainfo.xml create mode 100755 io.github.theforceengine.tfe.sh diff --git a/io.github.theforceengine.tfe.metainfo.xml b/io.github.theforceengine.tfe.metainfo.xml deleted file mode 100644 index 33e2047..0000000 --- a/io.github.theforceengine.tfe.metainfo.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - io.github.theforceengine.tfe - The Force Engine - - “The Force Engine” Contributors - Die Mitwirkenden an „The Force Engine“ - Współautorzy „The Force Engine” - https://theforceengine.github.io - - A modern cross‑platform port of “STAR WARS: Dark Forces” with mod support - Eine moderne Plattformen übergreifende Portierung von „STAR WARS: Dark Forces“ mit Unterstützung für Modifikationen - Nowoczesna wieloplatformowa konwersja „STAR WARS: Dark Forces” z obsługą modyfikacji - CC0-1.0 - GPL-2.0 - io.github.theforceengine.tfe.desktop - https://theforceengine.github.io - https://github.com/luciusDXL/TheForceEngine/issues - https://theforceengine.github.io/Documentation.html - https://github.com/luciusDXL/TheForceEngine - -

“The Force Engine” is a modernised, reverse engineered port of the “Jedi Engine” used in “STAR WARS: Dark Forces” and “Outlaws”. Currently, only “STAR WARS: Dark Forces” is supported but there are already many technical and quality‑of‑life improvements:

-

„The Force Engine“ ist eine modernisierte, rekonstruierte Portierung der in „STAR WARS: Dark Forces“ und „Outlaws“ verwendeten „Jedi Engine“. Derzeit wird ausschließlich „STAR WARS: Dark Forces“ unterstützt, aber es gibt bereits viele technische und das Leben erleichternde Verbesserungen:

-

“The Force Engine” is a modernized, reverse engineered port of the “Jedi Engine” used in “STAR WARS: Dark Forces” and “Outlaws”. Currently, only “STAR WARS: Dark Forces” is supported but there are already many technical and quality‑of‑life improvements:

-

„The Force Engine”, to unowocześniona konwersja, odwrotnie inżynierowanego „Jedi Engine”, który wykorzystywano do „STAR WARS: Dark Forces” i „Outlaws”. Na ten czas, wyłącznie „STAR WARS: Dark Forces” jest obsługiwane, lecz istnieje już wiele technicznych i życie ułatwiających ulepszeń:

-
    -
  • Controller support (except in menus)
  • -
  • Unterstützung von Steuerߛ und Eingabegeräten, ausgenommen in Menüs
  • -
  • Obsługa kontrolerów, za wyjątkiem w menu
  • -
  • Support for mouselook like in modern first‑person shooters
  • -
  • Unterstützung von Mausumsicht, wie in modernen Ego‑Shootern
  • -
  • Obsługa patrzenia myszą, jak w nowoczesnych pierwszoosobowych strzelankach
  • -
  • Complete input remapping for in‑game controls
  • -
  • Komplett frei belegbare Steuerung
  • -
  • Kompletnie dowolnie przypięcie akcji sterowania gry
  • -
  • Widescreen and high‑resolution support
  • -
  • Unterstützung von Breitbildschirmen und hohen Auflösungen
  • -
  • Obsługa szerokich ekranów i wysokich rozdzielczości
  • -
  • Texture filtering and bloom effects on light sources
  • -
  • Texturfilter und Lichteffekte auf Lichtquellen
  • -
  • Filtr tekstur i efekty lśnienia źródeł światła
  • -
  • Subtitles for dialog (including in‑game incidental dialog)
  • -
  • Dialoguntertitel einschließlich situativer Dialoge im Spiel
  • -
  • Podtytuły dialogów, w tym okolicznościowych
  • -
  • Closed captioning for important audio cues in the game
  • -
  • Untertitel bei wichtigen Audiohinweisen im Spiel
  • -
  • Napisy przy ważnych sygnałach dźwiękowych w grze
  • -
  • Translation support for subtitles/captions
  • -
  • Unterstützung von Übersetzungen für Untertitel
  • -
  • Obsługa przetłumaczonych podtytułów i napisów
  • -
  • A built‑in mod loader
  • -
  • Verbesserte Unterstützung für Mods mit integriertem Lademenü
  • -
  • Wbudowany ładownik modyfikacji
  • -
-

Future plans include built‑in tools for creating mods and maps for the games as well as Outlaws support.

-

Zukünftige Pläne beinhalten Werkzeuge zur Erstellung von Modifikationen und Karten für Spiele, sowie die Unterstützung von „Outlaws“.

-

Przyszłe plany zawierają narzędzia tworzenia modyfikacji i map do gier, jak i obsługę „Outlaws”.

-
- - - https://theforceengine.github.io/screenshots/media1.jpg - “Retro” mode: 4:3 aspect ratio and original game resolution, scaled up to modern full screen sizes - Der „Retro‑Modus“ im 4:3‑Seitenverhältnis und Originalspielauflösung hoch skaliert auf moderne Vollbildgrößen - Tryb „Retro”, stosunek stron 4 do 3 i oryginalna rozdzielczość gry, przeskalowany na nowoczesne pełnoekranowe rozmiary - - - https://theforceengine.github.io/screenshots/media3.jpg - The first level in high resolution - Die erste Mission in hoher Auflösung - Pierwszy poziom w wysokiej rozdzielczości - - - https://theforceengine.github.io/screenshots/media7.jpg - Load/Save menus with screenshots, timestamps, and custom save game names - Lade‑ und Speichermenüs mit Bildschirmfotos, Zeitstempeln und beschriftbaren Spielständen - Menu ładowania i zapisywania stanu gry z zrzutami ekranu, datami i o dowolnych nazwach - - - https://theforceengine.github.io/screenshots/media6.jpg - Animated in‑game 3D objects - Animierte 3D‑Objekte im Spiel - W grze animowane obiekty 3D - - - - Game - Shooter - ActionGame - - - - - - intense - - https://theforceengine.github.io/ - - gamepad - - - keyboard - pointing - - - offline-only - - - theforceengine - -
diff --git a/io.github.theforceengine.tfe.sh b/io.github.theforceengine.tfe.sh new file mode 100755 index 0000000..f054389 --- /dev/null +++ b/io.github.theforceengine.tfe.sh @@ -0,0 +1,14 @@ +#!/usr/bin/sh +# Check for game data +set -e +if [[ -z "$TFE_SKIP_DATACHECK" ]] && \ + [[ -z $(find "$XDG_DATA_HOME" -iname 'DARK.GOB') ]] && \ + [[ ! -d "$HOME/.local/share/Steam/steamapps/common/Dark Forces/Game/" ]] && \ + [[ ! -d "$HOME/.var/app/com.valvesoftware.Steam/.local/share/Steam/steamapps/common/Dark Forces/Game/" ]]; then + zenity --error \ + --text "Could not find Dark Forces game data\\n\\nPlease either install Dark Forces via Steam to your default library path or copy the game data to $XDG_DATA_HOME/." \ + --ok-label 'Close' \ + --no-wrap +fi +export TFE_DATA_HOME='/app/share/TheForceEngine' +exec theforceengine diff --git a/io.github.theforceengine.tfe.yml b/io.github.theforceengine.tfe.yml index 8779a4d..60e98d1 100644 --- a/io.github.theforceengine.tfe.yml +++ b/io.github.theforceengine.tfe.yml @@ -1,20 +1,20 @@ -app-id: io.github.theforceengine.tfe +id: io.github.theforceengine.tfe runtime: org.freedesktop.Platform runtime-version: '23.08' -sdk: org.freedesktop.Sdk +sdk: org.freedesktop.Sdk//23.08 command: io.github.theforceengine.tfe.sh -rename-desktop-file: TheForceEngine.desktop -rename-icon: TheForceEngine build-options: - strip: true + strip: false no-debuginfo: true +separate-locales: false finish-args: # hardware 3D and controller access - --device=all # X11 + XShm access - --share=ipc - - --socket=x11 + - --socket=wayland + - --socket=fallback-x11 # Audio - --socket=pulseaudio # Access to the default Steam Dark Forces data directory for native and Flatpak installations @@ -29,49 +29,61 @@ modules: tag: v1.09.540 x-checker-data: type: git - tag-pattern: ^v([\\d.]+)$ + tag-pattern: ^v\\d+(\\.\\d+)+$ # Separate engine data from user data on Linux by setting PATH_USER_DOCUMENTS to XDG_HOME. - type: patch path: user_data.patch # Patch automatic detection of Dark Forces installation to only check default Steam path - type: patch path: game_data_detection.patch - # Include local metainfo.xml file until a TFE release is made that includes it - # https://github.com/luciusDXL/TheForceEngine/pull/375 - - type: file - path: io.github.theforceengine.tfe.metainfo.xml - # Add a wrapper script that points TFE_DATA_HOME to the correct location within the sandbox - - type: script - dest-filename: io.github.theforceengine.tfe.sh - commands: - # Check for game data - - | - set -e - if [[ -z "$TFE_SKIP_DATACHECK" ]] && \ - [[ -z $(find "$XDG_DATA_HOME" -iname 'dark.gob') ]] && \ - [[ ! -d "$HOME/.local/share/Steam/steamapps/common/Dark Forces/Game/" ]] && \ - [[ ! -d '/.var/app/com.valvesoftware.Steam/.local/share/Steam/steamapps/common/Dark Forces/Game/' ]]; then - zenity --error \ - --text "Could not find Dark Forces game data\\n\\nPlease either install Dark Forces via Steam to your default library path or copy the game data to $XDG_DATA_HOME/." \ - --ok-label 'Close' \ - --no-wrap - fi - export TFE_DATA_HOME='/app/share/TheForceEngine' - exec theforceengine - buildsystem: cmake-ninja + buildsystem: cmake config-opts: - -DDISABLE_SYSMIDI=ON builddir: true - build-commands: - # Install launcher script + post-install: + # Edit and install desktop launcher file - | set -e - install -Dm 0755 '../io.github.theforceengine.tfe.sh' -t '/app/bin' - # Edit and install desktop launcher file - desktop-file-edit --set-key=Exec --set-value='io.github.theforceengine.tfe.sh' '../TheForceEngine/TheForceEngine.desktop' - # Install locally-included appstream metadata file until a TFE release is made that includes it - # https://github.com/luciusDXL/TheForceEngine/pull/375 - install -Dm 0644 '../io.github.theforceengine.tfe.metainfo.xml' '/app/share/metainfo/io.github.theforceengine.tfe.metainfo.xml' + desktop-file-edit --set-key=Exec \ + --set-value="$FLATPAK_ID.sh" \ + "$FLATPAK_DEST/share/applications/$FLATPAK_ID.desktop" + install -Dvm 0644 \ + -t "$FLATPAK_DEST/share/TheForceEngine/Mods/share/metainfo" \ + "../TheForceEngine/$FLATPAK_ID.Mod.AdjustableHud.metainfo.xml" + appstream-compose --prefix="$FLATPAK_DEST/share/TheForceEngine/Mods" \ + --basename="$FLATPAK_ID.Mod.AdjustableHud" \ + --origin=flatpak \ + "$FLATPAK_ID.Mod.AdjustableHud" modules: - shared-modules/glu/glu-9.json - shared-modules/glew/glew.json + + # Add a wrapper script that points TFE_DATA_HOME to the correct location within the sandbox + - name: launch_script + sources: + - type: file + path: io.github.theforceengine.tfe.sh + buildsystem: simple + build-commands: + # Install launch script + - install -Dm 0755 "$FLATPAK_ID.sh" -t "$FLATPAK_DEST/bin" + +cleanup-commands: + - rm -vf "$FLATPAK_DEST/share/metainfo/$FLATPAK_ID.Mod.AdjustableHud.metainfo.xml" + +add-extensions: + # TFE’s mod extension point + io.github.theforceengine.tfe.Mod: + directory: share/TheForceEngine/Mods + merge-dirs: . + no-autodownload: true + autodelete: false + bundle: false + subdirectories: true + # AdjustableHud mod bundled with TFE + io.github.theforceengine.tfe.Mod.AdjustableHud: + directory: share/TheForceEngine/Mods + no-autodownload: false + autodelete: true + bundle: true + subdirectories: false