Added 'plugins' variable (token expander).
Moved common code for expanding messages and tokens to MessageExpander. Refactored sw and swm to use MessageExpander.

Signed-off-by: CodeFoo Games <games@codefoo.co.uk>