diff --git a/assets/armored_knight_1-256.png b/assets/armored_knight_1-256.png index b8617eb..cdd9c90 100644 Binary files a/assets/armored_knight_1-256.png and b/assets/armored_knight_1-256.png differ diff --git a/assets/axe_ranger-256.png b/assets/axe_ranger-256.png index a63718d..867de02 100644 Binary files a/assets/axe_ranger-256.png and b/assets/axe_ranger-256.png differ diff --git a/assets/ceiling_moss_brick_blue_light-256.png b/assets/ceiling_moss_brick_blue_light-256.png index 34617ac..ceaa33e 100644 Binary files a/assets/ceiling_moss_brick_blue_light-256.png and b/assets/ceiling_moss_brick_blue_light-256.png differ diff --git a/assets/ceiling_test-256.png b/assets/ceiling_test-256.png index 4bcac90..8ca552b 100644 Binary files a/assets/ceiling_test-256.png and b/assets/ceiling_test-256.png differ diff --git a/assets/enemies.json b/assets/enemies.json index ae2263d..884eb36 100644 --- a/assets/enemies.json +++ b/assets/enemies.json @@ -52,7 +52,7 @@ {"_type": "EnemyConfig", "ai_script": "Enemy::actions", "ai_start_name": "Enemy::initial_state", "ai_goal_name": "Enemy::final_state"}, {"_type": "Personality", "hearing_distance": 5, "tough": true}, {"_type": "Sprite", "name": "axe_ranger", "width": 256, "height": 256, "scale": 1.0}, - {"_type": "Animation", "easing": 3, "ease_rate": 0.5, "scale": 0.1, "simple": false, "frames": 2, "speed": 0.6, "stationary": false}, + {"_type": "Animation", "easing": 3, "ease_rate": 0.5, "scale": 0.1, "simple": true, "frames": 1, "speed": 0.6, "stationary": false}, {"_type": "Sound", "attack": "Sword_Hit_2", "death": "Ranger_1"} ] }, diff --git a/assets/floor_tile_test-256.png b/assets/floor_tile_test-256.png index 56a2c5e..435d1fb 100644 Binary files a/assets/floor_tile_test-256.png and b/assets/floor_tile_test-256.png differ diff --git a/assets/glowing_moss_wall-256.png b/assets/glowing_moss_wall-256.png index 2dc7ae4..0c15981 100644 Binary files a/assets/glowing_moss_wall-256.png and b/assets/glowing_moss_wall-256.png differ diff --git a/assets/gold_savior-256.png b/assets/gold_savior-256.png index c2da3eb..de66a7d 100644 Binary files a/assets/gold_savior-256.png and b/assets/gold_savior-256.png differ diff --git a/assets/gold_savior_oil-256.png b/assets/gold_savior_oil-256.png index 9375d03..987ae92 100644 Binary files a/assets/gold_savior_oil-256.png and b/assets/gold_savior_oil-256.png differ diff --git a/assets/hairy_spider-256.png b/assets/hairy_spider-256.png index be2b67f..1bed6f9 100644 Binary files a/assets/hairy_spider-256.png and b/assets/hairy_spider-256.png differ diff --git a/assets/large_stone_floor-256.png b/assets/large_stone_floor-256.png index 82c57ed..4561e5b 100644 Binary files a/assets/large_stone_floor-256.png and b/assets/large_stone_floor-256.png differ diff --git a/assets/torch_crappy-256.png b/assets/torch_crappy-256.png index 9e7bcdc..1fbab99 100644 Binary files a/assets/torch_crappy-256.png and b/assets/torch_crappy-256.png differ diff --git a/assets/torch_horizontal_floor-256.png b/assets/torch_horizontal_floor-256.png index 3c7c718..aad2ca6 100644 Binary files a/assets/torch_horizontal_floor-256.png and b/assets/torch_horizontal_floor-256.png differ diff --git a/assets/torch_pillar-256.png b/assets/torch_pillar-256.png index 9431f04..1b16004 100644 Binary files a/assets/torch_pillar-256.png and b/assets/torch_pillar-256.png differ diff --git a/assets/wall_texture_test-256.png b/assets/wall_texture_test-256.png index 217c625..c3bcb1d 100644 Binary files a/assets/wall_texture_test-256.png and b/assets/wall_texture_test-256.png differ diff --git a/scripts/magick/pixelize b/scripts/magick/pixelize new file mode 100644 index 0000000..8d1fc71 --- /dev/null +++ b/scripts/magick/pixelize @@ -0,0 +1,188 @@ +#!/bin/bash +# +# Developed by Fred Weinhaus 5/8/2008 .......... revised 4/25/2015 +# +# ------------------------------------------------------------------------------ +# +# Licensing: +# +# Copyright © Fred Weinhaus +# +# My scripts are available free of charge for non-commercial use, ONLY. +# +# For use of my scripts in commercial (for-profit) environments or +# non-free applications, please contact me (Fred Weinhaus) for +# licensing arrangements. My email address is fmw at alink dot net. +# +# If you: 1) redistribute, 2) incorporate any of these scripts into other +# free applications or 3) reprogram them in another scripting language, +# then you must contact me for permission, especially if the result might +# be used in a commercial or for-profit environment. +# +# My scripts are also subject, in a subordinate manner, to the ImageMagick +# license, which can be found at: http://www.imagemagick.org/script/license.php +# +# ------------------------------------------------------------------------------ +# +#### +# +# USAGE: pixelize [-s size] [-m mode] infile outfile +# USAGE: pixelize [-h or -help] +# +# OPTIONS: +# +# -s size pixelization size; size>0; default=3 +# -m mode mode of minimizing; 1=resize; 2=sample; default=1 +# +### +# +# NAME: PIXELIZE +# +# PURPOSE: To create a pixelized or blocky effect in an image. +# +# DESCRIPTION: PIXELIZE creates a pixelized or blocky effect in an +# image where more pixelization (larger sizes) create larger blocky +# effects. +# +# OPTIONS: +# +# -s size ... SIZE is the pixelization (block) size. Values are greater +# than 0. The default is 3. +# +# -m mode ... MODE is the mode of minimizing. Choices are 1 for -resize +# and 2 for -sample. The default=1 +# +# CAVEAT: No guarantee that this script will work on all platforms, +# nor that trapping of inconsistent parameters is complete and +# foolproof. Use At Your Own Risk. +# +###### +# + +# set default values +size=3 +mode=1 + +# set directory for temporary files +dir="." # suggestions are dir="." or dir="/tmp" + +# set up functions to report Usage and Usage with Description +PROGNAME=`type $0 | awk '{print $3}'` # search for executable on path +PROGDIR=`dirname $PROGNAME` # extract directory of program +PROGNAME=`basename $PROGNAME` # base name of program +usage1() + { + echo >&2 "" + echo >&2 "$PROGNAME:" "$@" + sed >&2 -e '1,/^####/d; /^###/g; /^#/!q; s/^#//; s/^ //; 4,$p' "$PROGDIR/$PROGNAME" + } +usage2() + { + echo >&2 "" + echo >&2 "$PROGNAME:" "$@" + sed >&2 -e '1,/^####/d; /^######/g; /^#/!q; s/^#*//; s/^ //; 4,$p' "$PROGDIR/$PROGNAME" + } + + +# function to report error messages +errMsg() + { + echo "" + echo $1 + echo "" + usage1 + exit 1 + } + + +# function to test for minus at start of value of second part of option 1 or 2 +checkMinus() + { + test=`echo "$1" | grep -c '^-.*$'` # returns 1 if match; 0 otherwise + [ $test -eq 1 ] && errMsg "$errorMsg" + } + +# test for correct number of arguments and get values +if [ $# -eq 0 ] + then + # help information + echo "" + usage2 + exit 0 +elif [ $# -gt 6 ] + then + errMsg "--- TOO MANY ARGUMENTS WERE PROVIDED ---" +else + while [ $# -gt 0 ] + do + # get parameter values + case "$1" in + -h|-help) # help information + echo "" + usage2 + exit 0 + ;; + -s) # get size + shift # to get the next parameter - scale + # test if parameter starts with minus sign + errorMsg="--- INVALID SIZE SPECIFICATION ---" + checkMinus "$1" + size=`expr "$1" : '\([0-9]*\)'` + [ "$size" = "" ] && errMsg "SIZE=$size MUST BE AN INTEGER" + sizetest=`echo "$size <= 0" | bc` + [ $sizetest -eq 1 ] && errMsg "--- SIZE=$size MUST BE A POSITIVE INTEGER ---" + ;; + -m) # get mode + shift # to get the next parameter - mode + # test if parameter starts with minus sign + errorMsg="--- INVALID MODE SPECIFICATION ---" + checkMinus "$1" + mode=`expr "$1" : '\([0-9]*\)'` + [ "$mode" = "" ] && errMsg "MODE=$mode MUST BE AN INTEGER" + [ $mode -ne 1 -a $mode -ne 2 ] && errMsg "--- MODE=$mode MUST BE EITHER 1 OR 2 ---" + ;; + -) # STDIN and end of arguments + break + ;; + -*) # any other - argument + errMsg "--- UNKNOWN OPTION ---" + ;; + *) # end of arguments + break + ;; + esac + shift # next option + done + # + # get infile and outfile + infile="$1" + outfile="$2" +fi + +# test that infile provided +[ "$infile" = "" ] && errMsg "NO INPUT FILE SPECIFIED" + +# test that outfile provided +[ "$outfile" = "" ] && errMsg "NO OUTPUT FILE SPECIFIED" + + +# test if image an ordinary, readable and non-zero size +if [ -f $infile -a -r $infile -a -s $infile ] + then + : 'Do Nothing' +else + errMsg "--- FILE $infile DOES NOT EXIST OR IS NOT AN ORDINARY FILE, NOT READABLE OR HAS ZERO SIZE ---" +fi + +# get parameters +w=`convert $infile -format "%[fx:w]" info:` +h=`convert $infile -format "%[fx:h]" info:` +minify=`convert xc: -format "%[fx:100/$size]" info:` + +# process image +if [ $mode -eq 1 ]; then + convert $infile -resize $minify% -scale ${w}x${h}! "$outfile" +elif [ $mode -eq 2 ]; then + convert $infile -sample $minify% -scale ${w}x${h}! "$outfile" +fi +exit 0 diff --git a/magick/position b/scripts/magick/position similarity index 100% rename from magick/position rename to scripts/magick/position diff --git a/magick/splitcrop b/scripts/magick/splitcrop similarity index 100% rename from magick/splitcrop rename to scripts/magick/splitcrop diff --git a/magick/texture_setup.sh b/scripts/magick/texture_setup.sh similarity index 100% rename from magick/texture_setup.sh rename to scripts/magick/texture_setup.sh