mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2024-12-29 00:05:50 +00:00
Avoid sending an action multiple times in a row
This commit is contained in:
parent
9285ce49bd
commit
b320739684
1 changed files with 2 additions and 1 deletions
|
@ -127,7 +127,8 @@ void ActionMapper::addAction (int actionID, int k)
|
|||
|
||||
if (ad)
|
||||
{
|
||||
ad->buttonList.push_back(k);
|
||||
if(std::find(ad->buttonList.begin(), ad->buttonList.end(), k) == ad->buttonList.end())
|
||||
ad->buttonList.push_back(k);
|
||||
keyDownMap[k] = core->getKeyState(k);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue