15.04.2016, 13:55
Foreach only loops over the connected players, it doesn't use MAX_PLAYERS so on those loop you won't save anything. Normal for loops will obviously loop less as the value is lower, which would be a little faster.
Redefining MAX_PLAYERS will also reduce the amount of memory used, especially with arrays of playerdata.
But I wouldn't redefine my MAX_PLAYERS on 200 if I have 500 slots available without lowering the amount of slots.
Redefining MAX_PLAYERS will also reduce the amount of memory used, especially with arrays of playerdata.
But I wouldn't redefine my MAX_PLAYERS on 200 if I have 500 slots available without lowering the amount of slots.