fix handle drawing to properly be a square now

This commit is contained in:
Rusty Striker 2023-07-06 13:10:45 +03:00
parent 75cc8da7ee
commit 901b509991

9
ui.c
View file

@ -72,11 +72,10 @@ void ui_slider_draw(ui_slider* s) {
glVertex3f(pos.x, pos.y + ext.y, pos.z); glVertex3f(pos.x, pos.y + ext.y, pos.z);
// Draw slider button thing // Draw slider button thing
glColor3f(1.0, 1.0, 1.0); glColor3f(1.0, 1.0, 1.0);
glVertex3f(slider.x - ext.z, slider.y - ext.y, 0.0); glVertex3f(slider.x - ext.z, slider.y - ext.z, 0.0);
glVertex3f(slider.x + ext.z, slider.y - ext.y, 0.0); glVertex3f(slider.x + ext.z, slider.y - ext.z, 0.0);
glVertex3f(slider.x + ext.z, slider.y + ext.y, 0.0); glVertex3f(slider.x + ext.z, slider.y + ext.z, 0.0);
glVertex3f(slider.x - ext.z, slider.y + ext.y, 0.0); glVertex3f(slider.x - ext.z, slider.y + ext.z, 0.0);
glEnd(); glEnd();
} }