Made kernel-stuff for arches at corridor entrances

Started creating an image-processing like kernel system that can detect
certain patterns in the level. This will be improved so that it is more
generalised and applicable in many situations.