24.05.2011, 15:18
Hello,
I got a question about the switch() function.
Here is an example:
Is there any reason to add a "else" inside this switch or something?
Any ideas?
Thanks
I got a question about the switch() function.
Here is an example:
pawn Код:
switch(reason)
{
case 0:
{
format(string, sizeof(string), "[%d] %s has left the server. (Crashed)",playerid, pName);
}
case 1:
{
format(string, sizeof(string), "[%d] %s has left the server. (Leaving)",playerid, pName);
}
case 2:
{
format(string, sizeof(string),"[%d] %s has left the server. (Kicked/Banned)",playerid, pName);
}
}
Any ideas?
Thanks