Urg filtering

Just one bug left I think, but otherwise this works.

I feel bad selling my soul to the devil for this.