Confused about Tetris UI

So I have finally managed to get mostly everything in the project working, or at least everything that should relate to the UI, and was hyped to finally be able to do some hands on testing on stuff like piece movement, but when I started the UI, it became quickly apparent that something is not working.

The game does seem to play in the background, but it stays at this view:


Every now and again the preview for the next piece changes, faster so if I hold the down key, and eventually I reach the game over screen, but I don’t actually get to see the game, no matter what I do.

In previous projects I had UI issues, too, but in those projects I had no reason to beliefe that the mistake was on my end, and the eval tests confirmed my assumptions that the UI itself was bugged, but with this project having us implement stuff like the gameObservers I am unsure of if this time it is an issue I should take seriously.

tl;dr: UI not working properly, want confirmation that this is an issue with my code, and, if that is supposed to be public knowledge that I missed, information on what parts of the code the UI needs to display the game properly.

Do you actually invoke the observer methods in your implementation of TetrisGame? (e.g. piecePositionChanged or pieceLanded)

Also, do you do anything in your addObserver method in your implementation of TetrisGame?

I invoke the observer methodes whenever applicable, and I see no reason why addObserver should not work the way I implemented it.

edit: I guess it could be that there is a situation where we are supposed to inform observers but I don’t. I reread the pdf, and it occured to me that some of the phrasings could be interpreted in different ways. For example it is unclear whether we’re supposed to be informing the observers via picePositionChanged() when we place the very first piece. Either way, the actual moveDown() etc. functions inform their observers, so I feel like if the UI changes whenever it is informed that something happened it should work. Especially since it does update whenever nextPiece changes or gameOver happens.

Can you please tell us where the problems were, so we can improve the UI for future iterations of this course?

Regarding this GUI problem:
The UI expects the board variable of the game to be always the same variable that mutates.
When overriding it with a new variable, the GUI loses its connection to the board.

Thanks, that must be the reason, I do change the board!

When it comes to my issues with past UIs, 2048 UI sometimes refused to open, and the wordle UI wasn’t always responsive.

Do you remember in what regard it was unresponsive?

Went back and tested what was going wrong, because in all honesty I didn’t remember all too well, and it seems I got the issues mixed up:

The 2048 UI does not respond to inputs at all, and the wordle UI sometimes crashes when trying to start up a round. I am using the UIs on the VM in case that matters.

I dont know whether it is relevant but; I move the ui window from the bar or change its resolution then it seems to be working while I am moving it.