aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/agi/op_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/agi/op_cmd.cpp b/engines/agi/op_cmd.cpp
index 702c6352e1..01ec081315 100644
--- a/engines/agi/op_cmd.cpp
+++ b/engines/agi/op_cmd.cpp
@@ -1104,7 +1104,7 @@ cmd(pause) {
cmd(set_menu) {
debugC(4, kDebugLevelScripts, "text %02x of %02x", p0, curLogic->numTexts);
- if (curLogic->texts != NULL && p0 < curLogic->numTexts)
+ if (curLogic->texts != NULL && p0 <= curLogic->numTexts)
g_agi->_menu->add(curLogic->texts[p0 - 1]);
}