One question.
#7

In my personal theory, stock is just like a function. It's a bunch of functions inside other function, like..
pawn Код:
OnPlayerConnect(playerid)
{
    WelcomePlayer();
}

stock WelcomePlayer();
{
        new string[50], pname[MAX_PLAYER_NAME];
    GetPlayerName(playerid, pname, sizeof(pname));
    format(string, sizeof(string), "%s has joined the server", pname);
    SendClientMessageToAll(COLOR_YELLOW, string);
}
You can also add extra parameters like..

pawn Код:
WelcomePlayer(color);
But i yet dont know how to do that.
Reply


Messages In This Thread
One question. - by [Comrade] - 15.12.2010, 01:57
Re: One question. - by admantis - 15.12.2010, 02:00
Re: One question. - by XePloiT - 15.12.2010, 02:03
Re: One question. - by [Comrade] - 15.12.2010, 02:05
Re: One question. - by admantis - 15.12.2010, 02:07
Re: One question. - by [Comrade] - 15.12.2010, 02:08
Re: One question. - by admantis - 15.12.2010, 02:11
Re: One question. - by [Comrade] - 15.12.2010, 02:12
Re: One question. - by admantis - 15.12.2010, 02:13
Re: One question. - by XePloiT - 15.12.2010, 02:17

Forum Jump:


Users browsing this thread: 3 Guest(s)