Quote:
Originally Posted by avril-lavigne
I know its simple ... brain exploding.
new Float:speedlvl[33]
I need to save 7 levels there like { 250.0, 270.0, .... etc }
new Float:speedlvl[33][7] ??
|
There is no reason to store each of the speeds for each person. Simply have one array for players that contains the speed level number and have another array for the speeds.
PHP Code:
new g_iPlayerSpeedLevel[33]
new Float:g_fSpeedLevesl[7] = {250.0, 270.0, .... etc}
Then, when you need to get a player's speed, you simply do this:
PHP Code:
new Float:ThisPlayersSpeed = g_fSpeedLevels[g_iPlayerSpeedLevel[id]]
where 'id' is the player index.
__________________