Handling the player's input
Add some more declarations to the GameInputHandler.h
file so that your code matches what follows. I have highlighted the new code to add:
#pragma once #include "InputHandler.h" #include "PlayerUpdateComponent.h" #include "TransformComponent.h" class GameScreen; class GameInputHandler : public InputHandler { private: Â Â Â Â shared_ptr<PlayerUpdateComponent> m_PUC; Â Â Â Â shared_ptr<TransformComponent> m_PTC; Â Â Â Â bool mBButtonPressed = false; public: Â Â Â Â void initialize(); Â Â Â Â void handleGamepad() override; Â Â Â Â void handleKeyPressed(Event& event, Â Â Â Â Â Â Â Â RenderWindow& window) override; Â Â Â Â void handleKeyReleased(Event& event, Â Â Â Â Â Â Â Â RenderWindow& window) override; Â Â &...