You need to loop through each player.
PHP Code:
function onPlayerChats() { // player chats in the level
if (player.guild == "Events Team") {
if (player.chat.starts("/kick")) { // chat starts with /kick
temp.num = player.chat.substring(6).trim(); // find the number the ET said
for (temp.pl : players) { // loop through each player
if (pl.client.chance == num) { // it's the number the ET called
pl.setLevel2("chance.nw", 25, 45); // warp that player (note "pl."setLevel2)
}
}
}
}
}
You should also consider using clientr variables, or even player. variables serverside (this is preferable for something like this).
Keep in mind you should only use the above script in the level once.