diff options
Diffstat (limited to '')
-rw-r--r-- | Game/Code/Classes/UDraw.pas | 64 | ||||
-rw-r--r-- | Game/Code/Classes/UMusic.pas | 1 |
2 files changed, 61 insertions, 4 deletions
diff --git a/Game/Code/Classes/UDraw.pas b/Game/Code/Classes/UDraw.pas index 5b0a284c..d55448ad 100644 --- a/Game/Code/Classes/UDraw.pas +++ b/Game/Code/Classes/UDraw.pas @@ -30,6 +30,9 @@ procedure SingDrawLineBonus( const X, Y: Single; Color: TRGB; Alpha: Single; Tex //Draw Editor NoteLines
procedure EditDrawCzesc(Left, Top, Right: real; NrCzesci: integer; Space: integer);
+//Draw Volume Bar
+procedure DrawVolumeBar(x, y, w, h: Real; Volume: Integer);
+
type
TRecR = record
@@ -1457,8 +1460,6 @@ var R: Real;
G: Real;
B: Real;
- A: cardinal;
- I: Integer;
begin;
@@ -1535,7 +1536,7 @@ end; //PhrasenBonus - Line Bonus Mod
procedure SingDrawLineBonus( const X, Y: Single; Color: TRGB; Alpha: Single; Text: string; Age: Integer);
var
-Length, X2: Real; //Length of Text
+Length: Real; //Length of Text
Size: Integer; //Size of Popup
begin
if Alpha <> 0 then
@@ -1711,5 +1712,62 @@ begin glcolor4f(1,1,1,1);
end;
+procedure DrawVolumeBar(x, y, w, h: Real; Volume: Integer);
+const
+ step = 5;
+
+var
+ txt: PChar;
+ str: string;
+ I: integer;
+ num: integer;
+
+begin
+ num := round(100/step);
+
+ for I := 1 to num do
+ begin
+ if (I<=round(Volume/step)) then
+ begin
+ glColor4f(0.0, 0.8, 0.0, 0.8);
+ glEnable(GL_BLEND);
+ glbegin(gl_quads); + glVertex2f(x+(I-1)*(w/num), y); + glVertex2f(x+(I-1)*(w/num), y+h); + glVertex2f(x+(I)*(w/num)-2, y+h); + glVertex2f(x+(I)*(w/num)-2, y); + glEnd;
+ glDisable(GL_BLEND);
+ end else
+ begin
+ glColor4f(0.7, 0.7, 0.7, 0.6);
+ glEnable(GL_BLEND);
+ glbegin(gl_quads); + glVertex2f(x+(I-1)*(w/num), y); + glVertex2f(x+(I-1)*(w/num), y+h); + glVertex2f(x+(I)*(w/num)-2, y+h); + glVertex2f(x+(I)*(w/num)-2, y); + glEnd;
+ glDisable(GL_BLEND);
+ end;
+ end;
+
+ {
+ //print Text
+ str := IntToStr(MP3Volume)+ '%';
+
+ glColor4f(1, 1, 1, 1);
+
+ h := 8;
+ SetFontStyle(1); + SetFontItalic(false); + SetFontSize(h); + w := glTextWidth(PChar(str)); + + SetFontPos (x+2, y+2); + txt := Addr(str[1]); + glPrint(txt); }
+end;
+
end.
diff --git a/Game/Code/Classes/UMusic.pas b/Game/Code/Classes/UMusic.pas index 33e182e3..942c8c81 100644 --- a/Game/Code/Classes/UMusic.pas +++ b/Game/Code/Classes/UMusic.pas @@ -521,7 +521,6 @@ procedure TMusic.Play; begin
if Loaded then begin
// MediaPlayer.Play;
- DSP_VocalRemover:=0;
if Loop then BASS_ChannelPlay(Bass, True); // start from beginning... actually bass itself does not loop, nor does this TMusic Class
BASS_ChannelPlay(Bass, False); // for setting position before playing
end;
|