My old code reads a spritesheet (rows = different buttons, cols = different button states) one row at a time using for loops and divides them into individual sprite clips. All the sprites are the same size. Works fine.
Now, I want to put the elements of the clipping for loops into a struct so that I can write a single clipping function to iterate through every graphic on a given spritesheet. Running into a few problems getting everything to work. Something changed with the enums when I put them in the struct, and I think I screwed up the nested for loop.
its not the same code...
there is nothing at all like the line 14 for loop in the original.
the original has 1* (bug or derp?) and you have j*
the first thing to do if you want the same answer is to do the same things. If you try to move it to a new format AND change it at the same time, it will inevitably be difficult to get right. Once it does the same thing, then you can tweak it to do something similar but different and test that.