09-20-2020, 09:18 AM
(09-19-2020, 10:26 PM)megamarc Wrote: [*]"num_sections" can't be calculated as you do. In C, size of arrays passed as pointers must always be specified separately, because the C runtime doesn't hold this information. In your code, num_sections will always compute to 4 because &bg[1] - &bg[0] is 4 bytes.
[/list]
Keep going!
Oh I see. I noticed what you mean when I tried different values and it broke. I thought it was working when I tried it on the platformer demo, because pos_background[6] and num_section was printing out 6. How would I go about this so that it would work correctly?
Thank you!
Cheers!