Version 2 – A little fix
Just before we get to the optimization, we need a quick fix. Version 2 fixes an issue so it doesn’t crap out when the last sprite byte is zero. You can see the
cmpx #sp_end and
beq render at line 16 & 17. This checks to see if we have reached the last byte and exits if so.
The original is on the left, version 2 on the right.
Next, Version 3