Since a lot of people have problems with sethat and so on, here is a script for the sethat command. Ik this is not your request but maybe it will help people in the future:
PHP Code:
//#CLIENTSIDE
function onPlayerChats()
{
tokens = player.chat.tokenize();
if (player.chat.starts("sethat")) {
player.attr[1] = tokens[1];
}
}