diff options
author | Wohlstand <admin@wohlnet.ru> | 2017-11-09 02:57:59 +0300 |
---|---|---|
committer | Wohlstand <admin@wohlnet.ru> | 2017-11-09 02:57:59 +0300 |
commit | 265ae7a37afb087b9e16f4ddd0eaef28a21826de (patch) | |
tree | e852b2b0189e48bc2a4f6c9c409c0d11278b0203 /utils | |
parent | 4e241bdbd6e992c981632710d68adef6bc836d4a (diff) | |
download | libADLMIDI-265ae7a37afb087b9e16f4ddd0eaef28a21826de.tar.gz libADLMIDI-265ae7a37afb087b9e16f4ddd0eaef28a21826de.tar.bz2 libADLMIDI-265ae7a37afb087b9e16f4ddd0eaef28a21826de.zip |
Don't inirialize Tetris statically in UserInterface in classic ADLMIDI tool
Diffstat (limited to 'utils')
-rw-r--r-- | utils/adlmidi-2/midiplay.cc | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/utils/adlmidi-2/midiplay.cc b/utils/adlmidi-2/midiplay.cc index 6c3a4b6..bd0d586 100644 --- a/utils/adlmidi-2/midiplay.cc +++ b/utils/adlmidi-2/midiplay.cc @@ -249,6 +249,10 @@ static const char MIDIsymbols[256 + 1] = static class UserInterface { +#ifdef SUPPORT_PUZZLE_GAME + ADLMIDI_PuzzleGame::TetrisAI player; + ADLMIDI_PuzzleGame::TetrisAI computer; +#endif public: static constexpr unsigned NColumns = 1216 / 20; #ifdef SUPPORT_VIDEO_OUTPUT @@ -276,7 +280,12 @@ public: bool cursor_visible; char stderr_buffer[256]; public: - UserInterface(): x(0), y(0), color(-1), txtline(0), + UserInterface(): + #ifdef SUPPORT_PUZZLE_GAME + player(2), + computer(31), + #endif + x(0), y(0), color(-1), txtline(0), maxy(0), cursor_visible(true) { GuessInitialWindowHeight(); |