Fixes for datatype size on amd64.
[crack-attack.git] / src / Music.h
bloba2b49477a4cffa548abfa640c363cbca4a2e9c1d
1 /*
2 * Music.h
3 * Miguel Ángel Vilela García - 8/29/03
5 * Copyright (C) 2003 Miguel Ángel Vilela García
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 * Miguel Ángel Vilela García - www.miguev.net
24 #ifndef MUSIC_H
25 #define MUSIC_H
27 #include <stdio.h>
28 #include <stdlib.h>
29 #include <unistd.h>
30 #include <dirent.h>
31 #include <SDL/SDL.h>
32 #include <SDL/SDL_mixer.h>
33 #include <string>
34 #include <vector>
36 #define GC_MUSIC_FILENAME_LENGTH 128
37 #define GC_MUSIC_PRELUDE_TRACK "prelude"
38 #define GC_MUSIC_GAME_TRACK "game"
39 #define GC_MUSIC_GAMEOVER_TRACK "gameover"
40 #define GC_MUSIC_YOUWIN_TRACK "youwin"
42 class Music {
43 public:
44 static void initialize ( );
45 static void play();
46 static void play_prelude();
47 static void play_game();
48 static void play_gameover();
49 static void play_youwin();
50 static void pause();
51 static void resume();
52 static void stop();
53 static void fadeout( int ms );
54 static void cleanup ( );
55 static void load( );
56 private:
57 static void play_track( char *track );
58 static void finished();
61 #endif /* MUSIC_H */