MediEvil Rolling Demo/Enemies: Difference between revisions

Line 12: Line 12:


(16 >> 2) * 25</pre>
(16 >> 2) * 25</pre>
In order to bitshift the decimal number '''16''' by 2, we first need to convert it into binary, which gives us '''10000'''. Then we need to discard the last two digits, which will give us the binary number '''100'''. This is the binary form of the decimal number '''4'''.
In order to bitshift the decimal number '''16''' by 2, we first need to convert it into binary, which is '''10000'''. Then, we need to discard the last two digits, which will give us the binary number '''100'''. This is the binary form of the decimal number '''4'''.
<pre>4 * 25 = 100</pre>
<pre>4 * 25 = 100</pre>