Fixed keypress conflict

Adding the lastKey update to the Key Up conditional was the solution -
before there was no update and so the Key Up branch was overwriting the
keyPressed status of the wrong keys (i.e. if left was pressed, then
right, and left was released, it would mark right as having been
released instead since lastKey was still right (the left key up event
triggered this).