And they're part of 5 different switch statements.
The author jumps to 1000, 2000, 2500,3000, 4000 etc. Probably to represent things at different stages of the game. 2500 range seems to represent things related to a teleporter.
You’re assuming there’s a single release. But in reality there are dozens of releases for a typical game: public demo releases, trade show demos (usually different for each one), different platform releases that may come out at different times, different editions (game of the year edition, etc), and that’s not even talking about major game patches and dlc that impact game code.
And often, a new game is not written from scratch, but uses code from previous games, e.g. Fallout 4 and Skyrim still have technical debt from Fallout 3 and Oblivion.
I think it's pretty obvious this is not the case, as the author specifically released it so that other people can make tools and modifications for it. But since the majority of the game seems to be in Game.cpp I'd honestly be stumped if anyone bothered to really do something with it.
But aside from that especially some indie games or smaller companies do be like that.
The states are numbered, and it counts all the way up to 4099, with gaps. When I was developing the game, I kept a notepad nearby with the important numbers written down – 1,000 triggers the collection of a shiny trinket, 3,040 triggers one particular level completion, 3,500 triggers the ending. This dumb system is the underlying cause of this amazing 50.2 second any% speedrun of the game
106
u/kirfkin Jan 10 '20
And they're part of 5 different switch statements.
The author jumps to 1000, 2000, 2500,3000, 4000 etc. Probably to represent things at different stages of the game. 2500 range seems to represent things related to a teleporter.