Random problem :(
#6

pawn Код:
if (strcmp("/random", cmdtext, true, 6) == 0)
{
    if(IsPlayerConnected(playerid))
    {
        new rand = random(3)+1;
        GetPlayerName(playerid, sendername, sizeof(sendername));
        new random[MAX_PLAYERS];
        if(rand == 1)
        {
            random = "happy";
        }
        if(rand == 2)
        {
            random = "very happy";
        }
        if(rand == 3)
        {
            random = "lucky";
        }
        else
        {
            random = "sad";
        }
        format(string, sizeof(string), "A player is  %s", random);
        ProxDetector(10.0, playerid, string, COLOR_PINK,COLOR_PINK,COLOR_PINK,COLOR_PINK,COLOR_PINK);
    }
    return 1;
}
Reply


Messages In This Thread
Random problem :( - by i3Cookies - 07.12.2010, 09:59
Re: Random problem :( - by Mehtab - 07.12.2010, 10:02
Re: Random problem :( - by i3Cookies - 07.12.2010, 10:04
Re: Random problem :( - by Mehtab - 07.12.2010, 10:09
Re: Random problem :( - by Celson - 07.12.2010, 10:20
Re: Random problem :( - by nutzkung69 - 07.12.2010, 10:56
Re: Random problem :( - by Voldemort - 07.12.2010, 10:57

Forum Jump:


Users browsing this thread: 1 Guest(s)