Input not registering after a new state is loaded.

13 views
Skip to first unread message

Justin C.

unread,
Mar 6, 2016, 1:16:30 PM3/6/16
to HaxeFlixel
So I've noticed this little bug before, and haven't thought much of it. I'm guessing everyone has to deal with it, but I was wondering if there's a way around this. Anyways, the bug in question is when you load a new PlayState (for example) and you're holding right or something (to make your player move right) it doesn't register at all. I'm not sure what else to say at this point, so uh, yeah

Gama11

unread,
Mar 6, 2016, 1:51:06 PM3/6/16
to HaxeFlixel
That's not a bug, it's the intended behavior - inputs are reset on state switches. Try FlxG.inputs.resetOnStateSwitch = false;

Justin C.

unread,
Mar 6, 2016, 1:52:45 PM3/6/16
to HaxeFlixel
Ah, thanks Gamma ^)^
Reply all
Reply to author
Forward
0 new messages