From 908e17ee1f85472237aae329f8605a985841a4e8 Mon Sep 17 00:00:00 2001 From: Andrew Opalach Date: Thu, 21 Jul 2022 22:02:57 -0400 Subject: temporary fix for new assets, major cleanup --- scripts/random.sh | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100755 scripts/random.sh (limited to 'scripts') diff --git a/scripts/random.sh b/scripts/random.sh new file mode 100755 index 0000000..446a4a4 --- /dev/null +++ b/scripts/random.sh @@ -0,0 +1,32 @@ +#!/bin/bash + +#cd "$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" + +WALLPAPERS_PATH=workshop_wallpapers_11-8-21 +BUILD_DIR=build-release + +export mesa_glthread=true + +if [[ $1 == "audio" ]] +then + while : ; do + DIR=$(find $WALLPAPERS_PATH -maxdepth 1 -type d | shuf -n 1) + RES=$(cat $DIR/project.json | jq '.["general"]["supportsaudioprocessing"]') + [[ "$RES" == 'null' || "$RES" == 'false' ]] || break + done +elif [[ $1 == "safe" ]] +then + while : ; do + DIR=$(find $WALLPAPERS_PATH -maxdepth 1 -type d | shuf -n 1) + RES=$(cat $DIR/project.json | jq '.["contentrating"]') + [[ "$RES" == 'null' || "$RES" != '"Everyone"' ]] || break + done +else + DIR=$(find $WALLPAPERS_PATH -maxdepth 1 -type d | shuf -n 1) +fi + +echo $DIR + +cd $BUILD_DIR +./mauri ../$DIR/scene.pkg +cd .. -- cgit v1.2.3-101-g0448