Make support for sided gates

#1881
Nice catch ;-)