mirror of
https://gitlab.com/Nanolx/patchimage.git
synced 2024-11-01 07:15:06 +01:00
add support for changing first player character in kirbys adventure wii
This commit is contained in:
parent
18a1020a67
commit
dba36f2324
@ -1,3 +1,9 @@
|
||||
v4.95:
|
||||
- fixed storing NewSMB mods into ${PATCHIMAGE_GAME_DIR}
|
||||
- added support for exchanging first player's character
|
||||
in Kirby's Adventure Wii (using someone different than
|
||||
one of the different Kirbys may crash the game)
|
||||
|
||||
v4.94:
|
||||
- wiimmfi generic: use correct version of wit
|
||||
- wiimmfi mario kart: major code simplification and major speed-up
|
||||
|
@ -103,10 +103,14 @@ case ${GAME} in
|
||||
source ${PATCHIMAGE_SCRIPT_DIR}/mkwiimm.sh
|
||||
;;
|
||||
|
||||
q | Q | Sykland )
|
||||
r | R | Sykland )
|
||||
source ${PATCHIMAGE_SCRIPT_DIR}/skyland.sh
|
||||
;;
|
||||
|
||||
s | S | Kirby )
|
||||
source ${PATCHIMAGE_SCRIPT_DIR}/kirbywii.sh
|
||||
;;
|
||||
|
||||
1 | ParallelWorlds | "The Legend of Zelda: Parallel Worlds" )
|
||||
source ${PATCHIMAGE_SCRIPT_DIR}/parallelworlds.sh
|
||||
;;
|
||||
@ -167,9 +171,9 @@ case ${GAME_TYPE} in
|
||||
echo "*** 10) rebuild game"
|
||||
${WIT} cp -q -B ${WORKDIR} ${GAMEID}.wbfs --disc-id=${GAMEID} ${TMD_OPTS} --name "${GAMENAME}" || exit 51
|
||||
|
||||
if [[ -d ${PATCHIMAGE_WBFS_DIR} && ${PATCHIMAGE_WBFS_DIR} != ${PWD} ]]; then
|
||||
if [[ -d ${PATCHIMAGE_GAME_DIR} && ${PATCHIMAGE_GAME_DIR} != ${PWD} ]]; then
|
||||
echo "*** 11) store game"
|
||||
mv ${GAMEID}.wbfs "${PATCHIMAGE_WBFS_DIR}"/
|
||||
mv ${GAMEID}.wbfs "${PATCHIMAGE_GAME_DIR}"/
|
||||
fi
|
||||
|
||||
echo "*** 12) remove workdir"
|
||||
@ -197,6 +201,15 @@ case ${GAME_TYPE} in
|
||||
patch_wiimm
|
||||
;;
|
||||
|
||||
"WII_GENERIC")
|
||||
show_notes
|
||||
|
||||
echo -e "\n*** 1) check_input_image"
|
||||
check_input_image
|
||||
echo -e "\n*** 2) pi_action"
|
||||
pi_action
|
||||
;;
|
||||
|
||||
"IPS" )
|
||||
show_notes
|
||||
check_input_rom
|
||||
|
@ -61,9 +61,11 @@ M Awesomer Super Luigi Mini
|
||||
N Wiimfi Patcher. Patch Mario Kart to use Wiimm's server
|
||||
O Wiimfi Patcher. Patch WFC games to use Wiimm's server (exp)
|
||||
P Mario Kart Wiimm. Custom Mario Kart Distribution
|
||||
Q *** comming soon ***
|
||||
<<<>>>
|
||||
|
||||
Q Super Mario Skyland
|
||||
R Super Mario Skyland
|
||||
S Kirby's Adventure Wii (change first player character)
|
||||
|
||||
1 The Legend of Zelda: Parallel Worlds
|
||||
"
|
||||
@ -202,6 +204,31 @@ check_input_image_nsmb () {
|
||||
|
||||
}
|
||||
|
||||
check_input_image_kirby () {
|
||||
|
||||
x=0
|
||||
if [[ ! ${IMAGE} ]]; then
|
||||
if test -f SMN?01.wbfs; then
|
||||
x=1
|
||||
IMAGE=SMN?01.wbfs
|
||||
elif test -f SMN?01.iso; then
|
||||
x=2
|
||||
IMAGE=SMN?01.iso
|
||||
elif test -f ${PATCHIMAGE_WBFS_DIR}/SUK?01.iso; then
|
||||
x=3
|
||||
IMAGE=${PATCHIMAGE_WBFS_DIR}/SUK?01.iso
|
||||
elif test -f ${PATCHIMAGE_WBFS_DIR}/SUK?01.wbfs; then
|
||||
x=4
|
||||
IMAGE=${PATCHIMAGE_WBFS_DIR}/SUK?01.wbfs
|
||||
else
|
||||
echo -e "please specify image to use with --iso=<path>"
|
||||
exit 15
|
||||
fi
|
||||
fi
|
||||
echo "*** >> status: ${x}"
|
||||
|
||||
}
|
||||
|
||||
check_input_image_mkwiimm () {
|
||||
|
||||
x=0
|
||||
@ -469,7 +496,7 @@ while [[ $xcount -lt $pcount ]]; do
|
||||
;;
|
||||
|
||||
"" | --help )
|
||||
echo -e "patchimage 4.93 (2014-05-13)
|
||||
echo -e "patchimage 4.95 (2014-05-15)
|
||||
|
||||
(c) 2013-2014 Christopher Roy Bratusek <nano@jpberlin.de>
|
||||
patchimage creates wbfs images from riivolution patches.
|
||||
|
110
script.d/kirbywii.sh
Normal file
110
script.d/kirbywii.sh
Normal file
@ -0,0 +1,110 @@
|
||||
#!/bin/bash
|
||||
|
||||
GAME_TYPE="WII_GENERIC"
|
||||
GAME_NAME="Kirby's Adventure Wii"
|
||||
|
||||
show_notes () {
|
||||
|
||||
echo -e \
|
||||
"************************************************
|
||||
${GAMENAME}
|
||||
|
||||
Base Image: Kirby's Adventure Wii (SUK?01)
|
||||
Supported Versions: EUR, JAP, USA
|
||||
************************************************"
|
||||
|
||||
}
|
||||
|
||||
PATH_HERO="files/g3d/step/chara/hero/"
|
||||
|
||||
pi_action () {
|
||||
|
||||
check_input_image_kirby
|
||||
|
||||
echo "Choose character for first player
|
||||
|
||||
1 Kirby (blue)
|
||||
2 Kirby (yellow)
|
||||
3 Kirby (green)
|
||||
|
||||
*** options 4 to 6 may crash the game upon start ***
|
||||
4 King DeDeDe
|
||||
5 MetaKnight
|
||||
6 WaddleDee
|
||||
|
||||
7 Restore to original
|
||||
|
||||
type in an number."
|
||||
read ID
|
||||
|
||||
[[ ${ID} != [0-9] ]] && echo "invalid number provided from user-input." && exit 1
|
||||
|
||||
rm -rf workdir
|
||||
|
||||
echo -e "\n*** 3) extracting images"
|
||||
${WIT} extract ${IMAGE} --psel=data -d workdir -q || exit 51
|
||||
|
||||
if [[ ! -d "${PATCHIMAGE_RIIVOLUTION_DIR}"/hero/ ]]; then
|
||||
echo -e "\n*** 4) this is the first run, so backing up all characters
|
||||
(in ${PATCHIMAGE_RIIVOLUTION_DIR}) for future customizations"
|
||||
cp -r workdir/${PATH_HERO}/ "${PATCHIMAGE_RIIVOLUTION_DIR}"
|
||||
else
|
||||
echo -e "\n*** 4) restoring original characters"
|
||||
cp -r "${PATCHIMAGE_RIIVOLUTION_DIR}"/hero/* workdir/${PATH_HERO}/
|
||||
fi
|
||||
|
||||
REG=$(gawk '/^SUK/{print $3}' <(wit ll ${IMAGE}))
|
||||
|
||||
case $REG in
|
||||
PAL) REG=P ;;
|
||||
NTSC-J) REG=J ;;
|
||||
NTSC-U) REG=E ;;
|
||||
esac
|
||||
|
||||
[[ ${ID} != 7 ]] && echo "*** 5) exchanging characters"
|
||||
case ${ID} in
|
||||
1) cp workdir/${PATH_HERO}/kirby/base/Blue.brres.cmp{,_tmp}
|
||||
cp workdir/${PATH_HERO}/kirby/base/{Pink,Blue}.brres.cmp
|
||||
mv workdir/${PATH_HERO}/kirby/base/{Blue.brres.cmp_tmp,Pink.brres.cmp}
|
||||
;;
|
||||
|
||||
2) cp workdir/${PATH_HERO}/kirby/base/Yellow.brres.cmp{,_tmp}
|
||||
cp workdir/${PATH_HERO}/kirby/base/{Pink,Yellow}.brres.cmp
|
||||
mv workdir/${PATH_HERO}/kirby/base/{Yellow.brres.cmp_tmp,Pink.brres.cmp}
|
||||
;;
|
||||
|
||||
3) cp workdir/${PATH_HERO}/kirby/base/Green.brres.cmp{,_tmp}
|
||||
cp workdir/${PATH_HERO}/kirby/base/{Pink,Green}.brres.cmp
|
||||
mv workdir/${PATH_HERO}/kirby/base/{Green.brres.cmp_tmp,Pink.brres.cmp}
|
||||
;;
|
||||
|
||||
4) cp workdir/${PATH_HERO}/dedede/base/Default.brres.cmp \
|
||||
workdir/${PATH_HERO}/kirby/base/Pink.brres.cmp
|
||||
cp workdir/${PATH_HERO}/dedede/normal/*.cmp \
|
||||
workdir/${PATH_HERO}/kirby/normal/
|
||||
;;
|
||||
|
||||
5) cp workdir/${PATH_HERO}/meta/base/Default.brres.cmp \
|
||||
workdir/${PATH_HERO}/kirby/base/Pink.brres.cmp
|
||||
cp workdir/${PATH_HERO}/meta/normal/*.cmp \
|
||||
workdir/${PATH_HERO}/kirby/normal/
|
||||
;;
|
||||
|
||||
6) cp workdir/${PATH_HERO}/de/base/Default.brres.cmp \
|
||||
workdir/${PATH_HERO}/kirby/base/Pink.brres.cmp
|
||||
cp workdir/${PATH_HERO}/dee/normal/*.cmp \
|
||||
workdir/${PATH_HERO}/kirby/normal/
|
||||
;;
|
||||
esac
|
||||
|
||||
echo "*** 6) rebuilding the game"
|
||||
${WIT} cp -q -B workdir SUK${REG}01.wbfs || exit 51
|
||||
|
||||
if [[ -d ${PATCHIMAGE_GAME_DIR} && ${PATCHIMAGE_GAME_DIR} != ${PWD} ]]; then
|
||||
echo "*** 7) storing game in ${PATCHIMAGE_GAME_DIR}"
|
||||
mv SUK${REG}01.wbfs "${PATCHIMAGE_GAME_DIR}"/
|
||||
fi
|
||||
|
||||
rm -rf workdir
|
||||
|
||||
}
|
@ -20,7 +20,7 @@ Supported Versions: EUR, JAP, USA
|
||||
|
||||
check_input_image_special () {
|
||||
|
||||
check_input_image_mkwiimm
|
||||
check_input_image_kirby
|
||||
|
||||
}
|
||||
|
||||
@ -61,7 +61,7 @@ build_mkwiimm () {
|
||||
cd ${FILENAME/.7z}
|
||||
ln -s ${IMAGE} .
|
||||
|
||||
REG=$(gawk '/^RMC/{print $3}' <(wit ll /media/chris/WiiHDDX/wbfs/RMCP01.wbfs))
|
||||
REG=$(gawk '/^RMC/{print $3}' <(wit ll ${IMAGE}))
|
||||
|
||||
case $REG in
|
||||
PAL) REG=P ;;
|
||||
|
Loading…
Reference in New Issue
Block a user