Programmatic 2D maps

Hey guys,

I am creating a 2D platform game which uses a variety of different ‘platform’ / ‘tile’ types. I am drawing each time programmatically using copyPixels but I’ve come to a bit of problem when creating tiles that arn’t simple squares (or rects.) Lets say I wanted to create a sloping tile, or perhaps even a curved tile. How would I go about doing this? Taking into consideration collisions, I have absolutely no idea how I would create a sloped tile.

I have absolutely no idea how I go about rendering the map using copyPixels to creating a set of collidable tiles / coordinates for my player. Any help would be appreciated!

Thanks.