What Happen here...?
#1

IDK why the Script Spams the same thing when it has the others to manage

did i do something wrong?

pawn Код:
public BeginRace()
{
    if(setracestart == 1)
    {
        for(new i = 0; i < GetMaxPlayers(); i++)
        {
        if(playerinrace[i] == 1 && rcount == 0)
            {
            GameTextForPlayer(i,"~w~Get ready!",1000,4);
            PlayerPlaySound(i, 1052, 0, 0, 0);
            print("RACE: 4");
           
            format(str, sizeof(str), "~p~Get ready to race!");
                TextDrawSetString(BarTD[i], str);
            }
        if(playerinrace[i] == 1 && rcount == 1)
            {
            GameTextForPlayer(i,"~g~3",1000,3);
            PlayerPlaySound(i, 1053, 0, 0, 0);
            print("RACE: 3");
           
            format(str, sizeof(str), "~p~3");
                TextDrawSetString(BarTD[i], str);
            }
        if(playerinrace[i] == 1 && rcount == 2)
            {
            GameTextForPlayer(i,"~g~2",1000,3);
            PlayerPlaySound(i, 1053, 0, 0, 0);
            print("RACE: 2");
           
            format(str, sizeof(str), "~p~2");
                TextDrawSetString(BarTD[i], str);
            }
        if(playerinrace[i] == 1 && rcount == 3)
            {
            GameTextForPlayer(i,"~g~1",1000,3);
            PlayerPlaySound(i, 1053, 0, 0, 0);
                print("RACE: 1");
               
                format(str, sizeof(str), "~p~1");
                TextDrawSetString(BarTD[i], str);
            }
        if(playerinrace[i] == 1 && rcount == 4)
            {
            GameTextForPlayer(i,"~r~Let's roll!", 2000, 3);
            PlayerPlaySound(i, 1085, 0, 0, 0);
            TogglePlayerControllable(i, 1);
            SetPlayerCheckpoint(i, checkpoints[0][0], checkpoints[0][1], checkpoints[0][2], 8);

        format(str, sizeof(str), "~r~Go, Go, Go!");
                TextDrawSetString(BarTD[i], str);
               
                SecondTimer[i] = SetTimerEx("CountSeconds", 910, true, "i", i);
                UpdateTimer[i] = SetTimerEx("UpdateTD", 910, true, "i", i);
                print("RACE: started");
            raceon = 1;
            }
        }

        rcount = rcount + 1;
    }

    return 1;
}
Reply


Messages In This Thread
What Happen here...? - by HydraX - 21.07.2009, 23:12
Re: What Happen here...? - by yezizhu - 22.07.2009, 05:39
Re: What Happen here...? - by HydraX - 22.07.2009, 06:31
Re: What Happen here...? - by yezizhu - 22.07.2009, 07:14

Forum Jump:


Users browsing this thread: 1 Guest(s)