totally agreed. That said, from my perspective on pedagogy, this is a great starting point for a lot of important concepts. The fact that global variables are both a) the most close-at-hand solution that's easiest to teach and learn and b) totally inadequate leads to a situation where students get to improve their engineering practices iteratively as they learn new concepts rather than having to onboard complex mental models before they get to write any code (this is what Java is so much harder to teach and learn than, e.g., Lua and Love2D).
I guess tl;dr, imo this common framework design decision has a lot of pedagogical benefits even if it doesn't really satisfy the needs of game designers and other similar programmers. It's interesting to compare this pedagogical approach to the approaches implied by other tools like uxn, forth, etc.