ShapeMerger
Introduction
The ShapeMerger can be used to merge shapes together to create one larger shape. This is used by the TileEditor to create level collision.
Code Example
The following code creates two Polygons - one is the shape of a rectangle, the other is a hexagon. The rectangle is offset, then the two shapes are merged into one. Add the following using statement:
Add the following to Initialize after initializing FlatRedBall:
Did this article leave any questions unanswered? Post any question in our forums for a rapid response.
Last updated