26.09.2010, 16:24
Failed? Well obviously they fail when you're not using them properly. With that logic, I can say gas fails because it can't run my diesel boat.
Consider utilizing bit manipulation aswell as using the "char" keyword (arrays with the char keyword will contain only 1 byte per slot; however, only capable of carrying 8 bits (value 0-255)).
If you, for example, have a variable that tells you whether a player is in a race or not, you could store 1 value per bit; thus, using only 16 cells for 500 players.
Quote:
Yes, and if you think about it, that's gonna come back and bite you later on, when you have a bunch of slow PVars for your script to continuously process.
I use PVars in certain cases, as it seems more practical and more efficient, say for example I have a variable that really only has 1 use, no point creating a normal player variable for it, waste of 500 cells (or whatever MAX_PLAYERS is defined as). |
If you, for example, have a variable that tells you whether a player is in a race or not, you could store 1 value per bit; thus, using only 16 cells for 500 players.