engine: Layers(...) was actually checking bounds based on X dimension instead of Z