adding changes proposed by Markus Pröll (+point support)