So I'm trying to make a dash by double tapping a key, and my code looks like this:
<img src="http://puu.sh/2MwiB.png" border="0" />
However, it seems to immediately set dash to true, trigger the event that says "if true and if a is pressed" and then set it back to false instantly, setting the dash effect off in the process every time the A key is pressed.