diff --git a/CMake/platforms/miyoo_mini.cmake b/CMake/platforms/miyoo_mini.cmake index 452f9a5588a..95924fa49aa 100644 --- a/CMake/platforms/miyoo_mini.cmake +++ b/CMake/platforms/miyoo_mini.cmake @@ -1,4 +1,3 @@ -set(BUILD_ASSETS_MPQ OFF) set(USE_SDL1 ON) set(NONET ON) set(DEVILUTIONX_SYSTEM_LIBFMT OFF) diff --git a/Packaging/miyoo_mini/build.sh b/Packaging/miyoo_mini/build.sh index e4458aaa09b..827f9e8f3fd 100755 --- a/Packaging/miyoo_mini/build.sh +++ b/Packaging/miyoo_mini/build.sh @@ -25,6 +25,7 @@ cmake_configure() { -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_TOOLCHAIN_FILE="${PACKAGING_DIR}/toolchainfile.cmake" \ -DBUILD_TESTING=OFF \ + -DDISABLE_DEMOMODE=ON \ "$@" } @@ -49,7 +50,7 @@ build_custom_sdl() { # change back to devilutionx root cd "$PACKAGING_DIR/../.." - cp -rfL "$BUILD_DIR/CustomSDL/build/.libs/libSDL-1.2.so.0" "$BUILD_DIR/OnionOS/Roms/PORTS/Binaries/Diablo.port/lib/libSDL-1.2.so.0" + cp -rfL "$BUILD_DIR/CustomSDL/build/.libs/libSDL-1.2.so.0" "$BUILD_DIR/OnionOS/Roms/PORTS/Games/Diablo (DevilutionX)/lib/libSDL-1.2.so.0" } prepare_onion_skeleton() { @@ -58,26 +59,17 @@ prepare_onion_skeleton() { # Copy basic skeleton cp -rf Packaging/miyoo_mini/skeleton_OnionOS/* $BUILD_DIR/OnionOS - # ensure devilutionx asset dir - mkdir -p $BUILD_DIR/OnionOS/Roms/PORTS/Binaries/Diablo.port/assets - # ensure lib dir for custom SDL - mkdir -p $BUILD_DIR/OnionOS/Roms/PORTS/Binaries/Diablo.port/lib - - # ensure config dir - mkdir -p $BUILD_DIR/OnionOS/Saves/CurrentProfile/config/DevilutionX - - # ensure save dir - mkdir -p $BUILD_DIR/OnionOS/Saves/CurrentProfile/saves/DevilutionX + mkdir -p "$BUILD_DIR/OnionOS/Roms/PORTS/Games/Diablo (DevilutionX)/lib" } package_onion() { prepare_onion_skeleton build_custom_sdl - # copy assets - cp -rf $BUILD_DIR/assets/* $BUILD_DIR/OnionOS/Roms/PORTS/Binaries/Diablo.port/assets + # copy assets mpq + cp -f $BUILD_DIR/devilutionx.mpq "$BUILD_DIR/OnionOS/Roms/PORTS/Games/Diablo (DevilutionX)/devilutionx.mpq" # copy executable - cp -f $BUILD_DIR/devilutionx $BUILD_DIR/OnionOS/Roms/PORTS/Binaries/Diablo.port/devilutionx + cp -f $BUILD_DIR/devilutionx "$BUILD_DIR/OnionOS/Roms/PORTS/Games/Diablo (DevilutionX)/devilutionx" rm -f $BUILD_DIR/onion.zip diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Binaries/Diablo.port/launch.sh b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Binaries/Diablo.port/launch.sh deleted file mode 100644 index 9741b1d6969..00000000000 --- a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Binaries/Diablo.port/launch.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -progdir=`cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P` -savedir="/mnt/SDCARD/Saves/CurrentProfile/saves/DevilutionX" -configdir="/mnt/SDCARD/Saves/CurrentProfile/config/DevilutionX" - -cd $progdir - -if [ -f "./FILES_HERE/DIABDAT.MPQ" ] || [ -f "./FILES_HERE/spawn.mpq" ]; then - # Timer initialisation - cd /mnt/SDCARD/App/PlayActivity - ./playActivity "init" - - export LD_LIBRARY_PATH="$progdir/lib:$LD_LIBRARY_PATH" - SDL_HIDE_BATTERY=1 $progdir/devilutionx --data-dir $progdir/FILES_HERE --save-dir $savedir --config-dir $configdir - - # Timer registration - cd /mnt/SDCARD/App/PlayActivity - ./playActivity "Diablo" -else - cd "/mnt/SDCARD/Emu/PORTS/Binaries/missingFile" - ./infoPanel -fi diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Diablo.port b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Diablo.port deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Games/Diablo (devilutionX)/_required_files.txt b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Games/Diablo (devilutionX)/_required_files.txt new file mode 100644 index 00000000000..11f9542931c --- /dev/null +++ b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Games/Diablo (devilutionX)/_required_files.txt @@ -0,0 +1,9 @@ +Directory tree for "Diablo (DevilutionX)" +| +| devilutionx +| devilutionx.mpq +| DIABDAT.MPQ +| _required_files.txt +| +\---lib + libSDL-1.2.so.0 diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Imgs/Diablo.png b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Imgs/Diablo (DevilutionX).png similarity index 100% rename from Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Imgs/Diablo.png rename to Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Imgs/Diablo (DevilutionX).png diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Shortcuts/Action/Diablo (DevilutionX).notfound b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Shortcuts/Action/Diablo (DevilutionX).notfound new file mode 100644 index 00000000000..1c50d68f500 --- /dev/null +++ b/Packaging/miyoo_mini/skeleton_OnionOS/Roms/PORTS/Shortcuts/Action/Diablo (DevilutionX).notfound @@ -0,0 +1,28 @@ +#!/bin/sh +# Standalone Ports Script Template + +# main configuration : +GameName="Diablo (DevilutionX)" +GameDir="Diablo (DevilutionX)" +GameExecutable="devilutionx" +GameDataFile="DIABDAT.MPQ" + +# additional configuration : +KillAudioserver=0 +PerformanceMode=0 + +# specific to this port : +FullGamePath="/mnt/SDCARD/Roms/PORTS/Games/$GameDir" + +savedir="/mnt/SDCARD/Saves/CurrentProfile/saves/DevilutionX" +configdir="/mnt/SDCARD/Saves/CurrentProfile/config/DevilutionX" +mkdir -p "$savedir" +mkdir -p "$configdir" + +export SDL_HIDE_BATTERY=1 + +Arguments="--data-dir \"$FullGamePath\" --save-dir \"$savedir\" --config-dir \"$configdir\" --diablo" + + +# running command line : +/mnt/SDCARD/Emu/PORTS/launch_standalone.sh "$GameName" "$GameDir" "$GameExecutable" "$Arguments" "$GameDataFile" "$KillAudioserver" "$PerformanceMode" diff --git a/Packaging/miyoo_mini/skeleton_OnionOS/readme.txt b/Packaging/miyoo_mini/skeleton_OnionOS/readme.txt index ffa39b30e2b..c04f1411bde 100644 --- a/Packaging/miyoo_mini/skeleton_OnionOS/readme.txt +++ b/Packaging/miyoo_mini/skeleton_OnionOS/readme.txt @@ -1,19 +1,19 @@ -devilutionx(Diablo port) for OnionOS +DevilutionX (Diablo port) for OnionOS ==================================== Installation -------- - Activate the Ports Collection inside the Onion Installer on your device -- Copy everything from this archive to the root of your sd card +- Copy the Roms folder from this archive to the root of your sd card For the full game: - - Get the DIABDAT.MPQ from either the CD or GOG release (https://github.com/diasurgical/devilutionX/wiki/Extracting-the-.MPQs-from-the-GoG-installer) - - Copy the DIABDAT.MPQ into Roms/PORTS/Binaries/Diablo.port/FILES_HERE + - Get the DIABDAT.MPQ from the CD, GOG or Battle.net release (https://github.com/diasurgical/devilutionX/wiki/Extracting-the-.MPQs-from-the-GoG-installer) + - Copy the DIABDAT.MPQ into Roms/PORTS/Games/Diablo (DevilutionX) - Optional: If you want to also play the Hellfire expansion, copy hellfire.mpq, hfmonk.mpq, hfmusic.mpq, hfvoice.mpq into the same folder For the free shareware version: - - Get the spawn.mpq (https://github.com/diasurgical/devilutionx-assets/releases/latest/download/spawn.mpq) - - Copy the spawn.mpq into Roms/PORTS/Binaries/Diablo.port/FILES_HERE + - Get the spawn.mpq (https://github.com/diasurgical/devilutionx-assets/releases/download/v2/spawn.mpq) + - Copy the spawn.mpq into Roms/PORTS/Games/Diablo (DevilutionX) Controls --------