/cnnnn Problem.
#1

Hi guys,
First I show my CMD :
pawn Код:
if(strcmp(cmd, "/cnnnn", true) == 0)
    {
        if(PlayerInfo[playerid][pAdmin] >= 3)
        {
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, COLOR_WHITE, "Dastoor: /cnnnn <text> ");
                return 1;
            }
            new length = strlen(cmdtext);
            while ((idx < length) && (cmdtext[idx] <= ' '))
            {
                idx++;
            }
            new offset = idx;
            new result[128];
            while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
            {
                result[idx - offset] = cmdtext[idx];
                idx++;
            }
            result[idx - offset] = EOS;
            format(string, sizeof(string), "%s",result);
            foreach (Player, i)
            {
                if(IsPlayerConnected(i) == 1)
                {
                    displayCenterHUDInfo(i, string, 5);
                }
            }
            return 1;
        }
        else
        {
            SendClientMessage(playerid, COLOR_GRAD1, "   Shoma dastresie kafi baraye anjame inkar ra nadarid !");
            return 1;
        }
    }
The problem is here that, When I type "/cnnnn Hi Guys" for example, It only shows "Guys" word.
I want to get "Hi Guys" not only "Guys".
Also , displayCenterHUDInfo is like SendClientMessage ...
+Rep for the best answer.
Reply


Messages In This Thread
/cnnnn Problem. - by Alpay0098 - 15.06.2015, 10:14
Re: /cnnnn Problem. - by bgedition - 15.06.2015, 11:10
Re: /cnnnn Problem. - by Alpay0098 - 15.06.2015, 11:38
Re: /cnnnn Problem. - by bgedition - 15.06.2015, 11:45
Re: /cnnnn Problem. - by Ritzy2K - 15.06.2015, 11:48
Re: /cnnnn Problem. - by bgedition - 15.06.2015, 11:51
Re : /cnnnn Problem. - by Dutheil - 15.06.2015, 11:52
Re: /cnnnn Problem. - by Alpay0098 - 15.06.2015, 12:47
Re: /cnnnn Problem. - by bgedition - 15.06.2015, 16:04
Re: /cnnnn Problem. - by Alpay0098 - 15.06.2015, 16:27

Forum Jump:


Users browsing this thread: 1 Guest(s)