diff options
Diffstat (limited to 'engines/sludge')
-rw-r--r-- | engines/sludge/builtin.cpp | 5 | ||||
-rw-r--r-- | engines/sludge/sludge.h | 1 |
2 files changed, 3 insertions, 3 deletions
diff --git a/engines/sludge/builtin.cpp b/engines/sludge/builtin.cpp index ee1304997c..56db190c82 100644 --- a/engines/sludge/builtin.cpp +++ b/engines/sludge/builtin.cpp @@ -511,9 +511,8 @@ builtIn(pickOne) { } int i; -#if 0 - i = rand() % numParams; -#endif + + i = g_sludge->getRandomSource()->getRandomNumber(numParams - 1); // Return value while (numParams--) { diff --git a/engines/sludge/sludge.h b/engines/sludge/sludge.h index cb3d5248b0..e419b85f0e 100644 --- a/engines/sludge/sludge.h +++ b/engines/sludge/sludge.h @@ -71,6 +71,7 @@ public: Common::Language getLanguage() const; Graphics::PixelFormat *getScreenPixelFormat() const; Graphics::PixelFormat *getOrigPixelFormat() const; + Common::RandomSource *getRandomSource() const { return _rnd; }; const char *getGameFile() const; |