A tip is to use switch statements.
ex:
Code:
switch(key) {
case 0:
{
client_print(id, print_chat, "You have pressed key number 1");
dosomething(id);
}
case 1:
{
client_print(id, print_chat, "You have pressed key number 2");
dosomething(id);
}
case 2:
{
//etc..
}
}