diff --git a/Bundle Packs/preview_images/builders_pack_preview.png b/Bundle Packs/preview_images/builders_pack_preview.png index 6139634..ec50652 100644 Binary files a/Bundle Packs/preview_images/builders_pack_preview.png and b/Bundle Packs/preview_images/builders_pack_preview.png differ diff --git a/Bundle Packs/preview_images/merrybundle_preview_image.png b/Bundle Packs/preview_images/merrybundle_preview_image.png index 22074e1..20d474e 100644 Binary files a/Bundle Packs/preview_images/merrybundle_preview_image.png and b/Bundle Packs/preview_images/merrybundle_preview_image.png differ diff --git a/Bundle Packs/preview_images/skinpack_megabundle_preview_image.png b/Bundle Packs/preview_images/skinpack_megabundle_preview_image.png index e53ecf7..2f5555c 100644 Binary files a/Bundle Packs/preview_images/skinpack_megabundle_preview_image.png and b/Bundle Packs/preview_images/skinpack_megabundle_preview_image.png differ diff --git a/Bundle Packs/preview_images/spookybundle_preview_image.png b/Bundle Packs/preview_images/spookybundle_preview_image.png index 4bb4246..1d0552a 100644 Binary files a/Bundle Packs/preview_images/spookybundle_preview_image.png and b/Bundle Packs/preview_images/spookybundle_preview_image.png differ diff --git a/resources/4JStudios_20161025_091659_790844594565021696.png b/resources/bundle preview image template/4JStudios_20161025_091659_790844594565021696.png similarity index 100% rename from resources/4JStudios_20161025_091659_790844594565021696.png rename to resources/bundle preview image template/4JStudios_20161025_091659_790844594565021696.png diff --git a/resources/bundle preview image template/builders bundle/left.png b/resources/bundle preview image template/builders bundle/left.png new file mode 100644 index 0000000..a74579f Binary files /dev/null and b/resources/bundle preview image template/builders bundle/left.png differ diff --git a/resources/bundle preview image template/builders bundle/left1.png b/resources/bundle preview image template/builders bundle/left1.png new file mode 100644 index 0000000..3ad4802 Binary files /dev/null and b/resources/bundle preview image template/builders bundle/left1.png differ diff --git a/resources/bundle preview image template/builders bundle/make_preview.bat b/resources/bundle preview image template/builders bundle/make_preview.bat new file mode 100644 index 0000000..8cd7829 --- /dev/null +++ b/resources/bundle preview image template/builders bundle/make_preview.bat @@ -0,0 +1,21 @@ +@echo off +setlocal +set "HERE=%~dp0" +set "HERE=%HERE:~0,-1%" +set "REPO=%HERE%\..\..\.." +where python >nul 2>nul +if %errorlevel%==0 ( + set "PY=python" +) else ( + set "PY=py -3" +) +%PY% "%REPO%\scripts\make_bundle_preview.py" --bundle-dir "%HERE%" +if errorlevel 1 ( + echo. + echo Failed. + pause + exit /b 1 +) +echo. +echo Created "%HERE%\preview.png" +pause diff --git a/resources/bundle preview image template/builders bundle/middle.png b/resources/bundle preview image template/builders bundle/middle.png new file mode 100644 index 0000000..f205f07 Binary files /dev/null and b/resources/bundle preview image template/builders bundle/middle.png differ diff --git a/resources/bundle preview image template/builders bundle/middle1.png b/resources/bundle preview image template/builders bundle/middle1.png new file mode 100644 index 0000000..cbe9efd Binary files /dev/null and b/resources/bundle preview image template/builders bundle/middle1.png differ diff --git a/resources/bundle preview image template/builders bundle/preview.png b/resources/bundle preview image template/builders bundle/preview.png new file mode 100644 index 0000000..ec50652 Binary files /dev/null and b/resources/bundle preview image template/builders bundle/preview.png differ diff --git a/resources/bundle preview image template/builders bundle/right.png b/resources/bundle preview image template/builders bundle/right.png new file mode 100644 index 0000000..db0d068 Binary files /dev/null and b/resources/bundle preview image template/builders bundle/right.png differ diff --git a/resources/bundle preview image template/builders bundle/right1.png b/resources/bundle preview image template/builders bundle/right1.png new file mode 100644 index 0000000..2704d06 Binary files /dev/null and b/resources/bundle preview image template/builders bundle/right1.png differ diff --git a/resources/bundle preview image template/builders bundle/text.png b/resources/bundle preview image template/builders bundle/text.png new file mode 100644 index 0000000..94400dc Binary files /dev/null and b/resources/bundle preview image template/builders bundle/text.png differ diff --git a/resources/bundle_template.png b/resources/bundle preview image template/bundle_template.png similarity index 100% rename from resources/bundle_template.png rename to resources/bundle preview image template/bundle_template.png diff --git a/resources/cropped_bundle_clean.png b/resources/bundle preview image template/cropped_bundle_clean.png similarity index 100% rename from resources/cropped_bundle_clean.png rename to resources/bundle preview image template/cropped_bundle_clean.png diff --git a/resources/bundle preview image template/generated_spooky_bundle.png b/resources/bundle preview image template/generated_spooky_bundle.png new file mode 100644 index 0000000..62d3480 Binary files /dev/null and b/resources/bundle preview image template/generated_spooky_bundle.png differ diff --git a/resources/header.png b/resources/bundle preview image template/header.png similarity index 100% rename from resources/header.png rename to resources/bundle preview image template/header.png diff --git a/resources/bundle preview image template/mega skinpack bundle/left.png b/resources/bundle preview image template/mega skinpack bundle/left.png new file mode 100644 index 0000000..985707d Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/left.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/left1.png b/resources/bundle preview image template/mega skinpack bundle/left1.png new file mode 100644 index 0000000..039f5c6 Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/left1.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/make_preview.bat b/resources/bundle preview image template/mega skinpack bundle/make_preview.bat new file mode 100644 index 0000000..8cd7829 --- /dev/null +++ b/resources/bundle preview image template/mega skinpack bundle/make_preview.bat @@ -0,0 +1,21 @@ +@echo off +setlocal +set "HERE=%~dp0" +set "HERE=%HERE:~0,-1%" +set "REPO=%HERE%\..\..\.." +where python >nul 2>nul +if %errorlevel%==0 ( + set "PY=python" +) else ( + set "PY=py -3" +) +%PY% "%REPO%\scripts\make_bundle_preview.py" --bundle-dir "%HERE%" +if errorlevel 1 ( + echo. + echo Failed. + pause + exit /b 1 +) +echo. +echo Created "%HERE%\preview.png" +pause diff --git a/resources/bundle preview image template/mega skinpack bundle/middle.png b/resources/bundle preview image template/mega skinpack bundle/middle.png new file mode 100644 index 0000000..b6e881c Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/middle.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/middle1.png b/resources/bundle preview image template/mega skinpack bundle/middle1.png new file mode 100644 index 0000000..1ea547b Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/middle1.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/preview.png b/resources/bundle preview image template/mega skinpack bundle/preview.png new file mode 100644 index 0000000..2f5555c Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/preview.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/right.png b/resources/bundle preview image template/mega skinpack bundle/right.png new file mode 100644 index 0000000..5d9463f Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/right.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/right1.png b/resources/bundle preview image template/mega skinpack bundle/right1.png new file mode 100644 index 0000000..d60a740 Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/right1.png differ diff --git a/resources/bundle preview image template/mega skinpack bundle/text.png b/resources/bundle preview image template/mega skinpack bundle/text.png new file mode 100644 index 0000000..15d8a1e Binary files /dev/null and b/resources/bundle preview image template/mega skinpack bundle/text.png differ diff --git a/resources/bundle preview image template/merry bundle/left.png b/resources/bundle preview image template/merry bundle/left.png new file mode 100644 index 0000000..accb3b3 Binary files /dev/null and b/resources/bundle preview image template/merry bundle/left.png differ diff --git a/resources/bundle preview image template/merry bundle/make_preview.bat b/resources/bundle preview image template/merry bundle/make_preview.bat new file mode 100644 index 0000000..8cd7829 --- /dev/null +++ b/resources/bundle preview image template/merry bundle/make_preview.bat @@ -0,0 +1,21 @@ +@echo off +setlocal +set "HERE=%~dp0" +set "HERE=%HERE:~0,-1%" +set "REPO=%HERE%\..\..\.." +where python >nul 2>nul +if %errorlevel%==0 ( + set "PY=python" +) else ( + set "PY=py -3" +) +%PY% "%REPO%\scripts\make_bundle_preview.py" --bundle-dir "%HERE%" +if errorlevel 1 ( + echo. + echo Failed. + pause + exit /b 1 +) +echo. +echo Created "%HERE%\preview.png" +pause diff --git a/resources/bundle preview image template/merry bundle/middle.png b/resources/bundle preview image template/merry bundle/middle.png new file mode 100644 index 0000000..f6b698e Binary files /dev/null and b/resources/bundle preview image template/merry bundle/middle.png differ diff --git a/resources/bundle preview image template/merry bundle/preview.png b/resources/bundle preview image template/merry bundle/preview.png new file mode 100644 index 0000000..20d474e Binary files /dev/null and b/resources/bundle preview image template/merry bundle/preview.png differ diff --git a/resources/bundle preview image template/merry bundle/right.png b/resources/bundle preview image template/merry bundle/right.png new file mode 100644 index 0000000..d637d4e Binary files /dev/null and b/resources/bundle preview image template/merry bundle/right.png differ diff --git a/resources/bundle preview image template/merry bundle/text.png b/resources/bundle preview image template/merry bundle/text.png new file mode 100644 index 0000000..cbc8b5b Binary files /dev/null and b/resources/bundle preview image template/merry bundle/text.png differ diff --git a/resources/bundle preview image template/spooky bundle/left.png b/resources/bundle preview image template/spooky bundle/left.png new file mode 100644 index 0000000..d6059a6 Binary files /dev/null and b/resources/bundle preview image template/spooky bundle/left.png differ diff --git a/resources/bundle preview image template/spooky bundle/make_preview.bat b/resources/bundle preview image template/spooky bundle/make_preview.bat new file mode 100644 index 0000000..8cd7829 --- /dev/null +++ b/resources/bundle preview image template/spooky bundle/make_preview.bat @@ -0,0 +1,21 @@ +@echo off +setlocal +set "HERE=%~dp0" +set "HERE=%HERE:~0,-1%" +set "REPO=%HERE%\..\..\.." +where python >nul 2>nul +if %errorlevel%==0 ( + set "PY=python" +) else ( + set "PY=py -3" +) +%PY% "%REPO%\scripts\make_bundle_preview.py" --bundle-dir "%HERE%" +if errorlevel 1 ( + echo. + echo Failed. + pause + exit /b 1 +) +echo. +echo Created "%HERE%\preview.png" +pause diff --git a/resources/bundle preview image template/spooky bundle/middle.png b/resources/bundle preview image template/spooky bundle/middle.png new file mode 100644 index 0000000..4619bab Binary files /dev/null and b/resources/bundle preview image template/spooky bundle/middle.png differ diff --git a/resources/bundle preview image template/spooky bundle/preview.png b/resources/bundle preview image template/spooky bundle/preview.png new file mode 100644 index 0000000..1d0552a Binary files /dev/null and b/resources/bundle preview image template/spooky bundle/preview.png differ diff --git a/resources/bundle preview image template/spooky bundle/right.png b/resources/bundle preview image template/spooky bundle/right.png new file mode 100644 index 0000000..15adc29 Binary files /dev/null and b/resources/bundle preview image template/spooky bundle/right.png differ diff --git a/resources/bundle preview image template/spooky bundle/text.png b/resources/bundle preview image template/spooky bundle/text.png new file mode 100644 index 0000000..ec6b84c Binary files /dev/null and b/resources/bundle preview image template/spooky bundle/text.png differ diff --git a/resources/lce skinpack icons/1stbirthday.png b/resources/lce skinpack icons/1stbirthday.png new file mode 100644 index 0000000..75681a6 Binary files /dev/null and b/resources/lce skinpack icons/1stbirthday.png differ diff --git a/resources/lce skinpack icons/2ndbdaypsretro.png b/resources/lce skinpack icons/2ndbdaypsretro.png new file mode 100644 index 0000000..977f87b Binary files /dev/null and b/resources/lce skinpack icons/2ndbdaypsretro.png differ diff --git a/resources/lce skinpack icons/2ndbirthday.png b/resources/lce skinpack icons/2ndbirthday.png new file mode 100644 index 0000000..c3fd7dd Binary files /dev/null and b/resources/lce skinpack icons/2ndbirthday.png differ diff --git a/resources/lce skinpack icons/3rdbirthday.png b/resources/lce skinpack icons/3rdbirthday.png new file mode 100644 index 0000000..5e1c46b Binary files /dev/null and b/resources/lce skinpack icons/3rdbirthday.png differ diff --git a/resources/lce skinpack icons/4thbirthday.png b/resources/lce skinpack icons/4thbirthday.png new file mode 100644 index 0000000..0e3856f Binary files /dev/null and b/resources/lce skinpack icons/4thbirthday.png differ diff --git a/resources/lce skinpack icons/5thbirthday.png b/resources/lce skinpack icons/5thbirthday.png new file mode 100644 index 0000000..6c82ed9 Binary files /dev/null and b/resources/lce skinpack icons/5thbirthday.png differ diff --git a/resources/lce skinpack icons/adventure_time.png b/resources/lce skinpack icons/adventure_time.png new file mode 100644 index 0000000..5d9463f Binary files /dev/null and b/resources/lce skinpack icons/adventure_time.png differ diff --git a/resources/lce skinpack icons/battleandbeasts.png b/resources/lce skinpack icons/battleandbeasts.png new file mode 100644 index 0000000..12aa908 Binary files /dev/null and b/resources/lce skinpack icons/battleandbeasts.png differ diff --git a/resources/lce skinpack icons/battleandbeasts2.png b/resources/lce skinpack icons/battleandbeasts2.png new file mode 100644 index 0000000..20fa24e Binary files /dev/null and b/resources/lce skinpack icons/battleandbeasts2.png differ diff --git a/resources/lce skinpack icons/biomesettlers1.png b/resources/lce skinpack icons/biomesettlers1.png new file mode 100644 index 0000000..2704d06 Binary files /dev/null and b/resources/lce skinpack icons/biomesettlers1.png differ diff --git a/resources/lce skinpack icons/biomesettlers2.png b/resources/lce skinpack icons/biomesettlers2.png new file mode 100644 index 0000000..04cd0a7 Binary files /dev/null and b/resources/lce skinpack icons/biomesettlers2.png differ diff --git a/resources/lce skinpack icons/biomesettlers3.png b/resources/lce skinpack icons/biomesettlers3.png new file mode 100644 index 0000000..9b02753 Binary files /dev/null and b/resources/lce skinpack icons/biomesettlers3.png differ diff --git a/resources/lce skinpack icons/campfiretales.png b/resources/lce skinpack icons/campfiretales.png new file mode 100644 index 0000000..4619bab Binary files /dev/null and b/resources/lce skinpack icons/campfiretales.png differ diff --git a/resources/lce skinpack icons/chinesemythology.png b/resources/lce skinpack icons/chinesemythology.png new file mode 100644 index 0000000..a59356f Binary files /dev/null and b/resources/lce skinpack icons/chinesemythology.png differ diff --git a/resources/lce skinpack icons/drwhoi.png b/resources/lce skinpack icons/drwhoi.png new file mode 100644 index 0000000..d60a740 Binary files /dev/null and b/resources/lce skinpack icons/drwhoi.png differ diff --git a/resources/lce skinpack icons/drwhoii.png b/resources/lce skinpack icons/drwhoii.png new file mode 100644 index 0000000..1b81c21 Binary files /dev/null and b/resources/lce skinpack icons/drwhoii.png differ diff --git a/resources/lce skinpack icons/egyptianmythology.png b/resources/lce skinpack icons/egyptianmythology.png new file mode 100644 index 0000000..1771c38 Binary files /dev/null and b/resources/lce skinpack icons/egyptianmythology.png differ diff --git a/resources/lce skinpack icons/fallout.png b/resources/lce skinpack icons/fallout.png new file mode 100644 index 0000000..3f7301b Binary files /dev/null and b/resources/lce skinpack icons/fallout.png differ diff --git a/resources/lce skinpack icons/festive_mashup.png b/resources/lce skinpack icons/festive_mashup.png new file mode 100644 index 0000000..f6b698e Binary files /dev/null and b/resources/lce skinpack icons/festive_mashup.png differ diff --git a/resources/lce skinpack icons/festive_skin_pack.png b/resources/lce skinpack icons/festive_skin_pack.png new file mode 100644 index 0000000..d637d4e Binary files /dev/null and b/resources/lce skinpack icons/festive_skin_pack.png differ diff --git a/resources/lce skinpack icons/finalfantasyxvskinpack.png b/resources/lce skinpack icons/finalfantasyxvskinpack.png new file mode 100644 index 0000000..49a244c Binary files /dev/null and b/resources/lce skinpack icons/finalfantasyxvskinpack.png differ diff --git a/resources/lce skinpack icons/fromtheshadowsskinpack.png b/resources/lce skinpack icons/fromtheshadowsskinpack.png new file mode 100644 index 0000000..e14836a Binary files /dev/null and b/resources/lce skinpack icons/fromtheshadowsskinpack.png differ diff --git a/resources/lce skinpack icons/greekmythology.png b/resources/lce skinpack icons/greekmythology.png new file mode 100644 index 0000000..51346e2 Binary files /dev/null and b/resources/lce skinpack icons/greekmythology.png differ diff --git a/resources/lce skinpack icons/littlebigplanetmash-up.png b/resources/lce skinpack icons/littlebigplanetmash-up.png new file mode 100644 index 0000000..2ec6267 Binary files /dev/null and b/resources/lce skinpack icons/littlebigplanetmash-up.png differ diff --git a/resources/lce skinpack icons/magicthegathering.png b/resources/lce skinpack icons/magicthegathering.png new file mode 100644 index 0000000..e84189f Binary files /dev/null and b/resources/lce skinpack icons/magicthegathering.png differ diff --git a/resources/lce skinpack icons/mariobrothers.png b/resources/lce skinpack icons/mariobrothers.png new file mode 100644 index 0000000..b6e881c Binary files /dev/null and b/resources/lce skinpack icons/mariobrothers.png differ diff --git a/resources/lce skinpack icons/marvelavengers.png b/resources/lce skinpack icons/marvelavengers.png new file mode 100644 index 0000000..536e54c Binary files /dev/null and b/resources/lce skinpack icons/marvelavengers.png differ diff --git a/resources/lce skinpack icons/marvelguardiansofthegalaxy.png b/resources/lce skinpack icons/marvelguardiansofthegalaxy.png new file mode 100644 index 0000000..c515f8a Binary files /dev/null and b/resources/lce skinpack icons/marvelguardiansofthegalaxy.png differ diff --git a/resources/lce skinpack icons/marvelspiderman.png b/resources/lce skinpack icons/marvelspiderman.png new file mode 100644 index 0000000..982554e Binary files /dev/null and b/resources/lce skinpack icons/marvelspiderman.png differ diff --git a/resources/lce skinpack icons/mashuphalloween.png b/resources/lce skinpack icons/mashuphalloween.png new file mode 100644 index 0000000..d6059a6 Binary files /dev/null and b/resources/lce skinpack icons/mashuphalloween.png differ diff --git a/resources/lce skinpack icons/mashuphalo.png b/resources/lce skinpack icons/mashuphalo.png new file mode 100644 index 0000000..3540fb6 Binary files /dev/null and b/resources/lce skinpack icons/mashuphalo.png differ diff --git a/resources/lce skinpack icons/masseffect.png b/resources/lce skinpack icons/masseffect.png new file mode 100644 index 0000000..46c290a Binary files /dev/null and b/resources/lce skinpack icons/masseffect.png differ diff --git a/resources/lce skinpack icons/minecon2015.png b/resources/lce skinpack icons/minecon2015.png new file mode 100644 index 0000000..6ad023a Binary files /dev/null and b/resources/lce skinpack icons/minecon2015.png differ diff --git a/resources/lce skinpack icons/minecon2016.png b/resources/lce skinpack icons/minecon2016.png new file mode 100644 index 0000000..a39b51e Binary files /dev/null and b/resources/lce skinpack icons/minecon2016.png differ diff --git a/resources/lce skinpack icons/mineconearth2017.png b/resources/lce skinpack icons/mineconearth2017.png new file mode 100644 index 0000000..4f22aa3 Binary files /dev/null and b/resources/lce skinpack icons/mineconearth2017.png differ diff --git a/resources/lce skinpack icons/minigameheroes.png b/resources/lce skinpack icons/minigameheroes.png new file mode 100644 index 0000000..b22cd0a Binary files /dev/null and b/resources/lce skinpack icons/minigameheroes.png differ diff --git a/resources/lce skinpack icons/minigamemasters.png b/resources/lce skinpack icons/minigamemasters.png new file mode 100644 index 0000000..387bc02 Binary files /dev/null and b/resources/lce skinpack icons/minigamemasters.png differ diff --git a/resources/lce skinpack icons/moanacharacterpack.png b/resources/lce skinpack icons/moanacharacterpack.png new file mode 100644 index 0000000..919e4f1 Binary files /dev/null and b/resources/lce skinpack icons/moanacharacterpack.png differ diff --git a/resources/lce skinpack icons/norsemythology.png b/resources/lce skinpack icons/norsemythology.png new file mode 100644 index 0000000..88b827f Binary files /dev/null and b/resources/lce skinpack icons/norsemythology.png differ diff --git a/resources/lce skinpack icons/piratesofthecaribbean.png b/resources/lce skinpack icons/piratesofthecaribbean.png new file mode 100644 index 0000000..21df71c Binary files /dev/null and b/resources/lce skinpack icons/piratesofthecaribbean.png differ diff --git a/resources/lce skinpack icons/powerrangers.png b/resources/lce skinpack icons/powerrangers.png new file mode 100644 index 0000000..6ab9404 Binary files /dev/null and b/resources/lce skinpack icons/powerrangers.png differ diff --git a/resources/lce skinpack icons/redstone.png b/resources/lce skinpack icons/redstone.png new file mode 100644 index 0000000..67e943b Binary files /dev/null and b/resources/lce skinpack icons/redstone.png differ diff --git a/resources/lce skinpack icons/simpsons.png b/resources/lce skinpack icons/simpsons.png new file mode 100644 index 0000000..1ea547b Binary files /dev/null and b/resources/lce skinpack icons/simpsons.png differ diff --git a/resources/lce skinpack icons/skinpack1.png b/resources/lce skinpack icons/skinpack1.png new file mode 100644 index 0000000..1a8b772 Binary files /dev/null and b/resources/lce skinpack icons/skinpack1.png differ diff --git a/resources/lce skinpack icons/skinpack1ps.png b/resources/lce skinpack icons/skinpack1ps.png new file mode 100644 index 0000000..6ad6cff Binary files /dev/null and b/resources/lce skinpack icons/skinpack1ps.png differ diff --git a/resources/lce skinpack icons/skinpack2.png b/resources/lce skinpack icons/skinpack2.png new file mode 100644 index 0000000..ff5cb6a Binary files /dev/null and b/resources/lce skinpack icons/skinpack2.png differ diff --git a/resources/lce skinpack icons/skinpack2ps.png b/resources/lce skinpack icons/skinpack2ps.png new file mode 100644 index 0000000..1e49d33 Binary files /dev/null and b/resources/lce skinpack icons/skinpack2ps.png differ diff --git a/resources/lce skinpack icons/skinpack3.png b/resources/lce skinpack icons/skinpack3.png new file mode 100644 index 0000000..820dd13 Binary files /dev/null and b/resources/lce skinpack icons/skinpack3.png differ diff --git a/resources/lce skinpack icons/skinpack3ps.png b/resources/lce skinpack icons/skinpack3ps.png new file mode 100644 index 0000000..4911fc9 Binary files /dev/null and b/resources/lce skinpack icons/skinpack3ps.png differ diff --git a/resources/lce skinpack icons/skinpack4.png b/resources/lce skinpack icons/skinpack4.png new file mode 100644 index 0000000..d164f21 Binary files /dev/null and b/resources/lce skinpack icons/skinpack4.png differ diff --git a/resources/lce skinpack icons/skinpack5.png b/resources/lce skinpack icons/skinpack5.png new file mode 100644 index 0000000..e82d797 Binary files /dev/null and b/resources/lce skinpack icons/skinpack5.png differ diff --git a/resources/lce skinpack icons/skinpack6.png b/resources/lce skinpack icons/skinpack6.png new file mode 100644 index 0000000..cb069af Binary files /dev/null and b/resources/lce skinpack icons/skinpack6.png differ diff --git a/resources/lce skinpack icons/skyrim.png b/resources/lce skinpack icons/skyrim.png new file mode 100644 index 0000000..c4159a8 Binary files /dev/null and b/resources/lce skinpack icons/skyrim.png differ diff --git a/resources/lce skinpack icons/soloastarwarsstorypack.png b/resources/lce skinpack icons/soloastarwarsstorypack.png new file mode 100644 index 0000000..f482066 Binary files /dev/null and b/resources/lce skinpack icons/soloastarwarsstorypack.png differ diff --git a/resources/lce skinpack icons/starwarsclassic.png b/resources/lce skinpack icons/starwarsclassic.png new file mode 100644 index 0000000..3a6ce07 Binary files /dev/null and b/resources/lce skinpack icons/starwarsclassic.png differ diff --git a/resources/lce skinpack icons/starwarsprequel.png b/resources/lce skinpack icons/starwarsprequel.png new file mode 100644 index 0000000..8978607 Binary files /dev/null and b/resources/lce skinpack icons/starwarsprequel.png differ diff --git a/resources/lce skinpack icons/starwarsrebels.png b/resources/lce skinpack icons/starwarsrebels.png new file mode 100644 index 0000000..3843b8a Binary files /dev/null and b/resources/lce skinpack icons/starwarsrebels.png differ diff --git a/resources/lce skinpack icons/starwarssequelskinpack.png b/resources/lce skinpack icons/starwarssequelskinpack.png new file mode 100644 index 0000000..3443660 Binary files /dev/null and b/resources/lce skinpack icons/starwarssequelskinpack.png differ diff --git a/resources/lce skinpack icons/stevenuniverse.png b/resources/lce skinpack icons/stevenuniverse.png new file mode 100644 index 0000000..af50dbf Binary files /dev/null and b/resources/lce skinpack icons/stevenuniverse.png differ diff --git a/resources/lce skinpack icons/storymode.png b/resources/lce skinpack icons/storymode.png new file mode 100644 index 0000000..985707d Binary files /dev/null and b/resources/lce skinpack icons/storymode.png differ diff --git a/resources/lce skinpack icons/strangerthings.png b/resources/lce skinpack icons/strangerthings.png new file mode 100644 index 0000000..385c802 Binary files /dev/null and b/resources/lce skinpack icons/strangerthings.png differ diff --git a/resources/lce skinpack icons/supercute.png b/resources/lce skinpack icons/supercute.png new file mode 100644 index 0000000..0f3af52 Binary files /dev/null and b/resources/lce skinpack icons/supercute.png differ diff --git a/resources/lce skinpack icons/the_incredibles.png b/resources/lce skinpack icons/the_incredibles.png new file mode 100644 index 0000000..ebccfe3 Binary files /dev/null and b/resources/lce skinpack icons/the_incredibles.png differ diff --git a/resources/lce skinpack icons/thenightmarebeforechristmas.png b/resources/lce skinpack icons/thenightmarebeforechristmas.png new file mode 100644 index 0000000..039f5c6 Binary files /dev/null and b/resources/lce skinpack icons/thenightmarebeforechristmas.png differ diff --git a/resources/lce skinpack icons/toystorymash-up.png b/resources/lce skinpack icons/toystorymash-up.png new file mode 100644 index 0000000..4d1bb10 Binary files /dev/null and b/resources/lce skinpack icons/toystorymash-up.png differ diff --git a/resources/lce skinpack icons/villains.png b/resources/lce skinpack icons/villains.png new file mode 100644 index 0000000..0eef16f Binary files /dev/null and b/resources/lce skinpack icons/villains.png differ diff --git a/resources/lce texture pack icons/candy_texture_pack.png b/resources/lce texture pack icons/candy_texture_pack.png new file mode 100644 index 0000000..1616ae3 Binary files /dev/null and b/resources/lce texture pack icons/candy_texture_pack.png differ diff --git a/resources/lce texture pack icons/cartoon_texture_pack.png b/resources/lce texture pack icons/cartoon_texture_pack.png new file mode 100644 index 0000000..1dfbb89 Binary files /dev/null and b/resources/lce texture pack icons/cartoon_texture_pack.png differ diff --git a/resources/lce texture pack icons/chinese_mythology_mashup.png b/resources/lce texture pack icons/chinese_mythology_mashup.png new file mode 100644 index 0000000..1e6c8b6 Binary files /dev/null and b/resources/lce texture pack icons/chinese_mythology_mashup.png differ diff --git a/resources/lce texture pack icons/city_texture_pack.png b/resources/lce texture pack icons/city_texture_pack.png new file mode 100644 index 0000000..3d3b0ad Binary files /dev/null and b/resources/lce texture pack icons/city_texture_pack.png differ diff --git a/resources/lce texture pack icons/egyptian_mythology_mashup.png b/resources/lce texture pack icons/egyptian_mythology_mashup.png new file mode 100644 index 0000000..6d2d3f4 Binary files /dev/null and b/resources/lce texture pack icons/egyptian_mythology_mashup.png differ diff --git a/resources/lce texture pack icons/fantasy_texture_pack.png b/resources/lce texture pack icons/fantasy_texture_pack.png new file mode 100644 index 0000000..35aaa65 Binary files /dev/null and b/resources/lce texture pack icons/fantasy_texture_pack.png differ diff --git a/resources/lce texture pack icons/festive_mashup.png b/resources/lce texture pack icons/festive_mashup.png new file mode 100644 index 0000000..8d7ca08 Binary files /dev/null and b/resources/lce texture pack icons/festive_mashup.png differ diff --git a/resources/lce texture pack icons/greek_mythology_mashup.png b/resources/lce texture pack icons/greek_mythology_mashup.png new file mode 100644 index 0000000..3cb93fb Binary files /dev/null and b/resources/lce texture pack icons/greek_mythology_mashup.png differ diff --git a/resources/lce texture pack icons/halloween_mashup.png b/resources/lce texture pack icons/halloween_mashup.png new file mode 100644 index 0000000..0407839 Binary files /dev/null and b/resources/lce texture pack icons/halloween_mashup.png differ diff --git a/resources/lce texture pack icons/mass_effect_mashup.png b/resources/lce texture pack icons/mass_effect_mashup.png new file mode 100644 index 0000000..28b0010 Binary files /dev/null and b/resources/lce texture pack icons/mass_effect_mashup.png differ diff --git a/resources/lce texture pack icons/natural_texture_pack.png b/resources/lce texture pack icons/natural_texture_pack.png new file mode 100644 index 0000000..1072394 Binary files /dev/null and b/resources/lce texture pack icons/natural_texture_pack.png differ diff --git a/resources/lce texture pack icons/norse_mythology_mashup.png b/resources/lce texture pack icons/norse_mythology_mashup.png new file mode 100644 index 0000000..d7398ea Binary files /dev/null and b/resources/lce texture pack icons/norse_mythology_mashup.png differ diff --git a/resources/lce texture pack icons/pattern_texture_pack.png b/resources/lce texture pack icons/pattern_texture_pack.png new file mode 100644 index 0000000..ad4155a Binary files /dev/null and b/resources/lce texture pack icons/pattern_texture_pack.png differ diff --git a/resources/lce texture pack icons/pirates_of_the_caribbean_mashup.png b/resources/lce texture pack icons/pirates_of_the_caribbean_mashup.png new file mode 100644 index 0000000..4463933 Binary files /dev/null and b/resources/lce texture pack icons/pirates_of_the_caribbean_mashup.png differ diff --git a/resources/lce texture pack icons/plastic_texture_pack.png b/resources/lce texture pack icons/plastic_texture_pack.png new file mode 100644 index 0000000..bd407e4 Binary files /dev/null and b/resources/lce texture pack icons/plastic_texture_pack.png differ diff --git a/resources/lce texture pack icons/steampunk_texture_pack.png b/resources/lce texture pack icons/steampunk_texture_pack.png new file mode 100644 index 0000000..8e77781 Binary files /dev/null and b/resources/lce texture pack icons/steampunk_texture_pack.png differ diff --git a/resources/lce texture pack icons/super_cute_texture_pack.png b/resources/lce texture pack icons/super_cute_texture_pack.png new file mode 100644 index 0000000..9e6f714 Binary files /dev/null and b/resources/lce texture pack icons/super_cute_texture_pack.png differ diff --git a/resources/store icons/candy_preview.png b/resources/store icons/candy_preview.png new file mode 100644 index 0000000..f205f07 Binary files /dev/null and b/resources/store icons/candy_preview.png differ diff --git a/resources/store icons/cartoon_preview.png b/resources/store icons/cartoon_preview.png new file mode 100644 index 0000000..cbe9efd Binary files /dev/null and b/resources/store icons/cartoon_preview.png differ diff --git a/resources/store icons/chinesemytho_preview.png b/resources/store icons/chinesemytho_preview.png new file mode 100644 index 0000000..1bf825e Binary files /dev/null and b/resources/store icons/chinesemytho_preview.png differ diff --git a/resources/store icons/city_preview.png b/resources/store icons/city_preview.png new file mode 100644 index 0000000..178773b Binary files /dev/null and b/resources/store icons/city_preview.png differ diff --git a/resources/store icons/egyptianmytho_preview.png b/resources/store icons/egyptianmytho_preview.png new file mode 100644 index 0000000..5afb6fd Binary files /dev/null and b/resources/store icons/egyptianmytho_preview.png differ diff --git a/resources/store icons/fallout_preview.png b/resources/store icons/fallout_preview.png new file mode 100644 index 0000000..c60aa7f Binary files /dev/null and b/resources/store icons/fallout_preview.png differ diff --git a/resources/store icons/fantasy_preview.png b/resources/store icons/fantasy_preview.png new file mode 100644 index 0000000..50085b5 Binary files /dev/null and b/resources/store icons/fantasy_preview.png differ diff --git a/resources/store icons/festive_preview.png b/resources/store icons/festive_preview.png new file mode 100644 index 0000000..4fca2b6 Binary files /dev/null and b/resources/store icons/festive_preview.png differ diff --git a/resources/store icons/greekmytho_preview.png b/resources/store icons/greekmytho_preview.png new file mode 100644 index 0000000..3ad4802 Binary files /dev/null and b/resources/store icons/greekmytho_preview.png differ diff --git a/resources/store icons/halloween_preview.png b/resources/store icons/halloween_preview.png new file mode 100644 index 0000000..f5bd869 Binary files /dev/null and b/resources/store icons/halloween_preview.png differ diff --git a/resources/store icons/lbp_preview.png b/resources/store icons/lbp_preview.png new file mode 100644 index 0000000..f32cbf9 Binary files /dev/null and b/resources/store icons/lbp_preview.png differ diff --git a/resources/store icons/masseffect_preview.png b/resources/store icons/masseffect_preview.png new file mode 100644 index 0000000..95afb3b Binary files /dev/null and b/resources/store icons/masseffect_preview.png differ diff --git a/resources/store icons/natural_preview.png b/resources/store icons/natural_preview.png new file mode 100644 index 0000000..487fe0c Binary files /dev/null and b/resources/store icons/natural_preview.png differ diff --git a/resources/store icons/norsemytho_preview.png b/resources/store icons/norsemytho_preview.png new file mode 100644 index 0000000..51e1e1a Binary files /dev/null and b/resources/store icons/norsemytho_preview.png differ diff --git a/resources/store icons/pattern_preview.png b/resources/store icons/pattern_preview.png new file mode 100644 index 0000000..db0d068 Binary files /dev/null and b/resources/store icons/pattern_preview.png differ diff --git a/resources/store icons/plastic_preview.png b/resources/store icons/plastic_preview.png new file mode 100644 index 0000000..a74579f Binary files /dev/null and b/resources/store icons/plastic_preview.png differ diff --git a/resources/store icons/potc_preview.png b/resources/store icons/potc_preview.png new file mode 100644 index 0000000..25598d8 Binary files /dev/null and b/resources/store icons/potc_preview.png differ diff --git a/resources/store icons/steampunk_preview.png b/resources/store icons/steampunk_preview.png new file mode 100644 index 0000000..7c07835 Binary files /dev/null and b/resources/store icons/steampunk_preview.png differ diff --git a/resources/store icons/supercute_preview.png b/resources/store icons/supercute_preview.png new file mode 100644 index 0000000..a8a22f3 Binary files /dev/null and b/resources/store icons/supercute_preview.png differ diff --git a/resources/store icons/supermario_preview.png b/resources/store icons/supermario_preview.png new file mode 100644 index 0000000..5c38198 Binary files /dev/null and b/resources/store icons/supermario_preview.png differ diff --git a/scripts/make_bundle_preview.py b/scripts/make_bundle_preview.py new file mode 100644 index 0000000..a4b6238 --- /dev/null +++ b/scripts/make_bundle_preview.py @@ -0,0 +1,230 @@ +import argparse +import re +from pathlib import Path + +from PIL import Image, ImageColor, ImageDraw, ImageFont + + +def repo_root() -> Path: + return Path(__file__).resolve().parents[1] + + +def default_template_dir() -> Path: + return repo_root() / "resources" / "bundle preview image template" + + +def resolve_path(value: str | None, base: Path) -> Path | None: + if value is None: + return None + path = Path(value) + if path.is_absolute(): + return path + return base / path + + +def resolve_template_path(value: str, template_dir: Path, bundle_dir: Path | None) -> Path: + path = Path(value) + if path.is_absolute(): + return path + if bundle_dir: + local_path = bundle_dir / path + if local_path.exists(): + return local_path + return template_dir / path + + +def parse_box(value: str) -> tuple[int, int, int, int]: + parts = [int(part.strip()) for part in value.split(",")] + if len(parts) != 4: + raise argparse.ArgumentTypeError("Expected x,y,width,height") + return parts[0], parts[1], parts[2], parts[3] + + +def parse_color(value: str) -> tuple[int, int, int, int]: + return ImageColor.getcolor(value, "RGBA") + + +def cover_image(image: Image.Image, size: tuple[int, int]) -> Image.Image: + image = image.convert("RGBA") + scale = max(size[0] / image.width, size[1] / image.height) + resized = image.resize((round(image.width * scale), round(image.height * scale)), Image.Resampling.LANCZOS) + left = (resized.width - size[0]) // 2 + top = (resized.height - size[1]) // 2 + return resized.crop((left, top, left + size[0], top + size[1])) + + +def contain_image(image: Image.Image, max_width: int, max_height: int) -> Image.Image: + image = image.convert("RGBA") + scale = min(max_width / image.width, max_height / image.height) + return image.resize((round(image.width * scale), round(image.height * scale)), Image.Resampling.LANCZOS) + + +def paste_header(canvas: Image.Image, path: Path, width: int, y: int) -> None: + header = Image.open(path).convert("RGBA") + height = round(header.height * (width / header.width)) + header = header.resize((width, height), Image.Resampling.LANCZOS) + x = (canvas.width - header.width) // 2 + canvas.alpha_composite(header, (x, y)) + + +def paste_photos(canvas: Image.Image, paths: list[Path], box: tuple[int, int, int, int]) -> None: + x, y, width, height = box + slot_width = width // 3 + for index, path in enumerate(paths): + photo = cover_image(Image.open(path), (slot_width, height)) + canvas.alpha_composite(photo, (x + slot_width * index, y)) + + +def extend_canvas_for_rows(canvas: Image.Image, box: tuple[int, int, int, int], extra_rows: int) -> Image.Image: + if extra_rows <= 0: + return canvas + _, y, _, height = box + row_bottom = y + height + new_canvas = Image.new("RGBA", (canvas.width, canvas.height + height * extra_rows), (0, 0, 0, 0)) + new_canvas.alpha_composite(canvas.crop((0, 0, canvas.width, row_bottom)), (0, 0)) + bottom = canvas.crop((0, row_bottom, canvas.width, canvas.height)) + new_canvas.alpha_composite(bottom, (0, row_bottom + height * extra_rows)) + return new_canvas + + +def load_font(path: Path | None, size: int) -> ImageFont.FreeTypeFont | ImageFont.ImageFont: + if path and path.exists(): + return ImageFont.truetype(str(path), size) + for fallback in [ + Path("C:/Windows/Fonts/bahnschrift.ttf"), + Path("C:/Windows/Fonts/impact.ttf"), + Path("C:/Windows/Fonts/arialbd.ttf"), + ]: + if fallback.exists(): + return ImageFont.truetype(str(fallback), size) + return ImageFont.load_default() + + +def fit_text_font(text: str, font_path: Path | None, max_width: int, start_size: int, min_size: int) -> ImageFont.FreeTypeFont | ImageFont.ImageFont: + size = start_size + while size >= min_size: + font = load_font(font_path, size) + bbox = ImageDraw.Draw(Image.new("RGBA", (1, 1))).textbbox((0, 0), text, font=font, stroke_width=2) + if bbox[2] - bbox[0] <= max_width: + return font + size -= 1 + return load_font(font_path, min_size) + + +def paste_text(canvas: Image.Image, text: str, font_path: Path | None, size: int, y: int, fill: tuple[int, int, int, int], stroke: tuple[int, int, int, int], stroke_width: int, max_width: int) -> None: + font = fit_text_font(text, font_path, max_width, size, 14) + draw = ImageDraw.Draw(canvas) + bbox = draw.textbbox((0, 0), text, font=font, stroke_width=stroke_width) + x = (canvas.width - (bbox[2] - bbox[0])) // 2 + draw.text((x - bbox[0], y - bbox[1]), text, font=font, fill=fill, stroke_width=stroke_width, stroke_fill=stroke) + + +def paste_text_image(canvas: Image.Image, path: Path, y: int, max_width: int, max_height: int) -> None: + text_image = contain_image(Image.open(path), max_width, max_height) + x = (canvas.width - text_image.width) // 2 + canvas.alpha_composite(text_image, (x, y)) + + +def default_output(text: str | None) -> Path: + stem = "bundle_preview" + if text: + stem = re.sub(r"[^a-z0-9]+", "_", text.lower()).strip("_") or stem + return default_template_dir() / f"{stem}.png" + + +def require_file(path: Path, label: str) -> None: + if not path.exists(): + raise FileNotFoundError(f"Missing {label}: {path}") + + +def second_row_names(bundle_dir: Path) -> list[str] | None: + for names in [ + ["left1.png", "middle1.png", "right1.png"], + ["left2.png", "middle2.png", "right2.png"], + ]: + if any((bundle_dir / name).exists() for name in names): + return names + return None + + +def main() -> int: + parser = argparse.ArgumentParser() + parser.add_argument("--base", default="cropped_bundle_clean.png") + parser.add_argument("--header", default="header.png") + parser.add_argument("--bundle-dir") + parser.add_argument("--output-name", default="preview.png") + parser.add_argument("--no-header", action="store_true") + parser.add_argument("--header-width", type=int, default=590) + parser.add_argument("--header-y", type=int, default=22) + parser.add_argument("--photos", nargs=3) + parser.add_argument("--photos2", nargs=3) + parser.add_argument("--photo-strip", type=parse_box, default=parse_box("0,158,900,214")) + parser.add_argument("--text") + parser.add_argument("--text-image") + parser.add_argument("--text-y", type=int) + parser.add_argument("--text-size", type=int, default=34) + parser.add_argument("--text-font") + parser.add_argument("--text-fill", type=parse_color, default=parse_color("#ffffff")) + parser.add_argument("--text-stroke", type=parse_color, default=parse_color("#151515")) + parser.add_argument("--text-stroke-width", type=int, default=2) + parser.add_argument("--text-max-width", type=int, default=760) + parser.add_argument("--text-image-max-height", type=int, default=70) + parser.add_argument("--output") + args = parser.parse_args() + + template_dir = default_template_dir() + bundle_dir = resolve_path(args.bundle_dir, repo_root()) if args.bundle_dir else None + input_base = bundle_dir or repo_root() + if bundle_dir and args.photos is None: + args.photos = ["left.png", "middle.png", "right.png"] + if bundle_dir and args.photos2 is None: + args.photos2 = second_row_names(bundle_dir) + if bundle_dir and args.text_image is None and args.text is None and (bundle_dir / "text.png").exists(): + args.text_image = "text.png" + base_path = resolve_template_path(args.base, template_dir, bundle_dir) + if args.output: + output_path = resolve_path(args.output, input_base) + elif bundle_dir: + output_path = bundle_dir / args.output_name + else: + output_path = default_output(args.text) + require_file(base_path, "base image") + canvas = Image.open(base_path).convert("RGBA") + extra_rows = 1 if args.photos2 else 0 + if args.text_y is None: + args.text_y = 390 + args.photo_strip[3] * extra_rows + canvas = extend_canvas_for_rows(canvas, args.photo_strip, extra_rows) + + if args.photos: + photo_paths = [resolve_path(path, input_base) for path in args.photos] + for index, path in enumerate(photo_paths, 1): + require_file(path, f"photo {index}") + paste_photos(canvas, photo_paths, args.photo_strip) + + if args.photos2: + photo_paths = [resolve_path(path, input_base) for path in args.photos2] + for index, path in enumerate(photo_paths, 1): + require_file(path, f"second row photo {index}") + x, y, width, height = args.photo_strip + paste_photos(canvas, photo_paths, (x, y + height, width, height)) + + if not args.no_header: + header_path = resolve_template_path(args.header, template_dir, bundle_dir) + require_file(header_path, "header image") + paste_header(canvas, header_path, args.header_width, args.header_y) + + if args.text_image: + text_image_path = resolve_path(args.text_image, input_base) + require_file(text_image_path, "text image") + paste_text_image(canvas, text_image_path, args.text_y, args.text_max_width, args.text_image_max_height) + elif args.text: + paste_text(canvas, args.text, resolve_path(args.text_font, input_base), args.text_size, args.text_y, args.text_fill, args.text_stroke, args.text_stroke_width, args.text_max_width) + + output_path.parent.mkdir(parents=True, exist_ok=True) + canvas.convert("RGB").save(output_path, quality=95) + print(output_path) + return 0 + + +if __name__ == "__main__": + raise SystemExit(main())