diff options
author | whiteshark0 <whiteshark0@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-04-10 10:15:14 +0000 |
---|---|---|
committer | whiteshark0 <whiteshark0@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-04-10 10:15:14 +0000 |
commit | d28350b7fe6e1c827e9994d28f7f95cae4ac2db6 (patch) | |
tree | 201b88d0c1430218d8884c89f34094f9b029efad | |
parent | e9a8dafe97dfc4570e08bd8a1054e7f6e91ff8a1 (diff) | |
download | usdx-d28350b7fe6e1c827e9994d28f7f95cae4ac2db6.tar.gz usdx-d28350b7fe6e1c827e9994d28f7f95cae4ac2db6.tar.xz usdx-d28350b7fe6e1c827e9994d28f7f95cae4ac2db6.zip |
Corrected Coverpositions in Style 4
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@75 b956fd51-792f-4845-bead-9b4dfca2ff2c
-rw-r--r-- | Game/Code/Screens/UScreenSong.pas | 24 |
1 files changed, 9 insertions, 15 deletions
diff --git a/Game/Code/Screens/UScreenSong.pas b/Game/Code/Screens/UScreenSong.pas index 2af37dd5..e873d287 100644 --- a/Game/Code/Screens/UScreenSong.pas +++ b/Game/Code/Screens/UScreenSong.pas @@ -945,11 +945,12 @@ begin Wsp := 2 * pi * (CatSongs.VisibleIndex(B) - SongCurrent) / VS {CatSongs.VisibleSongs};// 0.5.0 (II): takes another 16ms
- Z := (1 + cos(Wsp)) / 2 - 0.2;
+ Z := (1 + cos(Wsp)) / 2;
Z2 := (1 + 2*Z) / 3;
- Button[B].X := Theme.Song.Cover.X + (Theme.Song.Cover.W + 0.185 * Theme.Song.Cover.H * VS * sin(Wsp) - Theme.Song.Cover.X) * Z2; // 0.5.0 (I): 2 times faster by not calling CatSongs.VisibleSongs
- Button[B].Z := Z;
+
+ Button[B].X := Theme.Song.Cover.X + (0.185 * Theme.Song.Cover.H * VS * sin(Wsp)) * Z2 - ((Button[B].H - Theme.Song.Cover.H)/2); // 0.5.0 (I): 2 times faster by not calling CatSongs.VisibleSongs
+ Button[B].Z := Z / 2 + 0.3;
Button[B].W := Theme.Song.Cover.H * Z2;
@@ -1050,16 +1051,6 @@ var VS: integer;
diff: real;
X: Real;
- {function margin (const X, Y, VS: real):real; //Margin of to Buttons
- begin
- Result := Frac(x / y) * y;
- if (X - VS) >= -3 then
- Result := X - VS - Y
- else if (X + 3) >= VS then
- Result := X - VS + Y
- else
- Result := X - Y;
- end; }
begin
VS := CatSongs.VisibleSongs; // cache Visible Songs
{Vars
@@ -1096,9 +1087,12 @@ begin Button[B].W := Button[B].H;
- Diff := (Button[B].H - Theme.Song.Cover.H)/2;;
+ Diff := (Button[B].H - Theme.Song.Cover.H)/2;
+
+
+ X := Sin(Angle);
- Button[B].X := Theme.Song.Cover.X + Theme.Song.Cover.W * Sin(Angle) - Diff;
+ Button[B].X := Theme.Song.Cover.X + Theme.Song.Cover.W * X - Diff;
end
else
|