Files
neoLegacy/tools/patch_reset_end.sh
T
Tranqlmao ff562d1644 TU46 Test content and patches
TU46 Test content, added missing commits by amending commit and cherry-picking to new branch, ready for iggy guis and tu46 bug fixes
2026-10-22 13:55:39 -04:00

22 lines
752 B
Bash

set -e
TOOLS="$(cd "$(dirname "$0")" && pwd -W)"
MEDIA="$TOOLS/../Minecraft.Client/Common/Media/MediaWindows64"
FFDEC_DIR="${FFDEC_DIR:-C:/Program Files (x86)/FFDec}"
WORK="$TOOLS/.reset_end_work"
rm -rf "$WORK"
javac -cp "$FFDEC_DIR/lib/*" -d "$TOOLS" "$TOOLS/AddResetEndCheckbox.java"
for res in 1080 720 480; do
swf="$MEDIA/LaunchMoreOptionsMenu$res.swf"
out="$WORK/$res"
mkdir -p "$out"
java -cp "$FFDEC_DIR/lib/*;$TOOLS" AddResetEndCheckbox "$swf" "$out/step1.swf"
"$FFDEC_DIR/ffdec-cli.exe" -export script "$out/as" "$out/step1.swf" > /dev/null
perl "$TOOLS/patch_reset_end_as.pl" "$out/as/scripts"
"$FFDEC_DIR/ffdec-cli.exe" -importScript "$out/step1.swf" "$swf" "$out/as/scripts"
done
rm -rf "$WORK"
echo "Done."