Perlenspiel 3.1.7

Merged the 3.1.7 changes into master.