PortsMaster / PortMaster-New

New PortMaster repo
https://www.portmaster.games
MIT License
82 stars 83 forks source link

Port Issue: Quake #592

Open JeodC opened 3 months ago

JeodC commented 3 months ago

The Quake.sh file needs some attention to account for cfw changes.

JeodC commented 3 months ago

Example with current CFWs used in script. May need to add more such as Knulli and CrossMix.

#!/bin/sh

XDG_DATA_HOME=${XDG_DATA_HOME:-$HOME/.local/share}

# Determine the control folder
if [ -d "/opt/system/Tools/PortMaster/" ]; then
  controlfolder="/opt/system/Tools/PortMaster"
elif [ -d "/opt/tools/PortMaster/" ]; then
  controlfolder="/opt/tools/PortMaster"
elif [ -d "$XDG_DATA_HOME/PortMaster/" ]; then
  controlfolder="$XDG_DATA_HOME/PortMaster"
else
  controlfolder="/roms/ports/PortMaster"
fi

source $controlfolder/control.txt
source $controlfolder/device_info.txt

get_controls

# Determine RetroArch location and config based on CFW name
case "$CFW_NAME" in
  TheRA)
    raloc="/opt/retroarch/bin"
    raconf=""
    ;;
  RetroOZ)
    raloc="/opt/retroarch/bin"
    raconf="--config /home/odroid/.config/retroarch/retroarch.cfg"
    ;;
  *ArkOS*)
    raloc="/usr/local/bin"
    raconf=""
    ;;
  muOS)
    raloc="/usr/bin"
    # Check if retroarch.cfg exists on sd2
    if [ -f /mnt/sdcard/MUOS/retroarch/retroarch.cfg ]; then
      raconf="-v -f -c /mnt/sdcard/MUOS/retroarch/retroarch.cfg"
    elif [ -f /mnt/mmc/MUOS/retroarch/retroarch.cfg ]; then
      raconf="-v -f -c /mnt/mmc/MUOS/retroarch/retroarch.cfg"
    fi
    ;;
  *)
    raloc="/usr/bin"
    raconf=""
    ;;
esac

GAMEDIR="/$directory/ports/quake"

$GPTOKEYB "retroarch" &
$raloc/retroarch $raconf -L $GAMEDIR/tyrquake_libretro.so $GAMEDIR/quakepaks/id1/*