Overhauled main script to reflect latest changes to the translation system.