Thread
:
[TUT] Hexadecimal system
View Single Post
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
08-16-2011 , 23:35 Re: [TUT] Hexadecimal system
#
6
Quote:
Originally Posted by
Bugsy
I agree with you both, I would never use hex to replace simple numeric values just for the sake of using hex. Why use 0x13 when 19 will do? It would be especially confusing for those viewing code who are not versed in hexadecimal.
The only time I would agree with his statement is when working with bit masks. In this instance they are actually easier to use than decimal numbers.
1111 1111
= binary
255 = decimal
FF
= hex
1111
0000
1111
0000 = binary
61680 = decimal
F
0
F
0 = hex
1111
0000
1111 1111 1111
= binary
987135 = decimal
F
0
FFF
= hex
Could you explain 'bit masks' a little bit more and the usage in AMXX scripting?
Thanks.
__________________
Quote:
Originally Posted by
DarkGod
nikhilgupta generates his plugins using sheer awesome.
If you like my work, please
nikhilgupta345
View Public Profile
Send a private message to nikhilgupta345
Find More Posts by nikhilgupta345