From 727a37b8e37e7a7463540b62031965acfd53194f Mon Sep 17 00:00:00 2001 From: Stas Sergeev Date: Wed, 15 Dec 2010 18:21:11 +0300 Subject: [PATCH] do not abbreviate commands after abandon --- sst.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sst.py b/sst.py index 3a777e1..857f2b0 100755 --- a/sst.py +++ b/sst.py @@ -5898,8 +5898,13 @@ def makemoves(): clrscr() setwnd(message_window) clrscr() + abandon_passed = False for (cmd, opt) in commands: - if cmd.startswith(scanner.token.upper()): + # commands after ABANDON cannot be abbreviated + if cmd == "ABANDON": + abandon_passed = True + if cmd == scanner.token.upper() or (not abandon_passed \ + and cmd.startswith(scanner.token.upper())): break; if cmd == "": listCommands() -- 2.31.1