you will have to play around with the bits of the binary number. IE to represent that a class is able to equip an item SOE uses a 1, otherwise its a 0. I cant remember which order the classes are in, but say every class can wear a bandana except the necro class. The binary value would be 111111111111011. The 0 in that value would have been where the bit for necros is. Note this is just a representation for explaining how this works. But anyways getting back to your question:
1. Convert the decimal number to binary
2. Find which bit corresponds to which class.
3. Write a small if statement that checks whether the value of the bit for the class your looking for is a 0 or a 1.
pretty easy once you know how it works....hopefully I didnt confuse too many ppls
I had to do this when I was writing the code for the search tool, its a pain but pretty easy.
__________________
Lethal Encounter
|