aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorb1indy <b1indy@b956fd51-792f-4845-bead-9b4dfca2ff2c>2007-07-22 14:40:26 +0000
committerb1indy <b1indy@b956fd51-792f-4845-bead-9b4dfca2ff2c>2007-07-22 14:40:26 +0000
commit2785a93305dc8574b9dd7ec909cc8aa71c91ab61 (patch)
tree3e7a3bce0ac82390f26f57ac30c183e5e97dac2b
parent75fd5d6e84319dccc367441704566aa704817699 (diff)
downloadusdx-2785a93305dc8574b9dd7ec909cc8aa71c91ab61.tar.gz
usdx-2785a93305dc8574b9dd7ec909cc8aa71c91ab61.tar.xz
usdx-2785a93305dc8574b9dd7ec909cc8aa71c91ab61.zip
again some fixes in reflection code for buttons and statics
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/branches/1.0x@318 b956fd51-792f-4845-bead-9b4dfca2ff2c
-rw-r--r--Game/Code/Menu/UMenuButton.pas6
-rw-r--r--Game/Code/Menu/UMenuStatic.pas6
2 files changed, 6 insertions, 6 deletions
diff --git a/Game/Code/Menu/UMenuButton.pas b/Game/Code/Menu/UMenuButton.pas
index fde808e2..919a18c9 100644
--- a/Game/Code/Menu/UMenuButton.pas
+++ b/Game/Code/Menu/UMenuButton.pas
@@ -418,7 +418,7 @@ begin
Spacing := Reflectionspacing
else
Spacing := DeSelectReflectionspacing;
-
+
with Texture do
begin
//Bind Tex and GL Attributes
@@ -440,13 +440,13 @@ begin
//Bottom Left
glColor4f(ColR * Int, ColG * Int, ColB * Int, 0);
- glTexCoord2f(TexX1*TexW, {TexY1*TexH*}0.5);
+ glTexCoord2f(TexX1*TexW, TexY1+TexH*0.5);
glVertex3f(x, y+h*scaleH + h*scaleH/2 + Spacing, z);
//Bottom Right
glColor4f(ColR * Int, ColG * Int, ColB * Int, 0);
- glTexCoord2f(TexX2*TexW, {TexY1*TexH*}0.5);
+ glTexCoord2f(TexX2*TexW, TexY1+TexH*0.5);
glVertex3f(x+w*scaleW, y+h*scaleH + h*scaleH/2 + Spacing, z);
//Top Right
diff --git a/Game/Code/Menu/UMenuStatic.pas b/Game/Code/Menu/UMenuStatic.pas
index 2a5e1e93..5f19fbf3 100644
--- a/Game/Code/Menu/UMenuStatic.pas
+++ b/Game/Code/Menu/UMenuStatic.pas
@@ -52,13 +52,13 @@ begin
//Bottom Left
glColor4f(ColR * Int, ColG * Int, ColB * Int, 0);
- glTexCoord2f(TexX1*TexW, 0.5);
+ glTexCoord2f(TexX1*TexW, 0.5*TexH+TexY1);
glVertex3f(x, y+h*scaleH + h*scaleH/2 + Reflectionspacing, z);
//Bottom Right
glColor4f(ColR * Int, ColG * Int, ColB * Int, 0);
- glTexCoord2f(TexX2*TexW, 0.5);
+ glTexCoord2f(TexX2*TexW, 0.5*TexH+TexY1);
glVertex3f(x+w*scaleW, y+h*scaleH + h*scaleH/2 + Reflectionspacing, z);
//Top Right
@@ -68,7 +68,7 @@ begin
glEnd;
glDisable(GL_TEXTURE_2D);
- glDisable(GL_DEPTH_TEST);
+ glDisable(GL_DEPTH_TEST);
glDisable(GL_BLEND);
end;
end;