But then the next unit would use them, we dont want that. So I always clear the que at the end of a units turn.
Yep, discarding input is okay when you're doing it deliberately. But by that time you already know what is what.
Nuance is, clearing input just to make the whole thing work may indicate a flaw in control flow. Or may not, but my experience says chances are high.
A simple (maybe too simple, but obvious) example would be accidentally doing things in draw-read-refresh order. It displays the scene one frame late and does introduce a visible lag.
Is there a way to write to the states?
No, those states are intended to be, well, just the current state of things. Modifying is done through terminal_set -- or a separate function if the action is frequent and important enough (e. g. terminal_layer).
Setting mouse position is a questionable action. For once, I'd never do that in my own program because as a user I'd really hate for mouse to jump on screen out of my control. I might add the functionality just for completeness sake but it has quite a low priority. Unless you provide a compelling use case =).