projects
/
super-star-trek.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Enable GNU realine keys, fix a small but fatal bug.
[super-star-trek.git]
/
sst.py
diff --git
a/sst.py
b/sst.py
index b1ab2f3487b232413ff89f1c7dfd2653090881c6..8583af2c3ea94d94e466b9decebfb29e7b4ca257 100755
(executable)
--- a/
sst.py
+++ b/
sst.py
@@
-13,6
+13,13
@@
on how to modify (and how not to modify!) this code.
"""
import os, sys, math, curses, time, readline, pickle, random, copy, gettext, getpass
"""
import os, sys, math, curses, time, readline, pickle, random, copy, gettext, getpass
+# This import only works on Unixes. The intention is to enable
+# Ctrl-P, Ctrl-N, and friends in Cmd.
+try:
+ import readline
+except ImportError:
+ pass
+
version = "2.1"
docpath = (".", "../doc", "/usr/share/doc/sst")
version = "2.1"
docpath = (".", "../doc", "/usr/share/doc/sst")
@@
-5705,7
+5712,7
@@
def choose():
game.state.remres = (game.inkling+4*game.incom)*game.intime
game.inresor = game.state.remres
if game.inkling > 50:
game.state.remres = (game.inkling+4*game.incom)*game.intime
game.inresor = game.state.remres
if game.inkling > 50:
- game.
state.
inbase += 1
+ game.inbase += 1
return False
def dropin(iquad=None):
return False
def dropin(iquad=None):
@@
-6007,6
+6014,8
@@
def makemoves():
if cmd == "":
listCommands()
continue
if cmd == "":
listCommands()
continue
+ elif opt and not (opt & game.options):
+ huh()
else:
break
if cmd == "SRSCAN": # srscan
else:
break
if cmd == "SRSCAN": # srscan