From 6eb777fe362d77189425c2ae137bedab0af5ee5f Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Sun, 28 Feb 2016 21:42:13 -0500 Subject: TITANIC: Added a lot of class definitions Let's be honest here, it's a s**t-load of class definitions --- engines/titanic/sound/auto_sound_player.cpp | 42 +++++++++++++++ engines/titanic/sound/auto_sound_player.h | 63 ++++++++++++++++++++++ engines/titanic/sound/background_sound_maker.cpp | 39 ++++++++++++++ engines/titanic/sound/background_sound_maker.h | 54 +++++++++++++++++++ engines/titanic/sound/music_player.cpp | 37 +++++++++++++ engines/titanic/sound/music_player.h | 58 ++++++++++++++++++++ engines/titanic/sound/titania_speech.cpp | 43 +++++++++++++++ engines/titanic/sound/titania_speech.h | 54 +++++++++++++++++++ .../titanic/sound/trigger_auto_music_player.cpp | 37 +++++++++++++ engines/titanic/sound/trigger_auto_music_player.h | 50 +++++++++++++++++ 10 files changed, 477 insertions(+) create mode 100644 engines/titanic/sound/auto_sound_player.cpp create mode 100644 engines/titanic/sound/auto_sound_player.h create mode 100644 engines/titanic/sound/background_sound_maker.cpp create mode 100644 engines/titanic/sound/background_sound_maker.h create mode 100644 engines/titanic/sound/music_player.cpp create mode 100644 engines/titanic/sound/music_player.h create mode 100644 engines/titanic/sound/titania_speech.cpp create mode 100644 engines/titanic/sound/titania_speech.h create mode 100644 engines/titanic/sound/trigger_auto_music_player.cpp create mode 100644 engines/titanic/sound/trigger_auto_music_player.h (limited to 'engines/titanic/sound') diff --git a/engines/titanic/sound/auto_sound_player.cpp b/engines/titanic/sound/auto_sound_player.cpp new file mode 100644 index 0000000000..619c36298e --- /dev/null +++ b/engines/titanic/sound/auto_sound_player.cpp @@ -0,0 +1,42 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#include "titanic/sound/auto_sound_player.h" + +namespace Titanic { + +CAutoSoundPlayer::CAutoSoundPlayer() : CGameObject(), + _fieldC8(0), _fieldCC(70), _fieldD0(0), _fieldD4(0), _fieldD8(-1), + _fieldDC(0), _fieldE0(-1), _fieldE4(0), _fieldE8(0) { +} + +void CAutoSoundPlayer::save(SimpleFile *file, int indent) const { + file->writeNumberLine(1, indent); + CGameObject::save(file, indent); +} + +void CAutoSoundPlayer::load(SimpleFile *file) { + file->readNumber(); + CGameObject::load(file); +} + +} // End of namespace Titanic diff --git a/engines/titanic/sound/auto_sound_player.h b/engines/titanic/sound/auto_sound_player.h new file mode 100644 index 0000000000..07ac0acd2e --- /dev/null +++ b/engines/titanic/sound/auto_sound_player.h @@ -0,0 +1,63 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#ifndef TITANIC_AUTO_SOUND_PLAYER_H +#define TITANIC_AUTO_SOUND_PLAYER_H + +#include "titanic/core/game_object.h" + +namespace Titanic { + +class CAutoSoundPlayer : public CGameObject { +public: + CString _string1; + int _fieldC8; + int _fieldCC; + int _fieldD0; + int _fieldD4; + int _fieldD8; + int _fieldDC; + int _fieldE0; + int _fieldE4; + int _fieldE8; +public: + CAutoSoundPlayer(); + + /** + * Return the class name + */ + virtual const char *getClassName() const { return "CAutoSoundPlayer"; } + + /** + * Save the data for the class to file + */ + virtual void save(SimpleFile *file, int indent) const; + + /** + * Load the data for the class from file + */ + virtual void load(SimpleFile *file); +}; + +} // End of namespace Titanic + +#endif /* TITANIC_AUTO_SOUND_PLAYER_H */ diff --git a/engines/titanic/sound/background_sound_maker.cpp b/engines/titanic/sound/background_sound_maker.cpp new file mode 100644 index 0000000000..111e641054 --- /dev/null +++ b/engines/titanic/sound/background_sound_maker.cpp @@ -0,0 +1,39 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#include "titanic/sound/background_sound_maker.h" + +namespace Titanic { + +void CBackgroundSoundMaker::save(SimpleFile *file, int indent) const { + file->writeNumberLine(1, indent); + file->writeNumberLine(_value, indent); + CGameObject::save(file, indent); +} + +void CBackgroundSoundMaker::load(SimpleFile *file) { + file->readNumber(); + _value = file->readNumber(); + CGameObject::load(file); +} + +} // End of namespace Titanic diff --git a/engines/titanic/sound/background_sound_maker.h b/engines/titanic/sound/background_sound_maker.h new file mode 100644 index 0000000000..5a234ae048 --- /dev/null +++ b/engines/titanic/sound/background_sound_maker.h @@ -0,0 +1,54 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#ifndef TITANIC_BACKGROUND_SOUND_MAKER_H +#define TITANIC_BACKGROUND_SOUND_MAKER_H + +#include "titanic/core/game_object.h" + +namespace Titanic { + +class CBackgroundSoundMaker : public CGameObject { +public: + int _value; +public: + CBackgroundSoundMaker() : CGameObject(), _value(0) {} + + /** + * Return the class name + */ + virtual const char *getClassName() const { return "CBackgroundSoundMaker"; } + + /** + * Save the data for the class to file + */ + virtual void save(SimpleFile *file, int indent) const; + + /** + * Load the data for the class from file + */ + virtual void load(SimpleFile *file); +}; + +} // End of namespace Titanic + +#endif /* TITANIC_BACKGROUND_SOUND_MAKER_H */ diff --git a/engines/titanic/sound/music_player.cpp b/engines/titanic/sound/music_player.cpp new file mode 100644 index 0000000000..39e97ed10e --- /dev/null +++ b/engines/titanic/sound/music_player.cpp @@ -0,0 +1,37 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#include "titanic/sound/music_player.h" + +namespace Titanic { + +void CMusicPlayer::save(SimpleFile *file, int indent) const { + file->writeNumberLine(1, indent); + CGameObject::save(file, indent); +} + +void CMusicPlayer::load(SimpleFile *file) { + file->readNumber(); + CGameObject::load(file); +} + +} // End of namespace Titanic diff --git a/engines/titanic/sound/music_player.h b/engines/titanic/sound/music_player.h new file mode 100644 index 0000000000..19539c89f7 --- /dev/null +++ b/engines/titanic/sound/music_player.h @@ -0,0 +1,58 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#ifndef TITANIC_MUSIC_PLAYER_H +#define TITANIC_MUSIC_PLAYER_H + +#include "titanic/core/game_object.h" + +namespace Titanic { + +class CMusicPlayer : public CGameObject { +public: + int _fieldBC; + CString _string1; + int _fieldCC; + int _fieldD0; +public: + CMusicPlayer() : CGameObject(), + _fieldBC(0), _fieldCC(0), _fieldD0(100) {} + + /** + * Return the class name + */ + virtual const char *getClassName() const { return "CMusicPlayer"; } + + /** + * Save the data for the class to file + */ + virtual void save(SimpleFile *file, int indent) const; + + /** + * Load the data for the class from file + */ + virtual void load(SimpleFile *file); +}; + +} // End of namespace Titanic + +#endif /* TITANIC_MUSIC_PLAYER_H */ diff --git a/engines/titanic/sound/titania_speech.cpp b/engines/titanic/sound/titania_speech.cpp new file mode 100644 index 0000000000..fac166901f --- /dev/null +++ b/engines/titanic/sound/titania_speech.cpp @@ -0,0 +1,43 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#include "titanic/sound/titania_speech.h" + +namespace Titanic { + +void CTitaniaSpeech::save(SimpleFile *file, int indent) const { + file->writeNumberLine(1, indent); + file->writeNumberLine(_value1, indent); + file->writeNumberLine(_value2, indent); + + CGameObject::save(file, indent); +} + +void CTitaniaSpeech::load(SimpleFile *file) { + file->readNumber(); + _value1 = file->readNumber(); + _value2 = file->readNumber(); + + CGameObject::load(file); +} + +} // End of namespace Titanic diff --git a/engines/titanic/sound/titania_speech.h b/engines/titanic/sound/titania_speech.h new file mode 100644 index 0000000000..a81544a903 --- /dev/null +++ b/engines/titanic/sound/titania_speech.h @@ -0,0 +1,54 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#ifndef TITANIC_TITANIA_SPEECH_H +#define TITANIC_TITANIA_SPEECH_H + +#include "titanic/core/game_object.h" + +namespace Titanic { + +class CTitaniaSpeech : public CGameObject { +public: + int _value1, _value2; +public: + CTitaniaSpeech() : CGameObject(), _value1(1), _value2(0) {} + + /** + * Return the class name + */ + virtual const char *getClassName() const { return "CTitaniaSpeech"; } + + /** + * Save the data for the class to file + */ + virtual void save(SimpleFile *file, int indent) const; + + /** + * Load the data for the class from file + */ + virtual void load(SimpleFile *file); +}; + +} // End of namespace Titanic + +#endif /* TITANIC_TITANIA_SPEECH_H */ diff --git a/engines/titanic/sound/trigger_auto_music_player.cpp b/engines/titanic/sound/trigger_auto_music_player.cpp new file mode 100644 index 0000000000..adcc18c591 --- /dev/null +++ b/engines/titanic/sound/trigger_auto_music_player.cpp @@ -0,0 +1,37 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#include "titanic/sound/trigger_auto_music_player.h" + +namespace Titanic { + +void CTriggerAutoMusicPlayer::save(SimpleFile *file, int indent) const { + file->writeNumberLine(1, indent); + CGameObject::save(file, indent); +} + +void CTriggerAutoMusicPlayer::load(SimpleFile *file) { + file->readNumber(); + CGameObject::load(file); +} + +} // End of namespace Titanic diff --git a/engines/titanic/sound/trigger_auto_music_player.h b/engines/titanic/sound/trigger_auto_music_player.h new file mode 100644 index 0000000000..9cc71ee0f0 --- /dev/null +++ b/engines/titanic/sound/trigger_auto_music_player.h @@ -0,0 +1,50 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program 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; either version 2 + * of the License, or (at your option) any later version. + * + * This program 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. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +#ifndef TITANIC_AUTO_MUSIC_PLAYER_H +#define TITANIC_AUTO_MUSIC_PLAYER_H + +#include "titanic/core/game_object.h" + +namespace Titanic { + +class CTriggerAutoMusicPlayer : public CGameObject { +public: + /** + * Return the class name + */ + virtual const char *getClassName() const { return "CTriggerAutoMusicPlayer"; } + + /** + * Save the data for the class to file + */ + virtual void save(SimpleFile *file, int indent) const; + + /** + * Load the data for the class from file + */ + virtual void load(SimpleFile *file); +}; + +} // End of namespace Titanic + +#endif /* TITANIC_AUTO_MUSIC_PLAYER_H */ -- cgit v1.2.3