fix: PlayerInput now normalizes input after un/pause
This commit is contained in:
parent
5d0ae90fbc
commit
10535a675d
2 changed files with 28 additions and 3 deletions
|
|
@ -6,6 +6,7 @@
|
|||
class PlayerInput : public Node {
|
||||
GDCLASS(PlayerInput, Node);
|
||||
static void _bind_methods();
|
||||
void normalize_input();
|
||||
void _notification(int what);
|
||||
virtual void unhandled_input(Ref<InputEvent> const &event) override;
|
||||
|
||||
|
|
@ -18,6 +19,9 @@ public:
|
|||
static String sig_run;
|
||||
static String sig_jump;
|
||||
static String sig_crouch;
|
||||
|
||||
private:
|
||||
bool was_paused{ false };
|
||||
};
|
||||
|
||||
#endif // !PLAYER_INPUT_H
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue