From a0c5805c8efba2e184b737dc7869092318743004 Mon Sep 17 00:00:00 2001 From: uruk Date: Mon, 5 May 2014 20:31:21 +0200 Subject: CGE2: Read identifiers properly in Text::load(). --- engines/cge2/fileio.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'engines/cge2/fileio.cpp') diff --git a/engines/cge2/fileio.cpp b/engines/cge2/fileio.cpp index 4da2c52cfa..fb39cd3ad7 100644 --- a/engines/cge2/fileio.cpp +++ b/engines/cge2/fileio.cpp @@ -232,6 +232,14 @@ Common::String EncryptedStream::readLine() { return _readStream->readLine(); } +int EncryptedStream::number(char *s) { + int r = atoi(s); + char *pp = strchr(s, ':'); + if (pp) + r = (r << 8) + atoi(pp + 1); + return r; +} + int32 EncryptedStream::size() { return _readStream->size(); } -- cgit v1.2.3