fix random bug with walls