Cleaned up the code a bit, removed untextured mode