void thumb() // creates the thumb { int bob = -40; double radian = double(bob) / 180.0 * pi; glPushMatrix(); glTranslatef(cos(radian) * 2.5, sin(radian) * 2.5, 0); glutSolidSphere(joint[4][0], F, F); glPushMatrix(); glRotatef(90, 0, 1, 0); glRotatef(angle[4][0]-90, 1, 0, 0); // move away from hand glRotatef(-spread[3], 0, 1, 0); // move out of palm plane gluCylinder(gluNewQuadric(), joint[4][0], joint[4][1], dist[4][0], F, F); glTranslatef(0, 0, dist[4][0]); gluSphere(gluNewQuadric(), joint[4][1], F, F); glPushMatrix(); glRotatef(-1*angle[4][1], 1, 0, 0); gluCylinder(gluNewQuadric(), joint[4][1], joint[4][2], dist[4][1], F, F); glTranslatef(0, 0, dist[4][1]); gluSphere(gluNewQuadric(), joint[4][2], F, F); glPushMatrix(); glRotatef(-1*angle[4][2], 1, 0, 0); gluCylinder(gluNewQuadric(), joint[4][2], joint[4][3], dist[4][2], F, F); glTranslatef(0, 0, dist[4][2]); gluSphere(gluNewQuadric(), joint[4][3], F, F); glPopMatrix(); glPopMatrix(); glPopMatrix(); glPopMatrix(); }The thumb was a very confusing thing to make. The thumb is just som much more mobile and modifiable than the fingers that it was a real challenge. bob, Which wil be replaced later with spread as it becomes a capability, determines the angle of rotation away from the hand of the thumb. Spread will be used in the fingers to determine how far apart they are spread from each other. Other than that, the thumb is drawn very similarly to the fingers, just a bit broader and not in a srtraight line up from the hand. Instead, it is drawn away from the hand, and looks very peculiar without the flap of skin connecting it to the palm like in a real human hand. Everything else can be correlated to the finger function.