You could do it in a different way:
PHP Code:
#define bit(%1) (1<<%1)
enum _:option_enum
{
OPTION_1,
OPTION_2,
OPTION_3
}
new const option_list[option_enum][] =
{
"Option 1",
"Option 2",
"Option 3"
}
new g_client_options[33]
// Check if player has the option
for(new i = 0; i < option_enum; i++)
{
if( g_client_options[ client] & bit(i) )
{
}
}
// Add option to player
g_client_options[client] |= bit( Option_%i )
It's been a long time, so not sure "Option_1" can be actually "zero".
But you get the point.
__________________