Fix polygon

A polygon's id needs to be set before it is handed over to its vertices addChild() method.
Add new element 'slopetriangle' to the core