How would I go about creating functions to mimic the system Quake-engine games such as Quake 2 and Half-Life use to determine dmflags, or that chmod uses to determine permissions, but on a larger scale?
(For each rule, a value is added to, and that result can in turn be used to determine which rules are in effect)
I read about bindec() and decbin(), but can't figure out how exactly I should go about doing it. Any help would be appreciated!