make player able to attack

including several bug fixes