How can I store a reference to the device I am subscribing to?

At first, I used @Incredulous_Hulk way but ended up pivoting to something more alike this approach.

I created a new class and subscribed to a function in that class. In the construction of the new class, it received the color-changing tile class that it’s subscribed to, and any other expressions from the original class needed to run the magic numbers.

Huge win. Thank everybody, I’m marking this as the solution because it solved my problem in the best way.

2 Likes