| screen_name |
08-22-2009 01:41 PM |
Exactly what I meant. I was thinking that you could do something like this;
PHP Code:
function onPlayerChats() {
temp.pc = player.chat.tokenize();
switch (pc[0]) {
case "+":
switch (pc[1]) {
case "gold":
break;
case "item":
break;
case "health":
break;
default:
player.chat = "Invalid parameter";
break;
}
break;
case "?":
break;
default:
break;
}
}
Something of the sort. I realize after typing that though, if I wanted the ? command to display help, then there would be a lot of extra typing.
|