summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2021-01-23 21:15:50 +0100
committerNikolay Korolev <nickvnuk@gmail.com>2021-01-23 21:15:50 +0100
commit6bdc0365eee4c8a587d04ad7693e28bc5a388a35 (patch)
treee3b8203d4960263802dbff230444546b61102f9c
parentuse ARRAY_SIZE (diff)
downloadre3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar.gz
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar.bz2
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar.lz
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar.xz
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.tar.zst
re3-6bdc0365eee4c8a587d04ad7693e28bc5a388a35.zip
-rw-r--r--src/control/Script.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/control/Script.cpp b/src/control/Script.cpp
index e435f615..e70bd508 100644
--- a/src/control/Script.cpp
+++ b/src/control/Script.cpp
@@ -2059,7 +2059,9 @@ int8 CRunningScript::ProcessOneCommand()
uint32 ip = m_nIp;
if (command < ARRAY_SIZE(commands)) {
script_assert(commands[command].id == command);
+ m_nIp -= 2;
sprintf(commandInfo, m_nIp >= SIZE_MAIN_SCRIPT ? "M<%5d> " : "<%6d> ", m_nIp >= SIZE_MAIN_SCRIPT ? m_nIp - SIZE_MAIN_SCRIPT : m_nIp);
+ m_nIp += 2;
if (m_bNotFlag)
strcat(commandInfo, "NOT ");
if (commands[command].position == -1)