From 3ee6c1e771f925b8e3f38f2539a2d5a3b4111714 Mon Sep 17 00:00:00 2001 From: Ash Tyndall Date: Fri, 21 Oct 2011 15:49:02 +0800 Subject: [PATCH] --- helper.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/helper.c b/helper.c index 14fbe5a..b13e8f9 100644 --- a/helper.c +++ b/helper.c @@ -210,7 +210,10 @@ int makeSubmenuFromArray( const char *menuEntries[], unsigned int menuEntriesSiz * Draw a floor by looping over the floorSize and squareSize variables */ void drawFloor() { - if ( currentGroundTexture != 0 ) { + if ( currentGroundTexture == 0 ) { + getTexture(1); + glBindTexture(GL_TEXTURE_2D, 1); + } else { getTexture(currentGroundTexture); glBindTexture(GL_TEXTURE_2D, currentGroundTexture); } -- 2.20.1