Thread
:
[TUT] Bits, Bit-fields, and Bit-wise Operators
View Single Post
eyal282
Veteran Member
Join Date: Aug 2011
06-06-2017 , 17:07 Re: [TUT] Bits, Bit-fields, and Bit-wise Operators
#
80
Quote:
Originally Posted by
Bugsy
SetUserBool(%1,%2) ( %1 |= (1 << (%2 - 1)))
You used |= instead of left shift and you should shift 1, not %1, but yea that will work as long as only 1 to 32 are inputted. Same logic as using ( %2 & 31 ).
Yeah, mistake.
eyal282
View Public Profile
Send a private message to eyal282
Visit eyal282's homepage!
Find More Posts by eyal282