Closed ndouglas closed 5 years ago
Movement checks require that the map is passed to input handling function.
... and the map console, and the root console.
This will not scale up. Eventually we'd need to pass in every object in the game.
Rather, keys should be translated into commands. Commands should, elsewhere, go through some process like this:
So, ultimately, the input handler should be responsible only for transforming input into commands. All else should be handled elsewhere.
Movement checks require that the map is passed to input handling function.
... and the map console, and the root console.
This will not scale up. Eventually we'd need to pass in every object in the game.
Rather, keys should be translated into commands. Commands should, elsewhere, go through some process like this:
So, ultimately, the input handler should be responsible only for transforming input into commands. All else should be handled elsewhere.