From 9f895166fd353683ba1b04b7fd56e07f531b212a Mon Sep 17 00:00:00 2001 From: Mattia Basaglia Date: Thu, 5 Feb 2015 19:25:00 +0100 Subject: [PATCH] Minor tweaks to the minigame texture build script --- gfx/minigames/build.sh | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/gfx/minigames/build.sh b/gfx/minigames/build.sh index 49e0e4a..5e47774 100755 --- a/gfx/minigames/build.sh +++ b/gfx/minigames/build.sh @@ -7,7 +7,7 @@ MKDIR="mkdir -p" OUT_DIR=/tmp/minigames JPEG_QUALITY=75 TEXTURE_SIZE=2048 -FORMAT=png +FORMAT=tga # Converts images into $FORMAT # Synopsis: convert_image input.png output @@ -56,9 +56,9 @@ function scale_image() # Create the files for packaging function generate() { - for src_file in $(git ls-files) + for src_file in $(git ls-files '*/*') do - local out_dir="$OUT_DIR/gfx/hud/default/" + local out_dir="$OUT_DIR/gfx/hud/default/minigames/" local out_file="$out_dir/$src_file" $MKDIR "$out_dir/$(dirname "$src_file")" @@ -69,10 +69,9 @@ function generate() [ "$file_extension" != "$FORMAT" ] then out_file="$base_file.$FORMAT" - echo "$base_file" if [ "$src_file" -nt "$out_file" ] then - echo -e "Compressing \x1b[1m$src_file\x1b[0m" + echo -e "Converting \x1b[1m$src_file\x1b[0m" convert_image "$src_file" "$base_file" scale_image "$base_file" continue -- 2.39.2