Replacing main.c
Making some of the functions static
Removing the tests
Merging the battle loop into the main loop