Added clearCommand, invokeCommand, and flush

You can now call and remove commands from the console as needed, also
fixed a() such that anything passed in is automatically tostring'd.

Flush will write the entire log to disk, very useful for debugging.
Might be worth doing automatically when the game quits or the log has
had more than a certain number of lines added to it.