Guys, I've seen to much times here scripters talking about optimizations for good read/visual/style on the plugin. I'm learning more about it reading tutorials and plugins on that forum. I've searched a little bit and I want know more about it.
Ok, so my question is:
If I have so much
get_user_flags() or any other native.
if I make something like this
PHP Code:
haveTheFlag(index,id = 0)
return bool:(get_user_flags(index) & id)
And use instead of all
get_user_flags() on the plugin
PHP Code:
if(haveTheFlag(id) & ADMIN_KICK)
or
PHP Code:
#define haveTheFlag(%1,%2) (get_user_flags(%1) & %2)
That can be considered an optimization? What happen with the compiler?
__________________