Refactor commands

Commands are now implemented as tables contained in loveos.commands.
Each command is a table that contains the function that the command calls,
as well as all the metadata about the command.

This also fixes the issues presented in #1.