MADS: Slight formatting fixes.
This commit is contained in:
parent
57c5656169
commit
9866aba2e4
20 changed files with 52 additions and 37 deletions
|
@ -29,8 +29,9 @@
|
|||
|
||||
namespace MADS {
|
||||
|
||||
Dialog::Dialog(MADSEngine *vm): _vm(vm), _savedSurface(nullptr),
|
||||
_position(Common::Point(-1, -1)), _width(0), _height(0) {
|
||||
Dialog::Dialog(MADSEngine *vm)
|
||||
: _vm(vm), _savedSurface(nullptr), _position(Common::Point(-1, -1)),
|
||||
_width(0), _height(0) {
|
||||
TEXTDIALOG_CONTENT1 = 0XF8;
|
||||
TEXTDIALOG_CONTENT2 = 0XF9;
|
||||
TEXTDIALOG_EDGE = 0XFA;
|
||||
|
@ -136,8 +137,8 @@ void Dialog::drawContent(const Common::Rect &r, int seed, byte color1, byte colo
|
|||
/*------------------------------------------------------------------------*/
|
||||
|
||||
TextDialog::TextDialog(MADSEngine *vm, const Common::String &fontName,
|
||||
const Common::Point &pos, int maxChars):
|
||||
Dialog(vm) {
|
||||
const Common::Point &pos, int maxChars)
|
||||
: Dialog(vm) {
|
||||
_vm = vm;
|
||||
_font = _vm->_font->getFont(fontName);
|
||||
_position = pos;
|
||||
|
@ -363,8 +364,8 @@ void TextDialog::show() {
|
|||
|
||||
/*------------------------------------------------------------------------*/
|
||||
|
||||
MessageDialog::MessageDialog(MADSEngine *vm, int maxChars, ...):
|
||||
TextDialog(vm, FONT_INTERFACE, Common::Point(-1, -1), maxChars) {
|
||||
MessageDialog::MessageDialog(MADSEngine *vm, int maxChars, ...)
|
||||
: TextDialog(vm, FONT_INTERFACE, Common::Point(-1, -1), maxChars) {
|
||||
// Add in passed line list
|
||||
va_list va;
|
||||
va_start(va, maxChars);
|
||||
|
@ -389,7 +390,8 @@ Dialogs *Dialogs::init(MADSEngine *vm) {
|
|||
return new Nebular::DialogsNebular(vm);
|
||||
}
|
||||
|
||||
Dialogs::Dialogs(MADSEngine *vm): _vm(vm) {
|
||||
Dialogs::Dialogs(MADSEngine *vm)
|
||||
: _vm(vm) {
|
||||
_pendingDialog = DIALOG_NONE;
|
||||
}
|
||||
|
||||
|
|
|
@ -35,7 +35,8 @@ namespace MADS {
|
|||
|
||||
namespace Dragonsphere {
|
||||
|
||||
GameDragonsphere::GameDragonsphere(MADSEngine *vm): Game(vm) {
|
||||
GameDragonsphere::GameDragonsphere(MADSEngine *vm)
|
||||
: Game(vm) {
|
||||
_surface = new MSurface(MADS_SCREEN_WIDTH, MADS_SCENE_HEIGHT);
|
||||
_storyMode = STORYMODE_NAUGHTY;
|
||||
}
|
||||
|
|
|
@ -56,8 +56,9 @@ Game *Game::init(MADSEngine *vm) {
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
Game::Game(MADSEngine *vm): _vm(vm), _surface(nullptr), _objects(vm),
|
||||
_scene(vm), _screenObjects(vm), _player(vm) {
|
||||
Game::Game(MADSEngine *vm)
|
||||
: _vm(vm), _surface(nullptr), _objects(vm), _scene(vm),
|
||||
_screenObjects(vm), _player(vm) {
|
||||
_sectionNumber = _priorSectionNumber = 0;
|
||||
_loadGameSlot = -1;
|
||||
_lastSave = -1;
|
||||
|
|
|
@ -42,7 +42,8 @@ void RandomMessages::reset() {
|
|||
}
|
||||
|
||||
|
||||
KernelMessages::KernelMessages(MADSEngine *vm): _vm(vm) {
|
||||
KernelMessages::KernelMessages(MADSEngine *vm)
|
||||
: _vm(vm) {
|
||||
for (int i = 0; i < KERNEL_MESSAGES_SIZE; ++i) {
|
||||
KernelMessage rec;
|
||||
_entries.push_back(rec);
|
||||
|
|
|
@ -35,7 +35,8 @@ namespace MADS {
|
|||
|
||||
namespace Nebular {
|
||||
|
||||
GameNebular::GameNebular(MADSEngine *vm): Game(vm) {
|
||||
GameNebular::GameNebular(MADSEngine *vm)
|
||||
: Game(vm) {
|
||||
_surface = new MSurface(MADS_SCREEN_WIDTH, MADS_SCENE_HEIGHT);
|
||||
_storyMode = STORYMODE_NAUGHTY;
|
||||
_difficulty = DIFFICULTY_EASY;
|
||||
|
|
|
@ -28,7 +28,8 @@ namespace MADS {
|
|||
|
||||
namespace Nebular {
|
||||
|
||||
NebularGlobals::NebularGlobals(): Globals() {
|
||||
NebularGlobals::NebularGlobals()
|
||||
: Globals() {
|
||||
// Initialize lists
|
||||
resize(210);
|
||||
_spriteIndexes.resize(30);
|
||||
|
|
|
@ -934,7 +934,8 @@ const ASound1::CommandPtr ASound1::_commandList[42] = {
|
|||
&ASound1::command40, &ASound1::command41
|
||||
};
|
||||
|
||||
ASound1::ASound1(Audio::Mixer *mixer): ASound(mixer, "asound.001", 0x1520) {
|
||||
ASound1::ASound1(Audio::Mixer *mixer)
|
||||
: ASound(mixer, "asound.001", 0x1520) {
|
||||
_cmd23Toggle = false;
|
||||
|
||||
// Load sound samples
|
||||
|
|
|
@ -336,7 +336,8 @@ void RGBList::copy(RGBList &src) {
|
|||
|
||||
/*------------------------------------------------------------------------*/
|
||||
|
||||
Fader::Fader(MADSEngine *vm): _vm(vm) {
|
||||
Fader::Fader(MADSEngine *vm)
|
||||
: _vm(vm) {
|
||||
_colorFlags[0] = _colorFlags[1] = _colorFlags[2] = true;
|
||||
_colorFlags[3] = false;
|
||||
_colorValues[0] = _colorValues[1] = 0;
|
||||
|
|
|
@ -35,7 +35,8 @@ namespace MADS {
|
|||
|
||||
namespace Phantom {
|
||||
|
||||
GamePhantom::GamePhantom(MADSEngine *vm): Game(vm) {
|
||||
GamePhantom::GamePhantom(MADSEngine *vm)
|
||||
: Game(vm) {
|
||||
_surface = new MSurface(MADS_SCREEN_WIDTH, MADS_SCENE_HEIGHT);
|
||||
_storyMode = STORYMODE_NAUGHTY;
|
||||
}
|
||||
|
|
|
@ -32,7 +32,8 @@ const int Player::_directionListIndexes[32] = {
|
|||
0, 7, 4, 3, 6, 0, 2, 5, 0, 1, 9, 4, 1, 2, 7, 9, 3, 8, 9, 6, 7, 2, 3, 6, 1, 7, 9, 4, 7, 8, 0, 0
|
||||
};
|
||||
|
||||
Player::Player(MADSEngine *vm): _vm(vm) {
|
||||
Player::Player(MADSEngine *vm)
|
||||
: _vm(vm) {
|
||||
_action = nullptr;
|
||||
_facing = FACING_NORTH;
|
||||
_turnToFacing = FACING_NORTH;
|
||||
|
|
|
@ -45,8 +45,9 @@ private:
|
|||
uint32 _size;
|
||||
|
||||
HagEntry() : _offset(0), _size(0) {}
|
||||
HagEntry(Common::String resourceName, uint32 offset, uint32 size):
|
||||
_resourceName(resourceName), _offset(offset), _size(size) {}
|
||||
HagEntry(Common::String resourceName, uint32 offset, uint32 size)
|
||||
: _resourceName(resourceName), _offset(offset), _size(size) {
|
||||
}
|
||||
};
|
||||
|
||||
class HagIndex {
|
||||
|
|
|
@ -30,7 +30,8 @@
|
|||
|
||||
namespace MADS {
|
||||
|
||||
Scene::Scene(MADSEngine *vm): _vm(vm), _action(_vm), _depthSurface(vm),
|
||||
Scene::Scene(MADSEngine *vm)
|
||||
: _vm(vm), _action(_vm), _depthSurface(vm),
|
||||
_dirtyAreas(_vm), _dynamicHotspots(vm), _hotspots(vm),
|
||||
_kernelMessages(vm), _sequences(vm), _sprites(vm), _spriteSlots(vm),
|
||||
_textDisplay(vm), _userInterface(vm) {
|
||||
|
|
|
@ -65,8 +65,9 @@ public:
|
|||
PrepType _prepType;
|
||||
|
||||
VerbInit() {}
|
||||
VerbInit(int id, VerbType verbType, PrepType prepType): _id(id),
|
||||
_verbType(verbType), _prepType(prepType) {}
|
||||
VerbInit(int id, VerbType verbType, PrepType prepType)
|
||||
: _id(id), _verbType(verbType), _prepType(prepType) {
|
||||
}
|
||||
};
|
||||
|
||||
class SceneLogic {
|
||||
|
|
|
@ -54,12 +54,13 @@ typedef Common::List<DepthEntry> DepthList;
|
|||
|
||||
/*------------------------------------------------------------------------*/
|
||||
|
||||
MSprite::MSprite(): MSurface() {
|
||||
MSprite::MSprite()
|
||||
: MSurface() {
|
||||
}
|
||||
|
||||
MSprite::MSprite(Common::SeekableReadStream *source, const Common::Array<RGB6> &palette,
|
||||
const Common::Rect &bounds):
|
||||
MSurface(bounds.width(), bounds.height()),
|
||||
const Common::Rect &bounds)
|
||||
: MSurface(bounds.width(), bounds.height()),
|
||||
_offset(Common::Point(bounds.left, bounds.top)) {
|
||||
// Load the sprite data
|
||||
loadSprite(source, palette);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue