mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-07-03 06:24:32 +00:00
Correctly distinguish between action sources when evaluating ActionMapper
I'm not quite happy with the hackishness of this change; hope it doesn't incur too much runtime overhead with all these checks...
This commit is contained in:
parent
77e4bfd292
commit
dcf09343b5
8 changed files with 113 additions and 7 deletions
|
@ -251,3 +251,26 @@ std::string ActionSet::insertInputIntoString(const std::string &string)
|
|||
}
|
||||
*/
|
||||
|
||||
bool ActionSet::hasMouse(int actionID) const
|
||||
{
|
||||
for(size_t i = 0; i < inputSet.size(); ++i)
|
||||
if(inputSet[i].hasMouse(actionID))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool ActionSet::hasKey(int actionID) const
|
||||
{
|
||||
for(size_t i = 0; i < inputSet.size(); ++i)
|
||||
if(inputSet[i].hasKey(actionID))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool ActionSet::hasJoy(int actionID) const
|
||||
{
|
||||
for(size_t i = 0; i < inputSet.size(); ++i)
|
||||
if(inputSet[i].hasJoy(actionID))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue