Feature: Purchase land multiple tiles at a time
[openttd-github.git] / src / music / os2_m.h
bloba60f5bbfc7dadb5647bad1cd833d3ac07d995f13
1 /*
2 * This file is part of OpenTTD.
3 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
6 */
8 /** @file os2_m.h Base for OS2 music playback. */
10 #ifndef MUSIC_OS2_H
11 #define MUSIC_OS2_H
13 #include "music_driver.hpp"
15 /** OS/2's music player. */
16 class MusicDriver_OS2 : public MusicDriver {
17 public:
18 const char *Start(const StringList &param) override;
20 void Stop() override;
22 void PlaySong(const MusicSongInfo &song) override;
24 void StopSong() override;
26 bool IsSongPlaying() override;
28 void SetVolume(byte vol) override;
29 const char *GetName() const override { return "os2"; }
32 /** Factory for OS/2's music player. */
33 class FMusicDriver_OS2 : public DriverFactoryBase {
34 public:
35 FMusicDriver_OS2() : DriverFactoryBase(Driver::DT_MUSIC, 10, "os2", "OS/2 Music Driver") {}
36 Driver *CreateInstance() const override { return new MusicDriver_OS2(); }
39 #endif /* MUSIC_OS2_H */