Fixed terrain rendering bug