[Scummvm-cvs-logs] CVS: scummvm/wince pocketpc.cpp,1.29,1.30
Max Horn
fingolfin at users.sourceforge.net
Sun Aug 18 10:49:02 CEST 2002
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/simon simon.cpp,1.47,1.48 simon.h,1.26,1.27
- Next message: [Scummvm-cvs-logs] CVS: scummvm Makefile.common,1.18,1.19 engine.h,1.1,1.2 gameDetector.h,1.15,1.16 main.cpp,1.27,1.28 scumm.h,1.204,1.205 scummvm.cpp,1.205,1.206 sound.h,1.17,1.18
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/wince
In directory usw-pr-cvs1:/tmp/cvs-serv19809/wince
Modified Files:
pocketpc.cpp
Log Message:
MAJOR change to the way how Engine objects are instantiated
Index: pocketpc.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/wince/pocketpc.cpp,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -d -r1.29 -r1.30
--- pocketpc.cpp 18 Aug 2002 16:20:51 -0000 1.29
+++ pocketpc.cpp 18 Aug 2002 17:48:18 -0000 1.30
@@ -57,11 +57,7 @@
typedef void SoundProc(void *param, byte *buf, int len);
GameDetector detector;
-Gui gui;
-Scumm *g_scumm;
SimonState *g_simon;
-OSystem *g_system;
-SoundMixer *g_mixer;
Config *scummcfg;
tTimeCallback timer_callback;
int timer_interval;
@@ -443,46 +439,28 @@
return (-1);
OSystem *system = detector.createSystem();
+ Engine *engine;
/* Simon the Sorcerer? */
if (detector._gameId >= GID_SIMON_FIRST && detector._gameId <= GID_SIMON_LAST) {
/* Simon the Sorcerer. Completely different initialization */
- MidiDriver *midi = detector.createMidi();
-
- keypad_init();
- load_key_mapping();
- hide_cursor = TRUE;
-
- g_simon = SimonState::create(system, midi);
- g_system = g_simon->_system;
- g_mixer = &g_simon->_mixer[0];
- g_simon->_game = detector._gameId - GID_SIMON_FIRST;
- g_simon->set_volume(detector._sfx_volume);
- g_simon->_game_path = detector._gameDataPath;
- g_simon->go();
+ detector._gameId -= GID_SIMON_FIRST;
+ engine = SimonState::createFromDetector(&detector, system);
} else {
- Scumm *scumm = Scumm::createFromDetector(&detector, system);
- g_scumm = scumm;
- g_system = scumm->_system;
- g_mixer = &scumm->_mixer[0];
+ engine = Scumm::createFromDetector(&detector, system);
- scumm->_sound_volume_master = 0;
- scumm->_sound_volume_music = detector._music_volume;
- scumm->_sound_volume_sfx = detector._sfx_volume;
+ }
- keypad_init();
- load_key_mapping();
-
- hide_cursor = TRUE;
- if (scumm->_gameId == GID_SAMNMAX || scumm->_gameId == GID_FT || scumm->_gameId == GID_DIG)
- hide_cursor = FALSE;
+ keypad_init();
+ load_key_mapping();
+
+ hide_cursor = TRUE;
+ if (detector._gameId == GID_SAMNMAX || detector._gameId == GID_FT || detector._gameId == GID_DIG)
+ hide_cursor = FALSE;
- /* bind to Gui */
- scumm->_gui = &gui;
- gui.init(scumm); /* Reinit GUI after loading a game */
- scumm->go();
- }
+
+ engine->go();
return 0;
}
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/simon simon.cpp,1.47,1.48 simon.h,1.26,1.27
- Next message: [Scummvm-cvs-logs] CVS: scummvm Makefile.common,1.18,1.19 engine.h,1.1,1.2 gameDetector.h,1.15,1.16 main.cpp,1.27,1.28 scumm.h,1.204,1.205 scummvm.cpp,1.205,1.206 sound.h,1.17,1.18
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list