Skip to content

Commit

Permalink
Add redef mod to update_mtg.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
LoneWolfHT committed Dec 2, 2024
1 parent 44fac2c commit 5aff1dd
Showing 1 changed file with 25 additions and 5 deletions.
30 changes: 25 additions & 5 deletions scripts/update_mtg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,17 @@
MOD_PREFIX=mtg_
MODS_TO_KEEP=(binoculars bucket butterflies creative default doors dye fire fireflies flowers map player_api screwdriver sfinv stairs tnt vessels walls wool xpanes)

cd ../mods/mtg/ # Will work if we run from inside the scripts folder
cd mods/mtg/ # Will work if we run from inside the capturetheflag folder
cd "$(dirname "$0")/../mods/mtg/"

if [ ! -f ./modpack.conf ]; then
echo "May have changed into the wrong directory, aborting."
exit
fi

git clone [email protected]:minetest/minetest_game.git
echo ""

mv minetest_game/mods .
mv ./minetest_game/mods .

echo "Updating mods..."

Expand All @@ -19,8 +24,23 @@ done

echo "Done. Removing unneeded folders..."

rm -r mods/
rm -r ./mods

rm -rf minetest_game/
rm -rf ./minetest_game

echo "Done. minetest_game mods are updated!"

echo ""
echo "Applying redef mod..."

rm -r ./redef

echo ""
git clone https://git.0x7be.net/dirk/redef.git
echo ""

rm -rf ./redef/.git

sed -i -e "s/\['Maximum Stack Size'\]/--\['Maximum Stack Size'\]/g" ./redef/init.lua # Comment out the stack size change

echo "Done. redef applied!"

0 comments on commit 5aff1dd

Please sign in to comment.