Problem in my racing system
#3

Omg I'm an idiot...

Anyways it works, however I have another question related to this one aswell so here's the code:
pawn Код:
public HalfSecondTimer(playerid)
{
    for(new i = 0; i < MAX_RACES; i++)
    {
        if(IsPlayerInRangeOfPoint(playerid, 10.0, RInfo[i][CPX][0], RInfo[i][CPY][0], RInfo[i][CPZ][0]))
        {
            new Float:PX, Float:PY, Float:PZ;
            new raceid;
            raceid = i;
            PX = RInfo[raceid][CPX][0];
            PY = RInfo[raceid][CPY][0];
            PZ = RInfo[raceid][CPZ][0];
           
            JoinPickup = CreatePickup(1317, 1, PX,PY,PZ, -1);
           
            SendClientMessage(playerid,COLOR_YELLOW ,"Test");
        }
        else
        {
            DestroyPickup(JoinPickup);
        }
    }
    return 1;
}
So to to clean things up I changed it into a pickup.
Anyways what I wanted to ask was, how do I stop the loop? so that when the loop found the right checkpoint it stops looping, because now when I am in the checkpoint I get spammed with the clientmessage ("test")...
Reply


Messages In This Thread
Problem in my racing system - by knackworst - 04.09.2013, 13:34
Re: Problem in my racing system - by Konstantinos - 04.09.2013, 14:11
Re: Problem in my racing system - by knackworst - 04.09.2013, 14:24
Re: Problem in my racing system - by Dragonsaurus - 04.09.2013, 14:46
Re: Problem in my racing system - by Konstantinos - 04.09.2013, 14:46
Re: Problem in my racing system - by knackworst - 04.09.2013, 16:24
Re: Problem in my racing system - by Konstantinos - 04.09.2013, 16:30
Re: Problem in my racing system - by knackworst - 04.09.2013, 16:52
Re: Problem in my racing system - by knackworst - 04.09.2013, 17:04
Re: Problem in my racing system - by Konstantinos - 04.09.2013, 17:20

Forum Jump:


Users browsing this thread: 1 Guest(s)