Sorry for vague description. So when I press keyboard button, mouse button state is always false. If I press mouse button, and then keyboard button, both are true and work normally. Also, if I press keyboard button, then release it, and right after releasing the button press mouse button, mouse button doesn't trigger until around 1sec has passed from releasing keyboard button.
Here is the most minimal code, that will reproduce the problem:
#include <iostream>
#include <SFML/Window/Mouse.hpp>
#include <SFML/Window/Keyboard.hpp>
int main()
{
while (true)
{
if (sf::Keyboard::isKeyPressed(sf::Keyboard::W)){
std::cout <<"KB\n";
}
if(sf::Mouse::isButtonPressed(sf::Mouse::Left)){
std::cout << "MB\n";
}
}
return 0;
}
In the code, keyboard button w and LMB are used.