Moo-ified main script, to increase legibility