aboutsummaryrefslogtreecommitdiff
path: root/scumm/charset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scumm/charset.cpp')
-rw-r--r--scumm/charset.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/scumm/charset.cpp b/scumm/charset.cpp
index abf97bc5e0..6b3cae795f 100644
--- a/scumm/charset.cpp
+++ b/scumm/charset.cpp
@@ -50,7 +50,7 @@ CharsetRenderer::CharsetRenderer(ScummEngine *vm) {
}
void CharsetRendererCommon::setCurID(byte id) {
- checkRange(_vm->_maxCharsets - 1, 0, id, "Printing with bad charset %d");
+ checkRange(_vm->_numCharsets - 1, 0, id, "Printing with bad charset %d");
_curId = id;
@@ -65,7 +65,7 @@ void CharsetRendererCommon::setCurID(byte id) {
}
void CharsetRendererV3::setCurID(byte id) {
- checkRange(_vm->_maxCharsets - 1, 0, id, "Printing with bad charset %d");
+ checkRange(_vm->_numCharsets - 1, 0, id, "Printing with bad charset %d");
_curId = id;
@@ -949,7 +949,7 @@ void CharsetRendererV3::printChar(int chr) {
int w, h;
int drawTop;
- checkRange(_vm->_maxCharsets - 1, 0, _curId, "Printing with bad charset %d");
+ checkRange(_vm->_numCharsets - 1, 0, _curId, "Printing with bad charset %d");
if ((vs = _vm->findVirtScreen(_top)) == NULL)
return;
@@ -1005,7 +1005,7 @@ void CharsetRendererClassic::printChar(int chr) {
const byte *charPtr;
int is2byte = (chr >= 0x80 && _vm->_CJKMode) ? 1 : 0;
- checkRange(_vm->_maxCharsets - 1, 1, _curId, "Printing with bad charset %d");
+ checkRange(_vm->_numCharsets - 1, 1, _curId, "Printing with bad charset %d");
if ((vs = _vm->findVirtScreen(_top)) == NULL && (vs = _vm->findVirtScreen(_top + getFontHeight())) == NULL)
return;