27 Nov, Rhien wrote in the 62nd comment:

I know I'm a few years late but I'll probably keep dev'ing on ROM until I'm dead because fun. For posterity, I just got rid of number_bits all together and replaced those calls with the number_range equivalent which is far more readable and in some cases as pointed here more efficient (like that call in the Thac0 that while loops until it's under a number, blech).

number_bits(1) => number_range(0, 1)

number_bits(2) => number_range(0, 3)

number_bits(3) => number_range(0, 7)

number_bits(4) => number_range(0, 15)

number_bits(5) => number_range(0, 31)

number_bits(6) => number_range(0, 63)

number_bits(7) => number_range(0, 127)

number_bits(8) => number_range(0, 255)

number_bits(9) => number_range(0, 511)

Global find and replace that and let it be buried on the trash heap of history.

number_bits(1) => number_range(0, 1)

number_bits(2) => number_range(0, 3)

number_bits(3) => number_range(0, 7)

number_bits(4) => number_range(0, 15)

number_bits(5) => number_range(0, 31)

number_bits(6) => number_range(0, 63)

number_bits(7) => number_range(0, 127)

number_bits(8) => number_range(0, 255)

number_bits(9) => number_range(0, 511)

Global find and replace that and let it be buried on the trash heap of history.

Random Picks

60.0/62

Votes:0