Readded door generation functionality - and perfected it