It's easy to write these things off as poor designs in games, and I'm sure some are, but it's also likely that quite a few are creative solutions to solve problems with the provided resources at the time. Those creative solutions probably don't stand the test of time well as new API are created, bug fixes are released, and loopholes that were taken advantage of are closed.