Changed command handling

Switched how I handled commands from reading them from the file every
time to keeping everything contained in the dict and added a stop()
function to be called whenever the program, for some reason, is
stopped. :)