Quote:
Originally Posted by SEnergy
pawn Код:
for(i=0;AllPlayers[i]!=-1;i++){} AllPlayers[i]=playerid; AllPlayers[i+1]=-1;
what is this supposed to do?
|
That code loops AllPlayers array until the AllPlayers[i]!=-1. In other words, it finds the first place in the array, where there is not stored any playerid.(playerid are from 0 to 499).
After finding it, it stores the playerid in the "free" array space, and make sure the next cell is free.
After seeing your question I realized I missed one part of the code. Edited first post.