It’s definitely possible, although what you’re asking for is quite a complex problem. I’ve attached an image of a slightly simplified version of what you’re after just to get you started (‘PlayerStance’ is a enumeration, if you’ve not seen those before).
In this situation, if the player releases (I’m using releases rather than pressed because it’s less ambiguous, but you can obviously change that) the caps lock they’ll change between standing and crouching and then back to standing. If they hold the button, they’ll transition down to prone (from standing this is a two-step process, transitioning through crouching). This isn’t completely what you were after (and it doesn’t handle standing up again), but you shouldn’t need to extend it with anything more than a few booleans (‘were we already in crouch when the caps button was pressed’, stuff like that) and maybe another float.
In my opinion, multiple gates usually gets you into trouble ![]()
