A Question about Scripting
#1

I been making a script llately and i keep coming across this when i look at other peoples scripts.

pawn Код:
for(new i = 0; i < MAX_PLAYERS; i++)
    {
Ive seen this quite alot and not totally sure what it means but i asume it does somthing like, Chooses everyone in the game? im not really that sure.... IF someone could explain it, that wuld be great,

Also if it does what i think it does, so it chooses all players in the game, would this code work?(it wont be accurate cos im typeing it straight into the forum box)

pawn Код:
for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
                if(stracci[playerid] == 1)  
            {
                SetCheckpoint(blahblah)  
            }  
        }
    }

So if that script was to work, It would set a checkpoint for all Stracci Members...so would that work, im not sure because i still confused about that first bit...Thanks for help everyone!

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)