Object has type qualifiers that are not compatible with the member function
问题 My class Game has a member EntityManager entityManager_ . The class EntityManager has a private member Player player_ and the public getter function Player &EntityManager::getPlayer() which returns player_ . The class Player has for example the functions void startMoving() and sf::Vector2f getPosition() const . Now, I can without problems call entityManager_.getPlayer().startMoving(); from within my Game class, but when I try for example the following code to get the player's position: sf: