Fixed bug in StatePressed, added .gitignore