aboutsummaryrefslogtreecommitdiffstats
path: root/src/screens/UScreenMain.pas
diff options
context:
space:
mode:
authorbasisbit <basisbit@b956fd51-792f-4845-bead-9b4dfca2ff2c>2015-08-28 01:45:23 +0000
committerbasisbit <basisbit@b956fd51-792f-4845-bead-9b4dfca2ff2c>2015-08-28 01:45:23 +0000
commitebac563f0f8f4fba120cee79e8e6a7973e394677 (patch)
tree66c330cf4c5dbe0d3b618d2eb1ae25f0dff338c7 /src/screens/UScreenMain.pas
parent5eadb894728d5a285e0272c007bdeeb0d5bdf59d (diff)
downloadusdx-ebac563f0f8f4fba120cee79e8e6a7973e394677.tar.gz
usdx-ebac563f0f8f4fba120cee79e8e6a7973e394677.tar.xz
usdx-ebac563f0f8f4fba120cee79e8e6a7973e394677.zip
* first usable implementation of the JukeBox mode, work in progress - you can start it by pressing "j" in the main menu
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@3128 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'src/screens/UScreenMain.pas')
-rw-r--r--src/screens/UScreenMain.pas23
1 files changed, 22 insertions, 1 deletions
diff --git a/src/screens/UScreenMain.pas b/src/screens/UScreenMain.pas
index aa313cf6..b5e3a8bb 100644
--- a/src/screens/UScreenMain.pas
+++ b/src/screens/UScreenMain.pas
@@ -85,9 +85,9 @@ function TScreenMain.ParseInput(PressedKey: Cardinal; CharCode: UCS4Char;
PressedDown: boolean): boolean;
var
SDL_ModState: word;
+ I: integer;
begin
Result := true;
-
{ reset user interaction timer }
UserInteractionTicks := SDL_GetTicks;
@@ -126,6 +126,27 @@ begin
FadeTo(@ScreenEdit, SoundLib.Start);
Exit;
end;
+
+ Ord('J'): begin
+ //ScreenSong.Mode := smPartyJukebox;
+ AudioPlayback.PlaySound(SoundLib.Start);
+
+ SetLength(ScreenJukebox.JukeboxSongsList, 0);
+ SetLength(ScreenJukebox.JukeboxVisibleSongs, 0);
+
+ for I := 0 to High(CatSongs.Song) do
+ begin
+ if not (CatSongs.Song[I].Main) then
+ ScreenJukebox.AddSongToJukeboxList(I);
+ end;
+ ScreenJukebox.ActualInteraction := 0;
+ ScreenJukebox.CurrentSongList := 0;
+ ScreenJukebox.ListMin := 0;
+ ScreenJukebox.Interaction := 0;
+ ScreenJukebox.CurrentSongID := ScreenJukebox.JukeboxVisibleSongs[ScreenJukebox.CurrentSongList];
+
+ FadeTo(@ScreenJukebox);
+ end;
end;
// check special keys