Give Cookie script help
#3

Try now.
PHP код:
CMD:givecookie(playeridparams[]) // CMD for giving somebody a cookie
{
        new 
str[250], idcookies;
        if(
PlayerInfo[playerid][Level] >= 3)
        {
             if(
sscanf(params"ud"idcookies)) return SendClientMessage(playeridCOLOR_YELLOW"USAGE: /givecookie [Player ID] [COOKIES]");
             if(!
IsPlayerConnected(id)) return SendClientMessage(playeridCOLOR_YELLOW"PlayerID is not connected.");
             
PlayerInfo[id][Cookies] += cookies;
             
format(strsizeof(str), "**Admin %s (ID:%d) has give %d cookie to %s.(ID:%d) and %s cookie count is (%d)",PlayerName2(playerid),playeridcookiesPlayerName2(id),playerid,PlayerName2(id),PlayerInfo[id][Cookies]);
             
SendClientMessageToAll(COLOR_ORANGEstr);
             
GameTextForPlayer(id,"~g~~h~~h~Cookie",3000,4);
             
format(strsizeof(str), "**You just gave a cookie to %s."PlayerName2(id));
             
SendClientMessage(playeridCOLOR_GREENstr);
        }
        else 
SendClientMessage(playeridCOLOR_YELLOW"**You're not authorized to use this command.");
        return 
1;

Reply


Messages In This Thread
Give Cookie script help - by KyNe - 20.12.2017, 15:50
Re: Give Cookie script help - by aoky - 20.12.2017, 15:54
Re: Give Cookie script help - by DelK - 20.12.2017, 15:59
Re: Give Cookie script help - by KyNe - 20.12.2017, 16:17
Re: Give Cookie script help - by aoky - 20.12.2017, 16:26
Re: Give Cookie script help - by KyNe - 20.12.2017, 16:35
Re: Give Cookie script help - by Kaperstone - 20.12.2017, 16:37
Re: Give Cookie script help - by KyNe - 20.12.2017, 16:39
Re: Give Cookie script help - by aoky - 20.12.2017, 16:40
Re: Give Cookie script help - by KyNe - 20.12.2017, 16:42

Forum Jump:


Users browsing this thread: 3 Guest(s)