Added support to send messages to players.

* Added ChatTypes.
* Updated API.
* minor cleanup.