remove character_*_preview_back.png
added .blend files to make preview adapte to add others skin
@ -8,8 +8,8 @@
|
||||
# Warning: any file in .previews/ and u_skins/textures might be deleted without asking.
|
||||
PNGCRUSH=true
|
||||
IMAGEMAGICK=true
|
||||
cd .previews
|
||||
rm ../u_skins/textures/*_preview*.png # Remove all previous previews
|
||||
cd previews
|
||||
rm ../u_skins/textures/character_*_preview*.png # Remove all previous previews
|
||||
blender -b skin_previews.blend --python-text "Generate previews" > /dev/null
|
||||
if $IMAGEMAGICK
|
||||
then echo "Stripping metadata from generated files..."
|
||||
@ -23,26 +23,27 @@ do
|
||||
out_file=output/"$out_name"_preview.png
|
||||
if $IMAGEMAGICK
|
||||
then
|
||||
convert -strip $i $out_file
|
||||
else
|
||||
mv $i $out_file
|
||||
fi
|
||||
done
|
||||
for i in blender_out/character_*_01.png;
|
||||
do
|
||||
out_name=$(basename $i | sed -e 's/_01.png//g')
|
||||
out_file=output/"$out_name"_preview_back.png
|
||||
if $IMAGEMAGICK
|
||||
then
|
||||
convert -strip $i $out_file
|
||||
convert -strip -resize 32x64 $i $out_file
|
||||
else
|
||||
mv $i $out_file
|
||||
fi
|
||||
done
|
||||
|
||||
#for i in blender_out/character_*_01.png;
|
||||
#do
|
||||
# out_name=$(basename $i | sed -e 's/_01.png//g')
|
||||
# out_file=output/"$out_name"_preview_back.png
|
||||
# if $IMAGEMAGICK
|
||||
# then
|
||||
# convert -strip -resize 32x64 $i $out_file
|
||||
# else
|
||||
# mv $i $out_file
|
||||
# fi
|
||||
#done
|
||||
if $PNGCRUSH
|
||||
then
|
||||
echo "Running pngcrush..."
|
||||
pngcrush -d ../u_skins/textures/ output/*_preview*.png 2> pngcrush_output
|
||||
else mv output/*_preview*.png ../u_skins/textures/
|
||||
pngcrush -d ../u_skins/textures/ output/character_*_preview*.png 2> pngcrush_output
|
||||
else mv output/character_*_preview*.png ../u_skins/textures/
|
||||
fi
|
||||
echo "Done !"
|
||||
|
49
mods/u_skins/generate_previews_mff.sh
Executable file
@ -0,0 +1,49 @@
|
||||
#!/bin/sh
|
||||
# This script is used to generate the previews needed by the mod
|
||||
# It requires blender with the latest python API (2.6x is tested)
|
||||
# A script that works with older blenders and, maybe, without python, is available in older commits.
|
||||
# This script can also use pngcrush and imagemagick to reduce output size,
|
||||
# please enable them if you want to push to the git repository of the mod.
|
||||
# Pngcrush output will be written to .previews/pngcrush_output
|
||||
# Warning: any file in .previews/ and u_skins/textures might be deleted without asking.
|
||||
PNGCRUSH=true
|
||||
IMAGEMAGICK=true
|
||||
cd previews
|
||||
rm ../u_skins/textures/mff_*_preview*.png # Remove all previous previews
|
||||
blender -b mff_skin_previews.blend --python-text "Generate previews" > /dev/null
|
||||
if $IMAGEMAGICK
|
||||
then echo "Stripping metadata from generated files..."
|
||||
else echo "Moving files..."
|
||||
fi
|
||||
rm -rf output # remove my output
|
||||
mkdir -p output
|
||||
for i in blender_out/mff_character_*_00.png
|
||||
do
|
||||
out_name=$(basename $i | sed -e 's/_00.png//g')
|
||||
out_file=output/"$out_name"_preview.png
|
||||
if $IMAGEMAGICK
|
||||
then
|
||||
convert -strip -resize 32x64 $i $out_file
|
||||
else
|
||||
mv $i $out_file
|
||||
fi
|
||||
done
|
||||
|
||||
#for i in blender_out/mff_character_*_01.png
|
||||
#do
|
||||
# out_name=$(basename $i | sed -e 's/_01.png//g')
|
||||
# out_file=output/"$out_name"_preview_back.png
|
||||
# if $IMAGEMAGICK
|
||||
# then
|
||||
# convert -strip -resize 32x64 $i $out_file
|
||||
# else
|
||||
# mv $i $out_file
|
||||
# fi
|
||||
#done
|
||||
if $PNGCRUSH
|
||||
then
|
||||
echo "Running pngcrush..."
|
||||
pngcrush -d ../u_skins/textures/ output/mff_*_preview*.png 2> pngcrush_output
|
||||
else mv output/mff_*_preview*.png ../u_skins/textures/
|
||||
fi
|
||||
echo "Done !"
|
BIN
mods/u_skins/previews/mff_skin_previews.blend
Normal file
BIN
mods/u_skins/previews/skin_previews.blend
Normal file
3
mods/u_skins/u_skins/meta/mff_character_1.txt
Normal file
@ -0,0 +1,3 @@
|
||||
40
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_10.txt
Normal file
@ -0,0 +1,3 @@
|
||||
strangekiller
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_11.txt
Normal file
@ -0,0 +1,3 @@
|
||||
unknowedguy
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_12.txt
Normal file
@ -0,0 +1,3 @@
|
||||
walkingdead
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_2.txt
Normal file
@ -0,0 +1,3 @@
|
||||
aquaman
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_3.txt
Normal file
@ -0,0 +1,3 @@
|
||||
battlerobot
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_4.txt
Normal file
@ -0,0 +1,3 @@
|
||||
Cyberpangolin
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_5.txt
Normal file
@ -0,0 +1,3 @@
|
||||
Cyclède
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_6.txt
Normal file
@ -0,0 +1,3 @@
|
||||
Gardeducorps
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_7.txt
Normal file
@ -0,0 +1,3 @@
|
||||
happyguy
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_8.txt
Normal file
@ -0,0 +1,3 @@
|
||||
mystic
|
||||
|
||||
GPL3
|
3
mods/u_skins/u_skins/meta/mff_character_9.txt
Normal file
@ -0,0 +1,3 @@
|
||||
Obani
|
||||
|
||||
GPL3
|
@ -23,4 +23,28 @@ while fetched_skip < 40 do
|
||||
end
|
||||
fetched_skip = fetched_skip + 1
|
||||
id = id + 1
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
-- MODIFICATION MADE FOR MFF
|
||||
id = 1
|
||||
fetched_skip = 0
|
||||
while fetched_skip < 40 do
|
||||
local name = "mff_character_"..id
|
||||
local file = io.open(u_skins.modpath.."/meta/"..name..".txt", "r")
|
||||
if file then
|
||||
local data = string.split(file:read("*all"), "\n", 3)
|
||||
file:close()
|
||||
u_skins.list[internal_id] = name
|
||||
u_skins.meta[name] = {}
|
||||
u_skins.meta[name].name = data[1]
|
||||
u_skins.meta[name].author = data[2]
|
||||
u_skins.meta[name].license = data[3] or ""
|
||||
u_skins.meta[name].description = ""
|
||||
|
||||
fetched_skip = 0
|
||||
internal_id = internal_id + 1
|
||||
end
|
||||
fetched_skip = fetched_skip + 1
|
||||
id = id + 1
|
||||
end
|
||||
|
BIN
mods/u_skins/u_skins/textures/character_100_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 819 B After Width: | Height: | Size: 7.6 KiB |
Before Width: | Height: | Size: 32 KiB |
BIN
mods/u_skins/u_skins/textures/character_101_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 8.6 KiB |
Before Width: | Height: | Size: 24 KiB |
BIN
mods/u_skins/u_skins/textures/character_102_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 175 B After Width: | Height: | Size: 3.0 KiB |
Before Width: | Height: | Size: 23 KiB |
BIN
mods/u_skins/u_skins/textures/character_103_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 795 B After Width: | Height: | Size: 8.3 KiB |
Before Width: | Height: | Size: 26 KiB |
BIN
mods/u_skins/u_skins/textures/character_104_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 769 B After Width: | Height: | Size: 8.7 KiB |
Before Width: | Height: | Size: 32 KiB |
BIN
mods/u_skins/u_skins/textures/character_105_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 998 B After Width: | Height: | Size: 9.0 KiB |
Before Width: | Height: | Size: 8.5 KiB |
BIN
mods/u_skins/u_skins/textures/character_106_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 521 B After Width: | Height: | Size: 6.7 KiB |
Before Width: | Height: | Size: 26 KiB |
BIN
mods/u_skins/u_skins/textures/character_107_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 890 B After Width: | Height: | Size: 7.3 KiB |
Before Width: | Height: | Size: 28 KiB |
BIN
mods/u_skins/u_skins/textures/character_108_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 274 B After Width: | Height: | Size: 4.6 KiB |
Before Width: | Height: | Size: 32 KiB |
BIN
mods/u_skins/u_skins/textures/character_109_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 430 B After Width: | Height: | Size: 4.4 KiB |
Before Width: | Height: | Size: 19 KiB |
BIN
mods/u_skins/u_skins/textures/character_10_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 761 B After Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 19 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 2.6 KiB |
BIN
mods/u_skins/u_skins/textures/character_110_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 951 B After Width: | Height: | Size: 8.1 KiB |
Before Width: | Height: | Size: 28 KiB |
BIN
mods/u_skins/u_skins/textures/character_111_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 317 B After Width: | Height: | Size: 4.6 KiB |
Before Width: | Height: | Size: 9.1 KiB |
BIN
mods/u_skins/u_skins/textures/character_112_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 423 B After Width: | Height: | Size: 4.9 KiB |
Before Width: | Height: | Size: 8.8 KiB |
BIN
mods/u_skins/u_skins/textures/character_113_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 325 B After Width: | Height: | Size: 4.1 KiB |
Before Width: | Height: | Size: 32 KiB |
BIN
mods/u_skins/u_skins/textures/character_114_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 535 B After Width: | Height: | Size: 5.4 KiB |
Before Width: | Height: | Size: 10 KiB |
BIN
mods/u_skins/u_skins/textures/character_115_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 445 B After Width: | Height: | Size: 7.1 KiB |
Before Width: | Height: | Size: 7.0 KiB |
BIN
mods/u_skins/u_skins/textures/character_116_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 533 B After Width: | Height: | Size: 5.7 KiB |
Before Width: | Height: | Size: 7.7 KiB |
BIN
mods/u_skins/u_skins/textures/character_117_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 9.0 KiB |
Before Width: | Height: | Size: 12 KiB |
BIN
mods/u_skins/u_skins/textures/character_118_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 517 B After Width: | Height: | Size: 6.8 KiB |
Before Width: | Height: | Size: 18 KiB |
BIN
mods/u_skins/u_skins/textures/character_119_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 413 B After Width: | Height: | Size: 8.8 KiB |
Before Width: | Height: | Size: 12 KiB |
BIN
mods/u_skins/u_skins/textures/character_11_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 693 B After Width: | Height: | Size: 3.6 KiB |
Before Width: | Height: | Size: 24 KiB |
BIN
mods/u_skins/u_skins/textures/character_120_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 619 B After Width: | Height: | Size: 7.1 KiB |
Before Width: | Height: | Size: 36 KiB |
BIN
mods/u_skins/u_skins/textures/character_121_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 775 B After Width: | Height: | Size: 7.2 KiB |
Before Width: | Height: | Size: 13 KiB |
BIN
mods/u_skins/u_skins/textures/character_122_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 197 B After Width: | Height: | Size: 3.1 KiB |
Before Width: | Height: | Size: 16 KiB |
BIN
mods/u_skins/u_skins/textures/character_123_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 413 B After Width: | Height: | Size: 5.7 KiB |
Before Width: | Height: | Size: 18 KiB |
BIN
mods/u_skins/u_skins/textures/character_124_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 424 B After Width: | Height: | Size: 5.9 KiB |
Before Width: | Height: | Size: 22 KiB |
BIN
mods/u_skins/u_skins/textures/character_125_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 632 B After Width: | Height: | Size: 7.7 KiB |
Before Width: | Height: | Size: 5.0 KiB |
BIN
mods/u_skins/u_skins/textures/character_126_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 581 B After Width: | Height: | Size: 6.6 KiB |
Before Width: | Height: | Size: 14 KiB |
BIN
mods/u_skins/u_skins/textures/character_127_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 198 B After Width: | Height: | Size: 2.4 KiB |
Before Width: | Height: | Size: 13 KiB |
BIN
mods/u_skins/u_skins/textures/character_128_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 179 B After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 25 KiB |
BIN
mods/u_skins/u_skins/textures/character_129_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 752 B After Width: | Height: | Size: 8.0 KiB |
Before Width: | Height: | Size: 14 KiB |
BIN
mods/u_skins/u_skins/textures/character_12_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 940 B After Width: | Height: | Size: 8.0 KiB |
Before Width: | Height: | Size: 26 KiB |
BIN
mods/u_skins/u_skins/textures/character_130_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 8.4 KiB |
Before Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 1.5 KiB |
BIN
mods/u_skins/u_skins/textures/character_131_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 1022 B After Width: | Height: | Size: 6.8 KiB |
Before Width: | Height: | Size: 1.9 KiB |
BIN
mods/u_skins/u_skins/textures/character_132_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 696 B After Width: | Height: | Size: 7.9 KiB |
Before Width: | Height: | Size: 19 KiB |
BIN
mods/u_skins/u_skins/textures/character_133_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 597 B After Width: | Height: | Size: 8.4 KiB |
Before Width: | Height: | Size: 26 KiB |
BIN
mods/u_skins/u_skins/textures/character_134_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 293 B After Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 30 KiB |
BIN
mods/u_skins/u_skins/textures/character_135_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 770 B After Width: | Height: | Size: 8.6 KiB |
Before Width: | Height: | Size: 24 KiB |
BIN
mods/u_skins/u_skins/textures/character_136_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 925 B After Width: | Height: | Size: 7.6 KiB |
Before Width: | Height: | Size: 19 KiB |
BIN
mods/u_skins/u_skins/textures/character_137_preview.png
Executable file → Normal file
Before Width: | Height: | Size: 910 B After Width: | Height: | Size: 8.8 KiB |