Rewrote my generateSouvenirs function such that it generates an array of ojects that have (mostly) random color values, and the color of any linear sequence of 9 objects does not share a color property.
Tried adding some logic so that my first 9 objects didn't always have the same sequence of colors. Failed at that, but fixed a bug wherein I was adding n to trials twice.
Added a shuffle function to shuffle my colors array so my object index will no longer start with the same sequence of 10 colors each time. Call the shuffle function in my game reset function.
Added a function that adds matches to the souvenirs array and called the function at the end of the generateObjects function.
Fixed an evil bug wherein my souvenirs array contained more matches than it was supposed to because my generateSouvenirs function wasn't generating 10 unique objects, like it was supposed to.
Deleted unused code.