From: Ash Tyndall Date: Fri, 21 Oct 2011 12:04:51 +0000 (+0800) Subject: (no commit message) X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=94605c9ba4cad948d4488cb87cb8134240adf8c2;p=atyndall%2Fcits2231.git --- diff --git a/globals.c b/globals.c index 4f7c69e..278bf89 100644 --- a/globals.c +++ b/globals.c @@ -46,10 +46,7 @@ char *dirDefault2 = "/cslinux/examples/CITS2231/project-files/models-textures"; char dataDir[200]; // Stores the directory name for the meshes and textures. -int moving, startx, starty; - -/* Recursion level for floor drawing */ -int drawFloorRecurse = 8; +int startx, starty; /* Size of floor, from -n to n, floorSize must be divisible by squareSize */ int floorSize = 200; diff --git a/globals.h b/globals.h index 058e32c..c7d62d2 100644 --- a/globals.h +++ b/globals.h @@ -35,10 +35,7 @@ extern char *dirDefault2; // Stores the directory name for the meshes and textures. extern char dataDir[]; -extern int moving, startx, starty; - -/* Recursion level for floor drawing */ -extern int drawFloorRecurse; +extern int startx, starty; /* Size of floor, from -n to n */ extern int floorSize; diff --git a/scene.c b/scene.c index c62831e..ffc138d 100644 --- a/scene.c +++ b/scene.c @@ -285,13 +285,13 @@ void motion(int x, int y) { if ( buttonSelected == GLUT_LEFT_BUTTON ) { // w: rotate, h: zoom zoom += (y - starty); - printf("zoom is %f\n", zoom); } else if ( buttonSelected == GLUT_MIDDLE_BUTTON ) { // w: rotate, h: tilt camAngle += (y - starty); } starty = y; + printf("zoom is %f, y is %f starty is %f\n", zoom, y, starty); startx = x; break;