if anyone uses inux - i have extended my Bash game extraction Script to also convert model files.
Prerequisites:
=> Requires Wine
=> Copy the Ego X Rebirth Tools from an existing installation over to linux (next to the X Rebirth folder - like in windows)
=> Extract this Program into that Folder
=> put the code below in a shell Script also in the tools Folder and make it executeable:
Code: Select all
#!/bin/bash
cd ../X\ Rebirth
date +"%T"
echo "================================================================"
# Delete previously extracted Files - we want a fresh extraction
if [ -d XR_extracted ]; then
echo "============= removing previously extracted Files.. ============"
rm -rf XR_extracted
echo "============= done.™ ==========================================="
fi
date +"%T"
# Create Folder for Extracting all Cats/Dats and extract them there
mkdir XR_extracted
echo "============= extracting current Game files... ================="
wine ../X\ Rebirth\ Tools/XRCatTool.exe -in *.cat -out XR_extracted
echo "============= done.™ ==========================================="
date +"%T"
echo "============= converting mesh files... ========================"
# Convert all mesh files
for f in $(find XR_extracted/assets -name '*.xml'); do
echo -ne "================================================================"\\r
echo "= converting $f"
wine ../X\ Rebirth\ Tools/XRConvertersMain.exe importxmf ./XR_extracted $f
done
echo "============= done.™ ==========================================="
date +"%T"
#
# Do the same for all Extensions present - seperate cases for subst(itute) and ext(ension) cats/dats
for f in extensions/*; do
echo "================================================================"
date +"%T"
echo -ne "================================================================"\\r
echo "=========== extracting $f "
if [ -f "$f/ext_01.cat" ]; then
echo "= ext part ====================================================="
if [ -d "$f/ext" ]; then
rm -rf $f/ext
fi
mkdir "$f/ext"
wine ../X\ Rebirth\ Tools/XRCatTool.exe -in $f/ext_*.cat -out "$f/ext"
fi
if [ -f "$f/subst_01.cat" ]; then
echo "= subst part ===================================================="
if [ -d "$f/subst" ]; then
rm -rf $f/subst
fi
mkdir "$f/subst"
wine ../X\ Rebirth\ Tools/XRCatTool.exe -in $f/subst_*.cat -out "$f/subst"
fi
echo "= done.™ ======================================================="
done
echo "= Extraction of Game and Mod Files complete - have fun ;) ======"
echo "================================================================"
date +"%T"
it extracts all files from the Cats/Dats into a folder called XR_extracted in the Game Root, converts all model files in the assets Folder there to dae and after that extracts all mod cats/dats in an ext sub-folder for the ext one and an subst sub-folder for the subst cats/dats. no model conversion for mods/dlcs yet..
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help