I found a way (although this is very slow, so i still am looking for a quicker way).
The pink line are all little sprites 32 x 32
They move from left to right and check if overlapping the dark grey sprites.
If so, then the tilemap erases the tile at the position of the pink sprites.
It works, but i rather use a quick method so players don't have to wait as long when a new level is being generated.