engine: Added safety cleanup function
curses: Fixed message handler

If the engine sent messages when the curses interface is closed, exceptions were thrown. Now the messages are routed to the stdout instead.
engine: Fixed problems with playing tag
curses: Fixed search
Merge branch 'master' of https://github.com/z411/wmal-python