stardance has been extended another month! the new deadline is october 31 :)

You are browsing as a guest. Sign up (or log in) to start making projects!

3h 24m 12s logged

Failing Tests

Hello everybody! We’re back with another devlog! Let’s dive right in so I can got to bed!

All Tests Pass

A good bit of test writing has happened since the last devlog. The ROM suite has gone from a measly 3 tests to a much nicer 16, though still incomplete.
I wrote more tests to test combinations of roms and save sizes that are meant to work, as well as a bunch of those that also test RTC functionality for MBC3.
I ended up putting ROM construction into a helper, as well as making a helper for most of the save round trip tests, probably saving a few hundred lines of code.
Next tests are probably going to be broken saves, saves that don’t match, etc. etc. to see that ROMs are preserved and such.

Algospeak

Going back to the RTC, I remade the function that adds a number of seconds to the internal RTC. What I was doing before was calling a function that ticked by ticks with an amount of ticks equal to 1 second FOR EACH SECOND. That’s often hundreds of thousands or millions of function calls, with O(n) time complexity.
I was pretty easily able to swap it for an O(1) modulus thingy.

Switchie-Shwoo

Going back to ROM preservation, I recently realised that it was loading in new timestamp data before checking save validity, which could end up being problematic. I just swapped the order of those two and the problem was solved, though, as I said before, this needs to be test-enforced.

That’s it for now folks! See y’all next time! :3-blahaj-spinning:

0
25

Comments 0

No comments yet. Be the first!