Updated changelog.
This commit is contained in:
@@ -78,6 +78,64 @@ setup_and_run_downloadable() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Enhanced function to handle downloadable games with direct URL support
|
||||||
|
setup_and_run_downloadable_url() {
|
||||||
|
local downloadUrl="$1"
|
||||||
|
local gameDir="$2"
|
||||||
|
local executable="$3"
|
||||||
|
local fallbackUrl="$4"
|
||||||
|
local needNvda="$5"
|
||||||
|
local extractDir="$HOME/.local/games/$gameDir"
|
||||||
|
local tempZip="/tmp/${gameDir}_download.zip"
|
||||||
|
|
||||||
|
# Check if game is already installed
|
||||||
|
if [[ -e "$extractDir/$executable" ]]; then
|
||||||
|
run_wine "$gameDir" "./$executable" "$needNvda"
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Download the game
|
||||||
|
echo "Downloading $gameDir..."
|
||||||
|
if curl -L -o "$tempZip" "$downloadUrl"; then
|
||||||
|
# Recreate extractDir
|
||||||
|
rm -rf "$extractDir"
|
||||||
|
mkdir -p "$extractDir"
|
||||||
|
|
||||||
|
# Get the first path component of each file in the zip
|
||||||
|
mapfile -t topDirs < <(unzip -l "$tempZip" | awk 'NR>3 {print $4}' | grep '/$' | cut -d/ -f1 | sort -u | grep -v '^$')
|
||||||
|
if [[ ${#topDirs[@]} -eq 1 ]]; then
|
||||||
|
# Zip has a single top-level dir - extract to ~/.local/games, then rename
|
||||||
|
unzip -q "$tempZip" -d ~/.local/games
|
||||||
|
# If the extracted dir name differs from gameDir, rename it
|
||||||
|
if [[ "${topDirs[0]}" != "$gameDir" ]]; then
|
||||||
|
mv ~/.local/games/"${topDirs[0]}" "$extractDir"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
# Unzips file into the given directory without creating a subdirectory
|
||||||
|
unzip -q "$tempZip" -d "$extractDir"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Copy NVDA DLLs
|
||||||
|
for i in 32 64; do
|
||||||
|
find "$extractDir" -type f -name "nvdaControllerClient${i}.dll" -exec cp -v "$HOME/.local/games/nvda/nvdaControllerClient${i}.dll" '{}' \;
|
||||||
|
done
|
||||||
|
|
||||||
|
rm -f "$tempZip"
|
||||||
|
echo "Download and installation complete!"
|
||||||
|
|
||||||
|
# Now run the game
|
||||||
|
if [[ -e "$extractDir/$executable" ]]; then
|
||||||
|
run_wine "$gameDir" "./$executable" "$needNvda"
|
||||||
|
else
|
||||||
|
echo "Error: Game executable not found after installation"
|
||||||
|
run_web "$fallbackUrl"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
echo "Download failed, opening fallback URL"
|
||||||
|
run_web "$fallbackUrl"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
# Function to handle all web-based games
|
# Function to handle all web-based games
|
||||||
run_web() {
|
run_web() {
|
||||||
orca &
|
orca &
|
||||||
@@ -377,6 +435,12 @@ case "$GAME" in
|
|||||||
"Wicked Quest")
|
"Wicked Quest")
|
||||||
run_native "wicked-quest" "wicked_quest.py"
|
run_native "wicked-quest" "wicked_quest.py"
|
||||||
;;
|
;;
|
||||||
|
"Wreckingball")
|
||||||
|
setup_and_run_downloadable_url "https://sightlesswolf.com/wreckingball.zip" "wreckingball" "wreckingball.exe" "https://sightlesswolf.com" "nvda2speechd"
|
||||||
|
;;
|
||||||
|
"Wreckingball (Pulped)")
|
||||||
|
setup_and_run_downloadable_url "https://sightlesswolf.com/wreckingball-pulped.zip" "wreckingball-pulped" "wreckingball.exe" "https://sightlesswolf.com" "nvda2speechd"
|
||||||
|
;;
|
||||||
"Kitchensinc")
|
"Kitchensinc")
|
||||||
pushd "/home/stormux/.wine32/drive_c/Program Files/Kitchen's Sink"
|
pushd "/home/stormux/.wine32/drive_c/Program Files/Kitchen's Sink"
|
||||||
WINEPREFIX=/home/stormux/.wine32 /home/stormux/.local/wine32/bin/wine gamemenu.exe
|
WINEPREFIX=/home/stormux/.wine32 /home/stormux/.local/wine32/bin/wine gamemenu.exe
|
||||||
|
|||||||
@@ -3,6 +3,16 @@
|
|||||||
Dates are given for the image. All items listed are available for the listed image version coinciding with the listed date. For example, everything listed under may 7, 2025 are available in the image named stormux_gaming_image-2025.05.07.img.xz.
|
Dates are given for the image. All items listed are available for the listed image version coinciding with the listed date. For example, everything listed under may 7, 2025 are available in the image named stormux_gaming_image-2025.05.07.img.xz.
|
||||||
|
|
||||||
|
|
||||||
|
## October 1, 2025
|
||||||
|
|
||||||
|
- Wine configuration update (x86_64)
|
||||||
|
- System updates
|
||||||
|
- Update Toby Doom
|
||||||
|
- Extend install system to get games not included in the image
|
||||||
|
- Work on system to require fewer reinstallations
|
||||||
|
- Update Wicked Quest
|
||||||
|
|
||||||
|
|
||||||
## September 1, 2025
|
## September 1, 2025
|
||||||
|
|
||||||
- Fixed bug causing Crazy Party to not launch
|
- Fixed bug causing Crazy Party to not launch
|
||||||
|
|||||||
+5
-4
@@ -2,9 +2,10 @@
|
|||||||
|
|
||||||
gitUrl="https://git.stormux.org/storm/gaming-image-files"
|
gitUrl="https://git.stormux.org/storm/gaming-image-files"
|
||||||
gitPath="${gitUrl##*/}"
|
gitPath="${gitUrl##*/}"
|
||||||
pushd /tmp
|
pushd /tmp || exit
|
||||||
git clone "${gitUrl}"
|
git clone "${gitUrl}"
|
||||||
pushd "${gitPath}"
|
pushd "${gitPath}" || exit
|
||||||
|
git checkout testing
|
||||||
git lfs pull
|
git lfs pull
|
||||||
# Files and directories to ignore when copying
|
# Files and directories to ignore when copying
|
||||||
ignoreFiles=(".git" "./image" ".git*")
|
ignoreFiles=(".git" "./image" ".git*")
|
||||||
@@ -21,8 +22,8 @@ done
|
|||||||
find . "${findArgs[@]}" -type f -exec bash -c 'for i ; do cp -av --preserve=all --parents "${i}" /;done' _ "{}" \;
|
find . "${findArgs[@]}" -type f -exec bash -c 'for i ; do cp -av --preserve=all --parents "${i}" /;done' _ "{}" \;
|
||||||
# Fix ownership of home directory files
|
# Fix ownership of home directory files
|
||||||
chown -R stormux:users /home/stormux
|
chown -R stormux:users /home/stormux
|
||||||
popd
|
popd || exit
|
||||||
rm -rf "${gitPath}"
|
rm -rf "${gitPath}"
|
||||||
popd
|
popd || exit
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ import configparser
|
|||||||
import pathlib
|
import pathlib
|
||||||
import re
|
import re
|
||||||
import simpleaudio as sa
|
import simpleaudio as sa
|
||||||
|
import json
|
||||||
|
|
||||||
class VoicedMenu:
|
class VoicedMenu:
|
||||||
def __init__(self, title="Stormux Game Menu"):
|
def __init__(self, title="Stormux Game Menu"):
|
||||||
@@ -58,6 +59,37 @@ class VoicedMenu:
|
|||||||
# Track playing sound
|
# Track playing sound
|
||||||
self.currentSound = None
|
self.currentSound = None
|
||||||
|
|
||||||
|
# Load downloadable games registry
|
||||||
|
self.downloadable_games = self.load_downloadable_games()
|
||||||
|
|
||||||
|
def load_downloadable_games(self):
|
||||||
|
"""Load downloadable games registry from JSON file"""
|
||||||
|
registry_path = "/usr/share/stormux/downloadable_games.json"
|
||||||
|
try:
|
||||||
|
if os.path.exists(registry_path):
|
||||||
|
with open(registry_path, 'r') as f:
|
||||||
|
data = json.load(f)
|
||||||
|
return data.get('downloadable_games', {})
|
||||||
|
return {}
|
||||||
|
except Exception as e:
|
||||||
|
print(f"Error loading downloadable games registry: {e}")
|
||||||
|
return {}
|
||||||
|
|
||||||
|
def is_game_installed(self, game_id):
|
||||||
|
"""Check if a downloadable game is installed"""
|
||||||
|
if game_id not in self.downloadable_games:
|
||||||
|
return True # Not a downloadable game, assume installed
|
||||||
|
|
||||||
|
game_info = self.downloadable_games[game_id]
|
||||||
|
game_dir = os.path.expanduser(f"~/.local/games/{game_info['directory']}")
|
||||||
|
return os.path.exists(game_dir) and os.path.exists(os.path.join(game_dir, game_info['executable']))
|
||||||
|
|
||||||
|
def get_display_name(self, game_name, game_id=None):
|
||||||
|
"""Get display name for menu item, adding (not installed) if needed"""
|
||||||
|
if game_id and game_id in self.downloadable_games and not self.is_game_installed(game_id):
|
||||||
|
return f"{game_name} (not installed)"
|
||||||
|
return game_name
|
||||||
|
|
||||||
def init_speech(self):
|
def init_speech(self):
|
||||||
"""Initialize the speech client"""
|
"""Initialize the speech client"""
|
||||||
try:
|
try:
|
||||||
@@ -996,6 +1028,8 @@ if __name__ == "__main__":
|
|||||||
menu.add_item("Arcade", "Toy Mania", "GAME='Toy Mania' startx")
|
menu.add_item("Arcade", "Toy Mania", "GAME='Toy Mania' startx")
|
||||||
menu.add_item("Arcade", "Villains From Beyond", "GAME='Villains From Beyond' startx")
|
menu.add_item("Arcade", "Villains From Beyond", "GAME='Villains From Beyond' startx")
|
||||||
menu.add_item("Arcade", "Wicked Quest", "GAME='Wicked Quest' startx")
|
menu.add_item("Arcade", "Wicked Quest", "GAME='Wicked Quest' startx")
|
||||||
|
menu.add_item("Arcade", menu.get_display_name("Wreckingball", "wreckingball"), "GAME='Wreckingball' startx")
|
||||||
|
menu.add_item("Arcade", menu.get_display_name("Wreckingball (Pulped)", "wreckingball-pulped"), "GAME='Wreckingball (Pulped)' startx")
|
||||||
menu.add_item("Arcade", "Zombowl", "GAME='Zombowl' startx")
|
menu.add_item("Arcade", "Zombowl", "GAME='Zombowl' startx")
|
||||||
|
|
||||||
# Add board and card games section
|
# Add board and card games section
|
||||||
@@ -1103,6 +1137,7 @@ if __name__ == "__main__":
|
|||||||
menu.add_item("System", "Set Timezone", "GAME='Set Timezone' /home/stormux/.clirc")
|
menu.add_item("System", "Set Timezone", "GAME='Set Timezone' /home/stormux/.clirc")
|
||||||
menu.add_item("System", "Upload Files", "/home/stormux/.local/upload_server/uploader.py")
|
menu.add_item("System", "Upload Files", "/home/stormux/.local/upload_server/uploader.py")
|
||||||
menu.add_item("System", "Download Files", "/home/stormux/.local/download_server.py")
|
menu.add_item("System", "Download Files", "/home/stormux/.local/download_server.py")
|
||||||
|
menu.add_item("System", "Update System", "sudo /usr/local/bin/live-update.sh")
|
||||||
menu.add_item("System", "Restart: Can Take Several Minutes", "sudo reboot")
|
menu.add_item("System", "Restart: Can Take Several Minutes", "sudo reboot")
|
||||||
menu.add_item("System", "Power Off: Wait 2 Minutes Before Disconnecting Power", "sudo poweroff")
|
menu.add_item("System", "Power Off: Wait 2 Minutes Before Disconnecting Power", "sudo poweroff")
|
||||||
# Service menu items will be added dynamically in run() method via update_service_menu_items()
|
# Service menu items will be added dynamically in run() method via update_service_menu_items()
|
||||||
|
|||||||
Executable
+32
@@ -0,0 +1,32 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Update system packages (run as stormux user since yay shouldn't run as root)
|
||||||
|
sudo -u stormux yay -Syu --noconfirm --removemake --cleanafter
|
||||||
|
|
||||||
|
gitUrl="https://git.stormux.org/storm/gaming-image-files"
|
||||||
|
gitPath="${gitUrl##*/}"
|
||||||
|
pushd /tmp || exit
|
||||||
|
git clone "${gitUrl}"
|
||||||
|
pushd "${gitPath}" || exit
|
||||||
|
git checkout master
|
||||||
|
git lfs pull
|
||||||
|
# Files and directories to ignore when copying
|
||||||
|
ignoreFiles=(".git" "./image" ".git*" "/home/stormux/.w3m")
|
||||||
|
# Build find command with ignore patterns
|
||||||
|
findArgs=()
|
||||||
|
for ignore in "${ignoreFiles[@]}"; do
|
||||||
|
if [[ "$ignore" == .* && "$ignore" != ./* ]]; then
|
||||||
|
findArgs+=(-name "$ignore" -prune -o)
|
||||||
|
else
|
||||||
|
findArgs+=(-path "$ignore" -prune -o)
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
# Copy all files as root (preserves permissions properly)
|
||||||
|
find . "${findArgs[@]}" -type f -exec bash -c 'for i ; do cp -av --preserve=all --parents "${i}" /;done' _ "{}" \;
|
||||||
|
# Fix ownership of home directory files
|
||||||
|
chown -R stormux:users /home/stormux
|
||||||
|
popd || exit
|
||||||
|
rm -rf "${gitPath}"
|
||||||
|
popd || exit
|
||||||
|
|
||||||
|
exit 0
|
||||||
Reference in New Issue
Block a user