Add bitwise SetFlags for AdminId and GroupId#1677
Add bitwise SetFlags for AdminId and GroupId#1677peace-maker merged 3 commits intoalliedmodders:masterfrom
Conversation
|
I'm not a fan of mixing the This doesn't have to be implemented in C++ though and could be inlined in the SourcePawn methodmap. |
So before I rewrite it for the methodmap, would it be better to rename it slightly to avoid confusion?
The reason I wrote it as a native is because I wasn't sure if repeatedly calling the other natives |
|
If I should add non-methodmap versions let me know |
peace-maker
left a comment
There was a problem hiding this comment.
Looks good and SetBitFlags is more descriptive as well. Thank you!
Add a method to AdminId and GroupId that allows you to set multiple admin flags at a time using bitwise ADMFLAG_* values instead of the AdminFlag enum.
Tested with the following code, not that it was really necessary: